Autolagselect for series
Posted: Mon Sep 14, 2015 8:50 pm
Dear Tom,
I have a quesiton about how to display the AIC optimal lags for each series in a table. I have written the code:
dofor i = DEPENDENT RGDP UR CPI TR3M TR10Y CRE HPI OIL BAA SP500
@ADFAutoSelect(det=NONE, crit=AIC, maxlag=6, TITLE="Dickey-Fuller Unit Root Test (NONE):" + %l(i), print) i sambeg samend
compute Lagselect = %%LAGS
dis 'Lags:' %l(i) 'Lagselect = ' %%LAGS
end dofor
But then need to create a table where I have series in one column and optimal lags numbers in another column. Somehow I cannot find the syntax to use it.
Thank you very much.
I have a quesiton about how to display the AIC optimal lags for each series in a table. I have written the code:
dofor i = DEPENDENT RGDP UR CPI TR3M TR10Y CRE HPI OIL BAA SP500
@ADFAutoSelect(det=NONE, crit=AIC, maxlag=6, TITLE="Dickey-Fuller Unit Root Test (NONE):" + %l(i), print) i sambeg samend
compute Lagselect = %%LAGS
dis 'Lags:' %l(i) 'Lagselect = ' %%LAGS
end dofor
But then need to create a table where I have series in one column and optimal lags numbers in another column. Somehow I cannot find the syntax to use it.
Thank you very much.