I am fitting an Error Correction Model with two monthly price time series. In Stata I am using the varsoc command to determine the number of lags that are appropriate.

varsoc variable1 variable2

If I run varsoc with the default 4 maxlags, the suggested lag length using AIC/FPE is 3. However, if I run varsoc with maxlag(12) option, 12 lags are suggested. If I use maxlag(20), 13 lags are suggested.

  1. Why is varsoc so sensitive to the number of maxlag?
  2. If this is the case, how should I decide which maxlag to use? Running varsoc on the time series seperately yields 8 lags (if a larger maxlag is chosen).
  • 4
    $\begingroup$ Regarding the close vote, I don't think this question belongs to Stack Overflow because the issue seems to be statistical rather than programming-specific. Regarding error correction model, it seems to be vector error correction model (VECM) rather than single-equation error correction model (ECM); if this is so, I suggest editing the post accordingly. $\endgroup$ – Richard Hardy Dec 17 '15 at 16:58
  • $\begingroup$ Low, let me know if something is still unclear. Otherwise, consider accepting the answer. $\endgroup$ – Richard Hardy Feb 10 '17 at 11:03

The function varsoc considers full (unrestricted) VAR or VECM models with lags 1 through maxlag. It may happen that the user sets maxlag to a relatively low number such that the best model in AIC or FPE sense is excluded. This seems to be happening for maxlag(4) and maxlag(12). However, I suspect the AIC- or FPE-suggested lag order would not grow infinitely. It might just be the case that a VAR(13) model fits the data relatively better than a VAR(3) or VAR(12), even after penalizing the number of parameters in the model. You should also not be surprised that a VAR(3) is selected rather than a VAR(4) when you set maxlag(4). AIC and FPE need not decrease monotonically until the "optimal" lag and increase monotonically after that.

If you think that a VAR(13) is nonsensical and the lag order is too high, then perhaps you have excluded a relevant variable or neglected seasonality or a structural change, or the model suffers from yet another fault.


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.