gfevd {BGVAR}R Documentation

Generalized Forecast Error Variance Decomposition

Description

This function calculates a complete generalized forecast error variance decomposition (GFEVDs) based on generalized impulse response functions akin to Lanne-Nyberg (2016). The Lanne-Nyberg (2016) corrected GFEVD sum up to unity.

Usage

gfevd(x, n.ahead=24, running=TRUE, applyfun=NULL, cores=NULL, verbose=TRUE)

Arguments

x

an object of class bgvar.

n.ahead

the forecast horizon.

running

Default is set to TRUE and implies that only a running mean over the posterior draws is calculated. A full analysis including posterior bounds is likely to cause memory issues.

applyfun

Allows for user-specific apply function, which has to have the same interface than lapply. If cores=NULL then lapply is used, if set to a numeric either parallel::parLapply() is used on Windows platforms and parallel::mclapply() on non-Windows platforms.

cores

Specifies the number of cores which should be used. Default is set to NULL and applyfun is used.

verbose

If set to FALSE it suppresses printing messages to the console.

Value

Returns a list with two elements

GFEVD

a three or four-dimensional array, with the first dimension referring to the K time series that are decomposed into contributions of K time series (second dimension) for n.ahead forecast horizons. In case running=TRUE only the posterior mean else also its 16% and 84% credible intervals is contained in the fourth dimension.

xglobal

used data of the model.

Author(s)

Maximilian Boeck, Martin Feldkircher

References

Lanne, M. and H. Nyberg (2016) Generalized Forecast Error Variance Decomposition for Linear and Nonlinear Multivariate Models. Oxford Bulletin of Economics and Statistics, Vol. 78(4), pp. 595-603.

See Also

bgvar.

Examples



[Package BGVAR version 2.5.7 Index]