g.fevd: Generalized Forecast Error Variance Decomposition

g.fevdR Documentation

Generalized Forecast Error Variance Decomposition

Description

Computes the generalized forecast error variance decomposition of a VAR(p) for n.ahead steps.

Usage

g.fevd(x, n.ahead = 10, normalized = TRUE)

Arguments

x

Object of class ‘varest’ generated by VAR() from vars package.

n.ahead

Integer specifying the steps ahead.

normalized

a logical value indicating whether the result should be normalized to sum up to 1, see Details

Details

When normalized=FALSE this function computes the generalized forecast error variance decomposition proposed by Pesaran and Shin (1998) which takes the form:

\alpha _{ij}^{g}(h) = \frac{\sigma_{ii}^{-1}\sum_{l=0}^{h-1}(\mathbf{e'}_{i}\Theta _{l}\Sigma_{\varepsilon}\mathbf{e}_{j})^{2}}{\sum_{l=0}^{h-1}(\mathbf{e'}_{i}\Theta _{l}\Sigma _{\varepsilon }\Theta'_{l}\mathbf{e}_{i})}, \quad i,j = 0,1,2\ldots, K

Where \mathbf{\Theta}_{l}, are the coefficients matrix of the MA representation of the VAR model, \mathbf{\Sigma}_{\varepsilon} is the variance matrix of the reduced-form error vector \varepsilon, \sigma_{ii} is the standard deviation of the error term for the ith equation and e_{i} and e_{j} are selection vectors with ones as the ith element and zeros elsewhere.

If normalized=TRUE (the default value) then g.fevd computes:

\tilde{a}_{ij}^{g}(h) = \frac{a_{ij}^{g}(h)} {\sum_{j=1}^{K} a_{ij}^{g}(h)}

This fact implies the normalization is simply each entry of the generalized fevd divided by the its corresponding row sum.

Value

A list of length K holding the generalized forecast error variances as matrices. This is an object of class ‘varfevd’ from vars package.

Author(s)

Jilber Urbina

References

Pesaran, M. H. and Shin, Y. (1998). Generalized impulse response analysis in linear multivariate models. Economics Letters, 58(1):17-29.

Examples

library(vars)
data(stock.prices)
stocks <- stock.prices[,1:2]
VAR.1 <- VAR(stocks)
g.fevd(VAR.1, n.ahead = 10) # normalized 
g.fevd(VAR.1, n.ahead = 10, normalized=FALSE) # Not normalized 

Spillover documentation built on June 22, 2024, 12:25 p.m.