I want to combine a VAR model (with 2 variables) and an arma to forecast a serie.
I have this example :
Code: Select all
do time = prevstart,prevend-stepsahead
linreg(define=limpeq,noprint) limp estimstart time reslimp
# constant limp{1} lpib{0 2 3} dum200901
boxjenk(define=lpibeq,constant,ar=2,diffs=1,regressors,noprint) lpib estimstart time reslpib
# dum200804
vcv(matrix=v2,noprint)
# reslpib reslimp
group(vcv=v2) fullmodel lpibeq limpeq
forecast(model=fullmodel,from=time+1,to=time+stepsahead,stderrs=stderrs11,noprint,results=fore17)
compute rhat1(time+stepsahead)=fore17(2)(time+stepsahead)
end do