10 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) ISSN (Print) 2313-4410, ISSN (Online) 2313-4402 ยฉ Global Society of Scientific Research and Researchers http://asrjetsjournal.org/ On the Efficiency of Outlier Generating Mechanisms in Multivariate Time Series Olusesan Oluyomi Olufolaboa*, Olanrewaju Ismail Shittub, Kazeem Adesola Adepojuc aDepartment of Statistics, Yaba College of Technology, Lagos, Nigeria b,cDepartment of Statistics, University of Ibadan, Ibadan, Nigeria aEmail: olufolabosesan@yahoo.com bEmail: oi.shittu@hotmail.com cEmail: ka.adepoju@.ui.edu.ng Abstract In this paper, two new outlier generating mechanisms for the detection of outliers in multivariate time series setting were derived. This is achieved by specifying two-variable vector autoregressive models and assuming additive and convolution effect of outliers on time series data. The magnitude and variance of outlier were derived for the generating models by method of least squares. Also a modified test statistics were developed to detect single outliers both in the response and explanatory variables. In order to establish the validity and efficiency of the derived models, the models were applied to both simulated and existing data. The results from the analysed data were also compared to some existing models and the result showed that the convolution model is best in terms of the number of outliers detected and the residual variance. This result confirms the finding in previous studies of outlier detection in univariate time series. Keywords: Additive outlier; Convolution outlier; Innovative outlier; Multiplicative outlier; Vector auto regressive. 1. Introduction The problem of outlier detection in time series has gained much attention in recent times and various methods of detection are available, but in most cases, it is limited to univariate time series. ------------------------------------------------------------------------ * Corresponding author. http://asrjetsjournal.org/ American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 11 It is a known fact, that in time series analysis, outliers can cause biases in parameter estimation as well as inappropriate predictions, resulting in misleading conclusion [28]. The essence of outlier detection is to discover the unusual data; whose behaviour is very exceptional when compared to the rest of the data set. Examining the extraordinary behaviour of outliers will surely help to uncover the valuable knowledge hidden behind them and to help the decision makers to improve on the quality of data. Generally, detection methods are divided into two parts: univariate and multivariate methods. In univariate methods, observations are examined individually while in multivariate methods, associations between variables in the same dataset are taken into account. Several outlier detection methods have been proposed for univariate time series including [11,8,9,26,1,14 and 32]. All the listed works were based on time domain and almost all make use of iterative procedure in the outlier detection process. However, [25] in their work considered the identification of outliers in frequency domain using the spectral method. On the detection of outlier in multivariate time series, [12] made use of projection pursuit technique while [3] proposed the Independent Component Analysis (ICA) as a tool capable of identifying the locations of multiple outliers in multivariate time series. The authors [10] used meta-heuristic methods to detect additive outliers in multivariate time series. The work of [13] introduced the coefficient of vector autocorrelation, obtained its influence function together with its distribution and used it to test the hypothesis of presence of outliers. [31] in his paper used an efficient two-phase algorithm for detecting outlying samples in multivariate time series datasets. The Bounded Coordinate System metric was used to measure the similarity between two multivariate time series samples, and the outlierness of a sample is measured by average distance to its k nearest neighbours. Then a heuristic and two pruning rules were utilized to quickly remove multivariate time series samples that are not possible outlier candidates, reducing significantly the distance computation among objects. As a result of outlier masking effect of both Additive and Innovative on the estimates of parameters and the multiplicative effect on parameters estimated, [26] introduced two other types of outliers which are Convolution Outlier (CO) and Multiplicative Outlier (MO) for univariate time series. The work of [26] was extended to multivariate time series by [19] whereby two generating mechanisms; Innovative and Multiplicative were considered. It was concluded that Multiplicative outlier model was more sensitive to outlier with minimum standard error of the estimate. For this paper, two outliers generating mechanisms; Convolution and Additive will be extended to multivariate time series and their performances in terms of outlier detection will be compared to the existing ones. 2. Methodology In this section, by assuming that outliers have either Additive or Convolution effect on a series for bivariate time series and specifying two-variable Vector Autoregressive (VAR) models, the estimate of the parameter for the American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 12 two models will be derived and their corresponding test statistics developed. 2.1 Derivation of Outlier Generating Mechanisms for Additive Outlier (AO) Model In this subsection outlier generating mechanism for additive outlier model will be derived. Generally, an additive outlier represents an unexpected change in the value of one of the observations. It can appear as a result of a recording or measurement error or other single effect. The additive outlier is defined as )(T ttt ZX ฮพฯ‰+= (1) where tX = (๐‘ฅ๐‘ฅ1๐‘ก๐‘ก,๐‘ฅ๐‘ฅ2๐‘ก๐‘ก, โ€ฆ โ€ฆ โ€ฆ . . ๐‘ฅ๐‘ฅ๐‘˜๐‘˜๐‘ก๐‘ก ) is a k-dimensional time series, Zt is an outlier free time series that is assumed to follow the Autoregressive Moving Average of Order (p,q) i.e. ARMA (p,q), )(T tฮพ is a time indictor such that 1)( =T tฮพ for all 0)( == T tandTt ฮพ otherwise, and ๐œ”๐œ” = ๏ฟฝฯ‰ 1, โ€ฆ , ฯ‰ k๏ฟฝ โ€ฒ is the size or the magnitude of outlier. Now, given vector models 1tX and 2tX such that 1tX contains outlier and 2tX is outlier free, the magnitude of such outlier and its corresponding variance can be obtained by specifying the two variable VAR(2) as: 1 11 1 1 12 2 1 1 2 21 2 1 22 1 1 2 (2) t t t t t t t t X X X a X X X a ฯ• ฯ• ฯ• ฯ• โˆ’ โˆ’ โˆ’ โˆ’ = + + = + + (3) where, 1tX and 1 1tX โˆ’ are the current and lag values of the response variable respectively, 2tX and 2 1tX โˆ’ are current and lag values of the explanatory variable respectively. Now considering equation (3) ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…21๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก When ๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 is contaminated and assumed additive model, we have ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…21๏ฟฝ๐‘๐‘๐‘ก๐‘กโˆ’1 + ๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 (๐‘‡๐‘‡) ๏ฟฝ + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก (4) = โˆ…21 ๐‘๐‘๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 (๐‘‡๐‘‡) + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 13 ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22 ๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐‘๐‘๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 (๐‘‡๐‘‡) ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22 ๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22 ๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐œ™๐œ™21 ๐œ‰๐œ‰๐‘ก๐‘กโˆ’1๏ฟฝ๐œ”๐œ” + ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๏ฟฝ Therefore, the general the additive model is given as ๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด:๐‘‹๐‘‹๐ด๐ด๐ด๐ด๐‘ก๐‘ก = ๐œ™๐œ™๐ด๐ด๐ด๐ด๐‘‹๐‘‹๐‘—๐‘—๐‘ก๐‘กโˆ’1 + โˆ…๐ด๐ด๐‘—๐‘—๐œ–๐œ–๐‘ก๐‘กโˆ’1 ๏ฟฝ๐œ”๐œ” + ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๏ฟฝ (5) 2.1.1 Derivation of the Magnitude of Outlier for AO With 1 11 1 1 12 2 1 1 as defined in equation (2)t t t tX X X aฯ• ฯ•โˆ’ โˆ’= + + Then, ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) 11 12 2 1 1 ( ) ( ) 11 12 1 (6) T T t t t t t t T T t t t t t Z Z X a a a ฯ‰ฮพ ฯ• ฯ‰ฮพ ฯ• ฮธ ฮฒ ฮธ ฮฒ ฯ‰ฮพ ฯ• ฯ‰ฮพ ฯ• ฯ† ฮฒ ฯ• ฮฒ ฯ• ฮฒ โˆ’+ = + + + ๏ฃฎ ๏ฃน + = + + +๏ฃฏ ๏ฃบ ๏ฃฐ ๏ฃป l ( ) ( ) ( ) ( ) ( ) )( 12 )( 111 T tt T tta ฯ‰ฮพฮฒฯ•ฯ†ฯ‰ ฮฒฯ† ฮฒฮธฯ† ฮฒฯ† ฮฒฮธ โˆ’+๏ฃบ ๏ฃป ๏ฃน ๏ฃฏ ๏ฃฐ ๏ฃฎ โˆˆ+=๏ฃบ ๏ฃป ๏ฃน ๏ฃฏ ๏ฃฐ ๏ฃฎ โˆ’ ๏ฌ ( ) ( ) ( ) ( ) ( ) 1 )( 12 )( 11 โˆ’ โˆ’+๏ฃบ ๏ฃป ๏ฃน ๏ฃฏ ๏ฃฐ ๏ฃฎ + = ฮฒฮธ ฮฒฯ† ฯ‰ฮพฮฒฯ•ฯ†ฯ‰ฮพ ฮฒฮธ ฮฒฯ†ฯ† T tt T t ta ๏ฌ (7) Summing the square of equation (1.9) over n we have ( ) ( ) ( ) ( ) ( ) โˆ‘ โˆ‘ = = ๏ฃบ ๏ฃบ ๏ฃบ ๏ฃบ ๏ฃป ๏ฃน ๏ฃฏ ๏ฃฏ ๏ฃฏ ๏ฃฏ ๏ฃฐ ๏ฃฎ โˆ’ โˆ’+๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ + = n t n t T tt T t ta 1 1 )( 12 )( 11 2 1 ฮฒฮธ ฮฒฯ† ฯ‰ฮพฮฒฯ•ฯ†ฯ‰ฮพ ฮฒฮธ ฮฒฯ†ฯ† ๏ฌ (8) Differentiating equation (1.7) with respect to ฯ‰ and setting to zero, we obtain the magnitude of outlier in the model as American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 14 ( ) ( ) ( ) ( ) ( ) 0 1 2 ห† )( 12 )( 1 112 2 =โˆ’+๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ + ๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ โˆ’ = โˆ‚ โˆ‚ โˆ‘ = T tt T t n tA ta ฯ‰ฮพฮฒฯ•ฯ†ฯ‰ฮพ ฮฒฮธ ฮฒฯ†ฯ† ฮฒฮธ ฮฒฯ†ฯ‰ l (9) ( ) ( ) ( )โˆ‘ โˆ‘โˆ‘ = == =โˆ’+๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ + n t n t t n t 1 1 12 1 11 0ฯ‰ฮฒฯ•ฯ†ฯ‰ ฮฒฮธ ฮฒฯ†ฯ† ๏ฌ ( ) ( ) ( ) ( ) ( ) ( ) ( ) t t ๏ฌ ๏ฌ ฮฒฯ•ฯ† ฮฒฯ† ฮฒฮธฯ†ฯ†ฯ‰ ฯ‰ฮฒฯ•ฯ†ฯ‰ฯ† ฮฒฮธ ฮฒฯ†ฯ† 121111 121111 1 0 +=โˆ’ =โˆ’++๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ ( ) ( ) ( ) 11 1211 1 ห† ฯ† ฮฒฯ•ฯ† ฮฒฯ† ฮฒฮธฯ† ฯ‰ โˆ’ + = t A ๏ฌ ( )( ) 11 12 1 1ห† ฯ† ฯ†ฮฒฯ•ฯ‰ โˆ’ + = t A ๏ฌ (10) Therefore, the estimate of the variance is ( ) ( ) 2 2 2 12 2 11 ห† 1 a AV ฯ† ฮฒ ฯ• ฯƒ ฯ‰ ฯ• ๏ฃซ ๏ฃถ ๏ฃฌ ๏ฃท ๏ฃญ ๏ฃธ= โˆ’ 2 2 212 111 a ฯ• ฯ† ฮฒ ฯƒ ฯ• ๏ฃซ ๏ฃถ๏ฃซ ๏ฃถ = ๏ฃฌ ๏ฃท๏ฃฌ ๏ฃทโˆ’๏ฃญ ๏ฃธ ๏ฃญ ๏ฃธ (11) With the estimates of mean and variance of the magnitude of AO derived, the test statistic for testing the presence of outlier for additive model is constructed as follows: ( ) 12 11 11 12 12 12 1 1. 1 1 (12) t i a t i a ฯ• ฯ•ฮป ฯ• ฯ• ฯƒ ฯ• ฮป ฯ• ฯƒ + โˆ’ = โˆ’ + = l l American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 15 2.2 Derivation of Outlier Generating Mechanisms for Convolution Outlier (MO) Model The outlier effect on a given series may be either additive or innovative and the effect may be a combination of the two [26]. By this, we propose the convolution of the additive and innovative outliers for the multivariate setting as follows: The innovative and additive models are defined respectively as follows: ( ) model additivefor model innovativefor )(T tttA T tttI ZX ZX ฯ‰ฮพ ฯ‰ฮพฮฒฯ• += += The convolution involved adding both innovative and additive models [26]. This gives ( )( )ฮฒฯ•ฯ‰ฮพ ++= 12 T tttC ZX (13) For the general case of CO, now considering, ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…21๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก as defined in equation (2) Assuming ๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 is contaminated, we have ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…21 ๏ฟฝ2๐‘๐‘๐‘ก๐‘กโˆ’1 + ๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)(1 +๐œ‘๐œ‘(๐›ฝ๐›ฝ))๏ฟฝ + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก (14) ๐‘‹๐‘‹2๐‘ก๐‘ก = 2โˆ…21๐‘๐‘๐‘ก๐‘กโˆ’1 + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)(1 +๐œ‘๐œ‘(๐›ฝ๐›ฝ)) + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก where ๐‘๐‘๐‘ก๐‘ก = ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)and ๐‘๐‘๐‘ก๐‘กโˆ’1 = ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) we then have ๐‘‹๐‘‹2๐‘ก๐‘ก = 2โˆ…21๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)(1 +๐œ‘๐œ‘(๐›ฝ๐›ฝ)) + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก (15) ๐‘‹๐‘‹2๐‘ก๐‘ก = 2โˆ…21๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘กโˆ’1 + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)๐œ‘๐œ‘(๐›ฝ๐›ฝ) + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + ๐‘Ž๐‘Ž1๐‘ก๐‘ก ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22๐‘‹๐‘‹1 ๐‘ก๐‘กโˆ’1 + 2โˆ…21๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)๐œ‘๐œ‘(๐›ฝ๐›ฝ) ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22๐‘‹๐‘‹1 ๐‘ก๐‘กโˆ’1 + 2โˆ…21๐œ‘๐œ‘(๐›ฝ๐›ฝ)๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡) + โˆ…21๐œ”๐œ”๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)๏ฟฝ1 + ๐œ‘๐œ‘(๐›ฝ๐›ฝ)๏ฟฝ ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…22๐‘‹๐‘‹1 ๐‘ก๐‘กโˆ’1 + โˆ…21๐œ‰๐œ‰๐‘ก๐‘ก (๐‘‡๐‘‡)[2๐œ‘๐œ‘(๐›ฝ๐›ฝ) + ๐œ”๐œ”(1 + ๐›ฝ๐›ฝ)] (16) American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 16 Therefore, in general, the CO generating mechanism is ๐ถ๐ถ๐ด๐ด๐ถ๐ถ๐ด๐ด๐ด๐ด๐ด๐ด๐ถ๐ถ๐ด๐ด๐ด๐ด๐ด๐ด๐ถ๐ถ๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด๐ด:๐‘‹๐‘‹๐ถ๐ถ๐ด๐ด๐‘ก๐‘ก = ๐œ™๐œ™๐ด๐ด๐ด๐ด๐‘‹๐‘‹๐‘—๐‘—๐‘ก๐‘กโˆ’1 + โˆ…๐ด๐ด๐‘—๐‘—๐œ‰๐œ‰๐‘ก๐‘กโˆ’1๐‘‡๐‘‡ [2๐œ‘๐œ‘(๐›ฝ๐›ฝ) + ๐œ”๐œ”(1 + ๐›ฝ๐›ฝ)] (17) 2.1.2 Derivation of Magnitude of Outlier for CO Now, specifying tttt aXXX 1121211111 ++= โˆ’โˆ’ ฯ†ฯ† (18) and substituting tCX in equation (18) gives ( )( ) ( )( )( ) tt T tt T tt aXZZ 11212 )( 111 )( 1212 ++++=++ โˆ’โˆ’ ฯ†ฮฒฯ•ฯ‰ฮพฯ†ฮฒฯ•ฯ‰ฮพ (19) ( ) ( )( ) ( ) ( )( )[ ] ( ) tt T tt T tt aaa 1112111 )( 1212 ++++=++ โˆ’โˆ’ ๏ฌฮฒฯ•ฯ†ฮฒฯ•ฯ‰ฮพฮฒฯ•ฯ†ฮฒฯ•ฯ‰ฮพฮฒฯ• ( ) ( ) ( ) ( )( ) ( )( )ฮฒฯ•ฯ‰ฮพฯ†ฮฒฯ•ฯ‰ฮพฮฒฯ•ฯ†ฮฒฯ•ฯ†ฮฒฯ• +++โˆ’โˆ’โˆ’ โˆ’=โˆ’ 1122 )( 11 )( 1121111 T t T ttttt aaa ๏ฌ ( ) ( )[ ] ( ) ( )( ) ( )( )ฮฒฯ•ฯ‰ฮพฯ†ฮฒฯ•ฯ‰ฮพฮฒฯ•ฯ†ฯ†ฮฒฯ•ฮฒฯ• +++โˆ’=โˆ’โˆ’ โˆ’ 11122 )( 11 )( 11211 T t T ttta ๏ฌ (20) Summing and squaring equation (20) gives ( ) ( )( ) ( )( )[ ] ( ) ( )[ ]โˆ‘ โˆ‘ = = โˆ’ โˆ’โˆ’ โˆ’++โˆ’ = n t n t T t T tt ta 1 2 11 1 2 11112 2 122 11 ฯ†ฮฒฯ•ฮฒฯ• ฮฒฯ•ฯ‰ฮพฯ†ฮฒฯ•ฯ‰ฮพฮฒฯ•ฯ† ๏ฌ (21) Differentiating equation (21) with respect to ฯ‰ and equating to 0 we have ( )( ) ( )( ) ( ) ( )[ ] 0 122 112 2 11 11 2 = โˆ’โˆ’ +++ = โˆ‚ โˆ‘โˆ‚ ฯ†ฮฒฯ•ฮฒฯ• ฮฒฯ•ฯ†ฮฒฯ• ฯ‰ ta ` (22) ( ) ( )( ) ( )( )[ ] 011 1 11112 =+++โˆ’โˆ‘ = โˆ’ n t t ฮฒฯ•ฯ‰ฯ†ฮฒฯ•ฯ‰ฮฒฯ•ฯ† ๏ฌ ( ) ( )( ) ( )( ) 011 11112 =+++โˆ’โˆ’ ฮฒฯ•ฯ‰ฯ†ฮฒฯ•ฯ‰ฮฒฯ•ฯ† t๏ฌ ( )( ) ( )( ) ( ) 11211 11 โˆ’=+โˆ’+ t๏ฌฮฒฯ•ฯ†ฮฒฯ•ฯ‰ฯ‰ฯ†ฮฒฯ•ฯ‰ American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 17 ( )( ) ( )( )[ ] ( ) 11211 11 โˆ’=+โˆ’+ t๏ฌฮฒฯ•ฯ†ฮฒฯ•ฯ†ฮฒฯ•ฯ‰ ( ) ( ) ( )( )ฮฒฯ•ฯ† ฮฒฯ•ฯ† ฯ‰ โˆ’โˆ’ = โˆ’ 11 ห† 11 112 t C ๏ฌ (23) The corresponding variance is ( ) ( ) ( )( ) 2 2 12 22 11 ห†V( ) 1 1 a C ฯ• ฯ† ฮฒ ฯƒ ฯ‰ ฯ• ฯ† ฮฒ = โˆ’ โˆ’ (24) Therefore, the test statistic is ( )C C i eS ฯ‰ ฯ‰ฮป ห†. ห† = ( ) ( ) ( )( ) ( ) ( )( )22 11 2 2 2 12 11111 11 11/ ฮฒฯ•ฯ†ฯƒฮฒฯ•ฯ† ฮฒฯ•ฯ†ฮฒฯ•ฯ† ฮป +โˆ’๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ ๏ฃญ ๏ฃซ +โˆ’ = โˆ’ a t i ๏ฌ (25) ( ) ( ) ( )( ) ( ) ( )( ) ( ) a t ฯƒฮฒฯ•ฯ† ฮฒฯ•ฯ† ฮฒฯ•ฯ† ฮฒฯ•ฯ† 12 11 11 112 11* 11 +โˆ’ +โˆ’ = โˆ’๏ฌ a t i ฯƒ ฮป 1 โˆ’= ๏ฌ (26) Table 1: Summary of Estimates and Test Statistic for the two models when 1tX contains outlier MODELS MAGNITUDE VARIANCE TEST STATISTIC Additive ( ) ( )12 11 1 1 tฯ• ฮฒ ฯ† ฮป ฯ† + โˆ’ 2 2 2 11 12 1 aฯƒฮฒฯ• ฯ† ฯ† ๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ ๏ฃญ ๏ฃซ ๏ฃท๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ๏ฃฌ ๏ฃญ ๏ฃซ โˆ’ ( ) a t ฯƒฯ† ฯ† 12 121 ๏ฌ+ Convolution ( ) ( ) ( )( )ฮฒฯ•ฯ† ฮฒฯ•ฯ† โˆ’โˆ’ โˆ’ 11 11 112 t๏ฌ ( ) ( )( )22 11 2 2 12 11 ฮฒฯ•ฯ† ฯƒฮฒฯ•ฯ† โˆ’โˆ’ ๏ฃท ๏ฃธ ๏ฃถ ๏ฃฌ ๏ฃญ ๏ฃซ a a t ฯƒ 1โˆ’๏ฌ American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 18 3. Application In this section, analysis of both simulated and real data sets will be used to test the validity and efficiency of the derived outliers generating mechanisms. In other to compare the performance of the two newly derived models with the existing ones, Data on Nigerian Bank Deposits and Loans from Annual Statistical Bulletin of the Central Bank of Nigeria, 2011 were made used of. From the derived outlier generating mechanisms in section 2 and with the estimation of the magnitudes of outliers and their variances, the test statistics constructed will be used to detect the existence of outliers in both the generated series and real data. For the simulated data, a uniform distribution is assumed with contaminated observation with varying sizes of 10, 50, and 100. The data were analysed with the R-package of version 3.0.1. 3.1 Analysis of Simulated Data when X1t Contains an Outlier The results of the models on simulated data assuming a uniform distribution in terms of their outlier detection performance are tabulated below. The sample sizes considered are 10, 50 and 100. Table2: Summary of Result on Detection Rate of the Models on Simulated Data when 1tX contains outlier N=10 N=50 N=100 Model Type No of outliers injected No of outliers detected % of outliers detected No of outliers injected No of outliers detected % of outliers detected No of outliers injected No of outliers detected % of outliers detected Additive 2 1 50 5 4 80 8 6 75 Convolution 2 2 100 5 5 100 8 8 100 Innovative* 2 0 0 5 2 40 8 2 25 Multiplicative* 2 2 100 5 4 80 8 5 80 Source* [19] The Convolution model from the summary in Table2 had 100% outlier detection compared to Additive model as the sample size increases. When compared with existing models, the Convolution model is most sensitive to outlying observations. 3.2 Detection of Outlier in Real Data American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 19 In order to investigate the performance of the proposed models, a pair of data on Deposit and Loan was used. The data was extracted from the Annual Statistical Bulletin of the Central Bank of Nigeria, 2011. 3.2.1. Assumed Model of Deposits and Loans Here two cases are considered. The first case is when loan is contaminated. The vector autoregressive model is given as ๐‘‹๐‘‹1๐‘ก๐‘ก = โˆ…11๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + โˆ…12๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 + โ„“๐‘ก๐‘ก (27) where ๐‘‹๐‘‹1๐‘ก๐‘ก is the current value of deposit, ๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 is the immediate past value of deposit, and ๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 is the immediate past value of loan. The estimated VAR model via the use of statistical package R is as follows X1t = 0.4826 X1t-1 โ€“โ€“ 0.1579 X2t-1 (28) s.e (0.1836) (0.1561) t (2.628) (โ€“1.012) P-value (0.0142) (0.3210) When deposit is contaminated, the vector autoregressive model is: ๐‘‹๐‘‹2๐‘ก๐‘ก = โˆ…21๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 + โˆ…22๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 + โ„“๐‘ก๐‘ก (29) where ๐‘‹๐‘‹2๐‘ก๐‘ก is the current value of loan,๐‘‹๐‘‹2๐‘ก๐‘กโˆ’1 is the immediate past value of loan and ๐‘‹๐‘‹1๐‘ก๐‘กโˆ’1 is the immediate past value of deposit. The estimated VAR model via the use of statistical package R is as follows X2t = 0.9605 X2t-1 โ€“โ€“ 0.3339 X1t-1 (30) S.e (0.1712) (0.2015) t (5.610) (โ€“1.657) P (6.78e.06) (0.1095) The detection performance of both Additive and Convolution models on the real data are shown on tables 3 and 4 below. American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 20 Table 3: Detection Performance of Additive Model on Deposit and Loan Data Deposit Loan (Wa) T Remarks 111.7 131.2 276.6 311.4 873.5 1229.2 1378.4 5722.0 8360.1 10580.7 4612.2 19542.2 4855.2 8807.1 12442.0 19047.6 18513.8 15860.5 20640.9 16875.9 14861.6 20551.8 64490.0 18461.9 3118.6 3082.3 13411.8 3296.2 3953.1 35.9 44.2 58.2 114.9 373.6 492.8 659.9 3721.1 4730.8 5962.1 1895.3 10910.4 1602.2 8659.3 4411.2 11158.6 11852.7 7498.1 11150.3 12341.0 8942.2 11251.9 34118.5 16105.5 24274.6 27263.5 46521.5 15590.5 63769.4 -7425.1230 -7287.8225 -7320.9776 -6766.7184 -6641.4233 -6645.0523 -2347.0674 -1321.7090 -214.7493 -7060.4273 10107.6624 -10360.6635 -790.9809 2051.1317 6231.8871 3575.8049 1289.6953 6662.9285 1167.7164 1158.2959 7283.8830 48840.8554 -14779.9643 -10755.6646 -2097.8978 8721.0511 -3338.5137 -2683.9759 747.8194 -3.5562723 -3.4905121 -3.5063918 -3.2409286 -3.1809184 -3.1826565 -1.1241310 -0.6330342 -0.1028544 -3.3816009 4.8410781 -4.9622533 -0.3788413 0.9823922 2.9847704 1.7126364 0.6177012 3.1912183 0.5592793 0.5547673 3.4886253 23.3923914 -7.0788832 -5.1514396 -1.0047909 4.1769588 -1.5989855 -1.2854938 0.3581691 ND* ND ND ND ND ND ND ND ND ND D** D ND ND ND ND ND ND ND ND ND D D D ND D ND ND ND D** = Outlier detected ND* = No outlier detected The critical value (c) = 4 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 21 Table 4: Detection Performance of Convolution Model on Deposit and Loan Data Deposit Loan (Wc) T Remarks 111.7 131.2 276.6 311.4 873.5 1229.2 1378.4 5722.0 8360.1 10580.7 4612.2 19542.2 4855.2 8807.1 12442.0 19047.6 18513.8 15860.5 20640.9 16875.9 14861.6 20551.8 64490.0 18461.9 3118.6 3082.3 13411.8 3296.2 3953.1 35.9 44.2 58.2 114.9 373.6 492.8 659.9 3721.1 4730.8 5962.1 1895.3 10910.4 1602.2 8659.3 4411.2 11158.6 11852.7 7498.1 11150.3 12341.0 8942.2 11251.9 34118.5 16105.5 24274.6 27263.5 46521.5 15590.5 63769.4 543.83931 533.78300 536.21138 495.61569 486.43869 486.70449 171.90659 96.80611 15.72891 517.12786 -740.31692 758.84751 57.93392 -150.23132 -456.44297 -261.90317 -94.46133 -488.01380 -85.52721 -84.83722 -533.49445 -3577.25755 1082.53098 787.77864 153.65662 -638.75715 244.52322 196.58282 -54.77264 3.4944194 3.4298029 3.4454064 3.1845603 3.1255938 3.1273017 1.1045794 0.6220241 0.1010655 3.3227859 -4.7568790 4.8759466 0.3722523 -0.9653058 -2.9328574 -1.6828492 -0.6069578 -3.1357146 -0.5495519 -0.5451185 -3.4279489 -22.9855362 6.9557628 5.0618425 0.9873149 -4.1043105 1.5711749 1.2631357 -0.3519396 ND* ND ND ND ND ND ND ND ND ND D** D ND ND ND ND ND ND ND ND ND D D D ND D ND ND ND D** = Outlier detected ND* = No outlier detected The critical value (c) = 4 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 22 Table 5: Summary of Outlier Detection of the Two Models on Deposits and Loan Data Model No of outliers detected Convolution 6 Additive 6 **Innovation 5 **Multiplicative Nil **Source: [19] 4. Discussion of Results From the analyzed simulated data with varying sample sizes of 10, 50, and100, the average percentage rates of outlier detection for AO and CO are 68% and 100% respectively of the injected outliers. From the result, CO was consistent in outlier detection as the sample size increases. Comparing the performance of these two newly derived models with the existing models, the CO outperformed both Multiplicative and Innovative models that have average detection rate of 86.7% and 21.7% respectively for the simulated data. For the real data set of Deposit and Loan, 6 outliers were equally detected by the two models when we consider the case of deposit depending on loan. The two derived outlier-generating mechanisms were able to detect potential outlier independently in multivariate time series. However, comparing the performance of these models with the existing ones, AO and CO detected 6 outliers while Innovative model was able to detect 5 but Multiplicative model detected no outlier as a result of non-multiplicative nature of data. [19]. In summary, CO was found to be most sensitive to outliers for the simulated data sets as the sample increases and also for the real data. When compared also with the existing models, CO has been found to be most efficient with minimum standard error of the estimate and is therefore recommended for outlier detection in multivariate time series data. 5. Conclusion This work was undertaken to develop test statistic for detecting outliers assuming two different outliers generating mechanisms in multivariate time series models. In line with the main objective of this paper, the test statistics were derived for each generating mechanism namely; the Additive and Convolution models. The model with greatest detective power in terms of their sensitivity to the number of outliers detected by applying the models to both simulated and a pair of real data were determined. All these were achieved using theoretical and analytical methods. The convolution model was found to be most sensitive to outlier detection when compared with existing models, it is therefore recommended for outlier detection in multivariate time series. American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 23 References [1] Z. Azami, A. Ibrahim and S. Mohd. โ€œDetection Procedure for a Single Additive Outlier in Bilinear Model.โ€ Journal of Pak. Stat. Oper. Res. Vol. No 1 PP. 1-5, 2007. [2] R. Baragona and F. Battaglia. โ€œOutlier Detection in Multivariate Time Series by Independent Component Analysis.โ€ Neutral Computation, 19:1962-1984. [3] R. Baragona, F. Battaglia and C. Alzini. โ€œGenetic Algorithms for the Identification of Additive and Innovational Outliers in Time Seriesโ€ Computational Statistics and Data Analysis. 30,147,2001. [4] V. Barnett. โ€œThe study of outliers: Purpose and Model.โ€ Applied Statistics, 27(3), 242โ€“250,1978. [5] V. Barnett and T. Lewis. Outlier in Statistical Data. John Wiley & Sons U. K. 1994. [6] G.E.P. Box, G.M. Jenkins and G. Reinsel. Time Series Analysis: Forecasting and Control,3rd Ed., New Jersey: Prentice-Hall,1994. [7] K. Chaloner and R. Brant. โ€œA Bayesian Approach to Outlier Detection and Residual Analysis.โ€ Biometrika, 25, 651 โ€“ 660,1988. [8] I. Chang, et. al. โ€œEstimation of Time Series Parameters in the Presence of Outliersโ€ Technometrics, 3, 193.204,1988. [9] C. Chen and L.M. Liu. โ€œJoint Estimation of Model Parameters and Outlier effects in Time Series.โ€ Journal of the American Statistical Association, 88, 284 โ€“ 297,1993. [10] D. Cucina, A.Di Salvatore and M. Protopapas. โ€˜โ€™Meta-heuristic Methods for Outliers Detection in Multivariate Time Series.โ€™โ€™ Comisef working paper series, 003,270,2008 [11] A.J. Fox. โ€œOutliers in Time Series.โ€ Journal of the Royal Statistical Society. B34: 350 โ€“ 363,1972 [12] P. Galeano, D. Pena and R.S. Tsay. โ€œOutlier Detection in Multivariate Time Series via Projection Pursuit.โ€ Working paper 0-42. Statistics and Econometrics Series II, Dept. De Estadistica, Universidad Carlos III de Madrid,2004 [13] J. Helbling and R. Cleroux. โ€œOn Outlier Detection in Multivariate Time Series.โ€ Mathematical Volume 34, Number 1, pp. 19-26,2009. [14] A. Kaya. โ€œModelling Outlier Factors in Data Analysis.โ€ Advances in Information Systems, LNCS 3261, 88 โ€“ 95,2010. [15] A. Khattree and D.N. Naik. โ€œDetection of Outliers in Bivariate Time Series Data.โ€ Communications in American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 24 Statistics โ€“ Theory and Methods, 16(12): 3701 โ€“ 3714,1987. [16] G.M. Ljung. โ€œOn Outlier Detection in Time Series.โ€ J. R. Statist. Soc. B. 55 No. 2, 559 -567,1993. [17] C.R. Nelson, and C.L. Plosser. โ€œTrends and Random Walks in Macroeconomic Time Series.โ€ Journal of Monetary Economics, 10, 139 โ€“ 162,1982. [18] D. Olivier and C. Amelie. โ€œThe Impact of Outliers on Transitory and Permanent Components in macroeconomic Series.โ€ Economic Bulleting, Vol. 3, No 60 PP 1 โ€“ 9,2008. [19] O. Olufolabo, O.I. Shittu and K.A. Adepoju. โ€œPerformance of Two Generating Mechanisms in Detection of Outliers in Multivariate Time Series.โ€ American Journal of Theoretical and Applied Statistics.5(3), 115-122,2016. [20] A. Pankratz. Forecasting with Univariate Box-Jenkins Models: Concepts and Cases, New York: John Wiley and Sins,1983. [21] A. Pankratz. โ€œDetecting and Treating Outliers in Dynamic Regression Models.โ€ Biometrika,80, 47- 54,1993. [22] D. Pena and G.E.P. Box. โ€œIdentifying a Simplifying Structure in Time Series.โ€ Journal of the American Statistical Association, 82, 836-843,1987. [23] S. Ruey and R.S. Tsay. โ€œOutliers, Level Shifts, and Variance Changes in Time Series.โ€ Journal of Forecasting, Vol. 7, I-20 Department of Statistics, Carnegie Mellon University, U. S.A,1988. [24] D.K. Shangodoyin. โ€œOn the Specification of time series Models in the Presence of Aberrant Observationsโ€. Ph.D. Thesis in the Dept. of Statistics, Univ. of Ibadan,1994. [25] I.O. Shittu and D.K. Shangodoyin. โ€˜โ€™Detection of Outliers in Time Series Data: A Frequency Domain Approach.โ€™โ€™ Asian Journal of Scientific Research 1, (2) 130-137,2008. [26] I. O. Shittu. โ€œOn Performance of Some Generating Models in Detection of Outliers Under Classical Rule.โ€™โ€™ M.Phil. Thesis. Dept. of Statistics, Univ. of Ibadan,2000. [27] C. Sims. โ€œMacroeconomics and Reality.โ€ Econometricsa 48 (1), 11-46, JSTOR 112017,1980. [28] R.S. Tsay. โ€œTime Series Model specification in the Presence of Outlier.โ€ Jour. Amer. Stat. Asso. 81, 132 โ€“ 141,1986. [29] R.S. Tsay. โ€œOutliers, Level Shifts and Variance Changes in Time Series.โ€ Journal of Forecasting, 7, 1- 20,1988. American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 22, No 1, pp 10-25 25 [30] R.S. Tsay, D. Pena and A.E. Pankratz. โ€œOutliers in multivariate time series.โ€ Biometrika, 87, 789- 804,2000. [31] X.Wang. โ€œTwo-Phase Outlier Detection in Multivariate Time series.โ€ Fuzzy Systems and Knowledge Discovery, Eighth International Conference. Vol.3,2011. [32] Ji. Yanjie et al. (2013). โ€œDetection of Outliers in a Time Series of Available Parking Spaces.โ€ Mathematical Problems in Engineering, Volume 2013: 1-12,2013. http://ieeexplore.ieee.org/search/searchresult.jsp?searchWithin=%22Authors%22:.QT.Xin%20Wang.QT.&newsearch=true http://ieeexplore.ieee.org/xpl/mostRecentIssue.jsp?punumber=6012258 http://ieeexplore.ieee.org/xpl/mostRecentIssue.jsp?punumber=6012258