0
$\begingroup$

I have just started using statsmodels.tsa.arima_model.ARMA.fit and I am trying to fit a simple AR1 process, i.e. $$X_t = c + a_1 X_{t-1} + e_t,$$ but the value for a constant returned in statsmodels.tsa.arima_model.ARMAResults seems to be way off (I do set trend='c' option). It appears that instead of the constant $c$, what returned is the unconditional mean $c/(1-a_1)$.

Is this indented behavior and where is it documented (I couldn't find it on the package's website)?

$\endgroup$
4
  • 1
    $\begingroup$ The model is parametrized as a regression with ARMA errors, including for the constant (i.e. $X_t = c + a_1 (X_{t-1}-c) + e_t$). The documentation says this and the equation written there is consistent with that. The documentation also says that it fits an ARMAX model (what you've written), but that is not true. $\endgroup$
    – Chris Haug
    Commented Apr 3, 2020 at 14:00
  • $\begingroup$ @ChrisHaug Thank you for your comment, but I am not sure that I understand your point. I could only find the following in the Notes "If exogenous variables are given, then the model that is fit is .. This is the regression model with ARMA errors". So, according to this Note, the regression model representation is only used when there are exogenous varaibles, but I don't have any. $\endgroup$
    – Confounded
    Commented Apr 3, 2020 at 14:22
  • 1
    $\begingroup$ You do have an exogenous variable: it's a column of ones. It makes sense to use the same parametrization consistently in all cases (whether the "exogenous variable" is constant or not). $\endgroup$
    – Chris Haug
    Commented Apr 3, 2020 at 15:21
  • $\begingroup$ @ChrisHaug I see. Thank you. If you want to convert this to a short answer, then I can accept it and close the question. $\endgroup$
    – Confounded
    Commented Apr 3, 2020 at 17:05

0

Your Answer

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

Browse other questions tagged or ask your own question.