Hello everyone,
I was interested in calculating rolling autoregressive coefficients (AR(1)) for a period of 10 years window for multiple countries at once, and I calculated it using rangestat wherein I regressed inflation on its first lag for all the countries, the command is “rangestat (reg) inflation inflation_lag , interval ( Year -9 0) by (Country)” however when I used the rolling option in Stata for calculating rolling regression which is “rolling, window(10): arima inflation, ar(1) ” and then doing it separately for all the countries since "rolling" does not allow the “by” option, the results are varying, please guide further as to which method should be used or where I may be wrong. I am using Stata 17.
Thank You
I was interested in calculating rolling autoregressive coefficients (AR(1)) for a period of 10 years window for multiple countries at once, and I calculated it using rangestat wherein I regressed inflation on its first lag for all the countries, the command is “rangestat (reg) inflation inflation_lag , interval ( Year -9 0) by (Country)” however when I used the rolling option in Stata for calculating rolling regression which is “rolling, window(10): arima inflation, ar(1) ” and then doing it separately for all the countries since "rolling" does not allow the “by” option, the results are varying, please guide further as to which method should be used or where I may be wrong. I am using Stata 17.
Thank You
Comment