2
$\begingroup$

I was under the impression that Python Statsmodels SARIMAX with seasonal order parameters set to 0 will generate the same forecasts as ARIMA. But apparently the forecasts are wildly different. What implementation details am I missing here? I've attached here a snippet of results from my IPython Notebook.

Comparison of ARIMA and SARIMAX forecasts

$\endgroup$
  • 1
    $\begingroup$ Welcome to Cross Validated. In general, it would be helpful if you included your data / code / output in text form so that people can easily try to replicate your results. $\endgroup$ – Candamir Nov 1 '18 at 18:39
  • $\begingroup$ In addition to @Candamir's comment, text format works better for people with impaired vision: see this Meta thread. $\endgroup$ – Richard Hardy Nov 2 '18 at 8:04
2
$\begingroup$

In Statsmodels, ARIMA and SARIMAX are fitted using different methods, even though in theory they are from the same family of models.

If you look at the code, you will notice that ARIMA is under statsmodels.tsa.arima_model.ARIMA, using the traditional ARIMA formulation, while SARIMAX is under sm.tsa.statespace.SARIMAX and is using the statespace formulation of ARIMA models, and they use different approaches for fitting the models. In fact even within in SARIMAX, there are two different approaches that can be specified which lead to slightly different forecasts.

$\endgroup$
  • $\begingroup$ Thank you for your answer. Then how would you suggest aligning the results from both packages. Is one superior over another? For my project, I'm first finding seasonality using PACF. I originally intended to use SARIMA if there was clear seasonality and ARIMA otherwise. So, how could I use "ARIMA" through SARIMAX package? I highly appreciate your help. $\endgroup$ – Jimit Bavishi Nov 1 '18 at 17:11
  • $\begingroup$ "Is one superior to the other?" I don't know, it would depend on your data. I would however recommend using one package for both seasonal and non seasonal if you plan on doing consistent model selection (meaning if you are going to compare the performance of a seasonal model and a non seasonal model) - so yeah just go with SARIMAX. $\endgroup$ – Skander H. Nov 1 '18 at 17:52
  • $\begingroup$ Ok now I get it. Thank you very much for your kind advice :) $\endgroup$ – Jimit Bavishi Nov 1 '18 at 18:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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