I have time series with frequency=7. ndiffsfunction (https://www.rdocumentation.org/packages/forecast/versions/8.10/topics/ndiffs) suggests first order difference .

kpss.test from tseries package (https://www.rdocumentation.org/packages/tseries/versions/0.10-47/topics/kpss.test) suggests first order difference as well for (null="Trend"), while nsdiffs function tells that seasonal difference is not required. (https://www.rdocumentation.org/packages/forecast/versions/8.10/topics/nsdiffs). Time series ACF GRAPH of the series. ACF of time series

After the first order difference the following ACF and PACF graphs are constructed:

enter image description here

enter image description here

Time series itself after difference looks like this:enter image description here

It looks stationary and passes previously mentioned unit root tests, but ACF and PACF graphs made me thinking.

Seasonality doesn't appear to die out in ACF graph. My question is: what should I do with it ? Is seasonal difference required or should I just model it with ARIMA(p,1,q)(P,0,0)7 model, where p,q and P parameters are modeled to minimize AIC?


1 Answer 1


A primary issue with your 468 daily values is the presence of a number of anomalies. I took your data into AUTOBOX ( which I have helped to develop) and it simultaneously idenifies both the arima component ( 1,0,0)(1,0,0)7 and a number of evidented anomalies.

enter image description here presents the Actual/Fit and Forecast. The model is hereenter image description here and here enter image description here with statistics here enter image description here

The residual plot is here enter image description here

There is no need for differencing of any order. The software you are using "gets confused by anomalies" as it tacitely assumes there non-existence.

95% prediction limits allowing for future anomalies is here enter image description here . Note that if one were to assume that no anomalies will happen in the future then the 95% limits are much tighter and probably more misleading.

Hope this helps you and other readers.

  • $\begingroup$ Thanks. Really helpful ! $\endgroup$ Jan 14, 2020 at 13:33
  • $\begingroup$ If you like my answr , please accept it to close the question..... $\endgroup$
    – IrishStat
    Jan 14, 2020 at 20:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.