I have fitted ARIMA(5,1,2) model using auto.arima() function in R and by looking order we can say this is not a best model to forecast. If outliers exist in the data series, what is the method to fit a model to such data?
|
|
|||||
|
|
Anthony, Michael Chernick points you in the right direction. I would also look at Ruey Tsay's work as that added to this body of knowledge. See more here. You can't compete against today's automated computer algorithms. They look at many ways to approach the time series that you haven't considered and often not documented in any paper or book. When one asks how to do an ANOVA, a precise answer can be expected when comparing against different algorithms. When one asks the question how do I do pattern recognition, many answers are possible as heuristics are involved. Your question involves the use of heuristics. The best way to fit an ARIMA model, if outliers exist in the data is to evaluate possible states of nature and to select that approach that is deemed optimal for a particular data set. One possible state of nature is that the ARIMA process is the primary source of explained variation. In this case one would "tentatively identify" the ARIMA process via the acf/pacf function and then examine the residuals for possible outliers. Outliers can be Pulses i.e. one-time events OR seasonal pulses which are evidented by systematic outliers at some frequency say 12 for monthly data. A third type of outlier is where one has a contiguous set of pulses, each having the same sign and magnitude, this is called a step or level shift. After examining the residuals from the tentative ARIMA process one can then tentatively add the empirically identified deterministic structure to create a tentative combined model. Nor if the primary source of variation is one of the 4 kinds or "outliers" then one would be better served by identifying them ab initio (first) and then using the residuals from this "regression model" to identify the stochastic (ARIMA) structure. Now these two alternative strategies get a little more complicated when one has a "problem" where the ARIMA parameters change over time or the error variance changes over time due to a number of possible causes , possibly the need for weighted least squares or a power transform like logs/reciprocals etc.. Another complication/opportunity is how and when to form the contribution of user-suggested predictor series to form a seamlessly integrated model incorporating memory, causals and empirically identified dummy series. This problem is further exacerbated when one has trending series best modeled with indicator series of the form 0,0,0,0,1,2,3,4,.... or 1,2,3,4,5,...n and combinations of level shift series like 0,0,0,0,0,0,1,1,1,1,1. You might want to try and write such procedures in R , but life is short. I would be glad to actually solve your problem and demonstrate in this case how the procedure works, please post the data or send it to sales@autobox.com ADDITIONAL COMMENT AFTER RECEIVING/ANALYZING THE DATA/DAILY DATA FOR A FOREIGN EXCHANGE RATE/1765 VALUES STARTING 1/1/2007
|
|||||||||||
|
|
There are no ready to use robust counterpart to arima function in R (yet) --should they appear one, then i will be listed here--. Maybe an alternative is to down-weight those observations that are outlying wrt to a simple uni-variate outlier detection rule, but i don't see ready to use packages to carry weighted ARMA regression either. Another possible alternative would then be to winsorize the outlying points:
|
|||||||||
|
|
There is a sizable literature on robust time series models. Martin and Yohai are among the major contributors. The work goes back to the 1980s. I did some work on detecting outliers in time series myself but Martin was really one of the many contributors to both the detection of outliers and parameter estimation in the presence of outliers or heavytailed residuals in time series. Here is a link to a survey article on the topic with a list of over 100 references. It even includes my 1982 JASA paper. Here is a 2000 PhD thesis that covers the theory,methods and applications of robust time series analysis and includes a nice bibliography. http://www.collectionscanada.gc.ca/obj/s4/f2/dsk2/ftp03/NQ57354.pdf A link on software that includes some robust time series tools: |
|||||||
|
had an acf of
. Upon identifying an arma model of the form (1,1,0)(0,0,0) and a number of outliers the acf of the residuals indicates randomness since the acf values are very small. ! AUTOBOX identified a number of outliers
. The final model
included the need for a variance stabilization augmentation ala TSAY where variance changes in the residuals were identified and incorporated . The problem that you had with your automatic run was that the procedure you were using , like an accountant , believes the data rather than challenging the data via Intervention Detection a.k.a. Oulier Detection. I have posted a complete analysis 
