forecast {BGVAR} | R Documentation |
A function that computes forecasts based on a GVAR object.
fcast(gvar.obj,h=0,fhorz=8)
gvar.obj |
An objected fitted by function |
h |
For out-of-sample forecasts, set |
fhorz |
The forecast horizon. |
fcast
is a K times fhorz
times 5 -dimensional array that contains the 16%th, 25%th, 50%th, 75%th and 84% percentiles of the posterior predictive distribution.
xlgobal
is a matrix object of dimension T times N (T # of observations, K # of variables in the system).
fhorz
is the specified forecast horizon.
Martin Feldkircher and Florian Huber
library(BGVAR) data(eerData) model.sims<-bgvar(Data=eer.data,W=W.trade0012,saves=100,burns=100,plag=1,Cpu=4,prior="SIMS",save_thin=1,eigen=TRUE,logfile=FALSE,stats=TRUE) fcastM<-fcast(model.sims,h=0,fhorz=8)