A function to forecast forwards using MCMC samples from the bayesGARCH function from the bayesGARCH package.
fcastGARCH(y, parmat, l)
forcast log returns and also forecast y
vector of log-returns used in fitting the model via bayesGARCH
a matrix of MCMC samples from the bayesGARCH function e.g. "out$chain1" where "out" is the output of the fitted model and "chain1" is the desired chain
number of lags to forecast forward
Suggest thinning MCMC samples to get, say 1000, posterior samples (this can be done post-hoc)
See also the function lr2fact for converting log-returns to a factor. Apply this to the output of fcastGARCH in order to undertake forecasting on the scale of the original series (i.e. not the log returns). Quantiles may be computed across the MCMC iterations and then all one needs to do is to multiply the result by the last observed value in the original series (again, not the log returns)