g.fevd {Spillover} | R 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 ‘ |
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:
Where , are the coefficients matrix of the MA representation of the VAR model,
is the variance matrix of the reduced-form error vector
,
is the standard deviation of the error term for the
equation and
and
are selection vectors with ones as the ith element and zeros elsewhere.
If normalized=TRUE
(the default value) then g.fevd
computes:
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