View source: R/do_everything.R
do_everything_svar | R Documentation |
Similarly to other do_everything_*
functions, do_everything_svar
estimates the benchmark SVAR model and the associated IRFs with error bands.
Note that the data object is similar as in the other do_everything_*
functions,
i.e. the data matrix contains all the variables and those included in the
SVAR are indexed with a vector (see below).
do_everything_svar(df, k, nrep = 500, h = 50, ci = 0.68)
df |
list containing items:
|
k |
VAR order |
nrep |
number of replications in the bootstrap |
h |
h-step ahead IRFs |
ci |
confidence interval level for the IRFs, defaults to 0.68 The estimated models are identified recursively using Cholesky decomposition of the residual covariance matrix. As a default, the function returns the impulse responses to the third shock, the size of which is normalized to 0.5 on impact. For changing the shock of interest (i.e. not the third), and the normalization constant, the user should include a vector of length 2 in the data object with name "shock_ix" with the position of the shock of interest as the first and the normalization constant as the second element. |
An (h+1 x 3 x q)
array corresponding to the structurally identified IRFs
McCracken, M. W., & Ng, S. (2016). FRED-MD: A monthly database for macroeconomic research. Journal of Business & Economic Statistics, 34(4), 574-589.
# example from the paper: the data object is similar to the
# other do_everything_* function, i.e. the data matrix
# is the whole data
FRED_light$int_ix <- c(6, 105, 77, 95)
est_obj <- do_everything_svar(FRED_light, k = 9, nrep = 500, h = 50, ci = .68)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.