2
$\begingroup$

It is my understanding of the AIC formula that: $$ AIC = -2\log(L) + 2m $$ where $m =$ number of parameters.

I am wondering how to determine the value of $m$ in AIC for the following models:

  • AR(1)
  • MA(1)
  • ARMA(1,1)
  • ARIMA(1,1,1)
  • Seasonal ARIMA(1,1,1)(1,1,1)12

I believe for an AR(p) model $m=p$,
MA(q) model $m=q$,
ARMA(p,q) model $m = p+q$,
ARIMA(p,d,q) model $m=p+q$
and for a seasonal ARIMA(p,d,q)(P,D,Q)s model $m = p+q+P+Q+1$.

Could you please let me know if this is correct?
And if not, how would I determine the correct number of parameters ($m$)?

$\endgroup$
  • 1
    $\begingroup$ I think it's mostly right, although perhaps +1 should be added everywhere (except for SARIMA) because of the fact that also $\sigma^2_{\varepsilon}$ is being estimated extra to the AR and MA coefficients. But I am not sure. Also, what is your logic behind the +1 for SARIMA but not in the other cases? $\endgroup$ – Richard Hardy Apr 21 '17 at 6:54
  • $\begingroup$ @RIchard The +1 is correct but nothing is lost by ignoring it with AIC (since they all have it). For BIC and AICc though, you can't just leave it out. Also you usually have a mean but for differenced models you often don't $\endgroup$ – Glen_b -Reinstate Monica Apr 21 '17 at 7:00
  • $\begingroup$ @Glen, thanks. I presume you mean that nothing is lost in comparisons where such constants cancel out. But if one takes AIC of a given (as opposed to chosen) model and interprets it as the expected likelihood, then it starts to matter, right? $\endgroup$ – Richard Hardy Apr 21 '17 at 7:02
  • $\begingroup$ Yes, nothing is lost in comparisons when it's common to both. $\endgroup$ – Glen_b -Reinstate Monica Apr 21 '17 at 7:27
  • $\begingroup$ I actually thought the +1 was for the seasonal component of the seasonal ARIMA model. My interest is finding the exact number of parameters, so I do not want to leave out any additional parameters just for the ease of comparison. $\endgroup$ – niallStudent Apr 21 '17 at 11:51
3
$\begingroup$

I think you are almost right. For a general SARIMA model, it would be $$ m=p+q+P+Q+1 $$ where $+1$ comes from the fact that also $\sigma^2_{\varepsilon}$ is being estimated extra to the AR and MA coefficients.

For submodels such as AR, MA or ARIMA, just set the appropriate coefficients to zero. Thus $m=p+1$ for AR; $m=q+1$ for MA; and $m=p+q+1$ for ARIMA.

(As @Glen_b notes, the $+1$ is not so important when we compare AICs across models; when we take a difference between two AICs, the $+1$ in each cancels out.)

$\endgroup$
  • $\begingroup$ Thank you for your answer, I was testing your answer on R by running the following code: arima(dowjones,c(1,0,0)). This resulted in R outputting a log likelihood of -49.86 and an aic of 105.72. Doing some basic maths with the AIC formula and the loglikelihood, R output is suggesting that the number of parameters is 3 rather than 2 (your suggested answer). $\endgroup$ – niallStudent Apr 21 '17 at 11:43
  • $\begingroup$ I don't know if the reported likelihood is correct. It will be correct up to a constant but probably not beyond that. I find it annoying, but that is how most of the functions do it... $\endgroup$ – Richard Hardy Apr 21 '17 at 11:55
  • $\begingroup$ I believe it is correct since -49.86*-2 = 99.72. Indicating exactly 6 needs to be added on to achieve the correct AIC. This indicates that the correct number of parameters is 3. Should I perhaps post this as a separate question with the R code included? $\endgroup$ – niallStudent Apr 21 '17 at 15:24
  • $\begingroup$ Perhaps the constant counts as a parameter as well? I don't know... $\endgroup$ – Richard Hardy Apr 21 '17 at 15:45

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.