Page 1 of 1
Var forecasting
Posted: Fri May 22, 2015 7:26 pm
by sanjeev
I am using the runtheil program for forecasts. However when I am generating say 8 forecasts the program is displaying the use of 9 observations in the calculation of the summary statistics of the forecasts. I am attaching the program code will be grateful for help.
Re: Var forecasting
Posted: Sat May 23, 2015 8:06 am
by TomDoan
The syntax on this is wrong:
theil(setup,model=bvar) 1 12 2013:05,2015:02
I assume that should be just 2015:2 (the last period of data) at the end.
Re: Var forecasting
Posted: Sun May 24, 2015 8:27 pm
by sanjeev
I have made the changes as suggested . However the results are the same. The number of observations in the summary statistics varies from the number of forecasts generated. Maybe if I send the data file one might see it clearly. waiting for your suggestion.
Re: Var forecasting
Posted: Mon May 25, 2015 9:12 am
by TomDoan
You apparently don't have comparison data after 2014:12 (or you can't compute forecasts after 2014:12 due to missing data):
Code: Select all
2014:12 4.135309594 8.915746146 0.232811676 -1.96379672
4.139158578 8.264320000 0.201959135 -1.96772947
2015:01 NA NA NA NA
NA NA NA NA
2015:02 NA NA NA NA
NA NA NA NA
so you will get 2 fewer than you're expecting for the longer horizons.
Re: Var forecasting
Posted: Mon May 25, 2015 11:03 pm
by sanjeev
Yes that is correct but even if i change my forecast time period so that it ends at 2014:12 the summary statistics are showing me one observation more than the forecasts as calculated. That is while 20 one period ahead forecasts are calculated, the number of observations in the summary statistics of forecasts is shown as 21.
Re: Var forecasting
Posted: Tue May 26, 2015 7:47 am
by TomDoan
You probably didn't count that extra THEIL instruction after the ESTIMATE:
theil(setup,model=bvar) 1 12 2013:05,2015:02
estimate(noprint) * 2013:04
theil
do time=2013:05;2015:02
Kalman
theil(print) time
end do time