Learn R Programming

bvarsv (version 1.0)

bvarsv-package: Bayesian Analysis of a Vector Autoregressive Model with Stochastic Volatility and Time-Varying Parameters

Description

R/C++ implementation of the Primiceri (2005) model, which allows for both stochastic volatility and time-varying regression parameters. This is a very flexible framework which nests several other models as special cases. The package contains functions for computing posterior predictive distributions from the model, based on an input data set.

Arguments

Details

ll{ Package: bvarsv Type: Package Version: 1.0 Date: 2014-08-14 License: GPL (>= 2) URL: https://sites.google.com/site/fk83research/code }

References

The code incorporates the recent corrigendum by Del Negro and Primiceri (2014), which points to an error in the original MCMC algorithm of Primiceri (2005). Del Negro, M. and G. Primiceri (2014): ``Time Varying Structural Vector Autoregressions and Monetary Policy: A Corrigendum'', working paper, Northwestern University. Koop, G. and D. Korobilis (2010): ``Bayesian Multivariate Time Series Methods for Empirical Macroeconomics'', Foundations and Trends in Econometrics 3, 267-358. Accompanying Matlab code available at https://sites.google.com/site/dimitriskorobilis/matlab. Primiceri, G. (2005): ``Time Varying Structural Vector Autoregressions and Monetary Policy'', Review of Economic Studies 72, 821-852.

Examples

Run this code
# Load US macro data
data(usmacro)

# Estimate trivariate model using Primiceri's prior choices (default settings)
set.seed(5813)
bv <- bvar.sv.tvp(usmacro)

Run the code above in your browser using DataLab