|
MATLAB Code for Bayesian Inference in VARs,
TVP-VARs and TVP-FAVARs This website contains Matlab code for carrying out Bayesian inference in the models discussed in "Bayesian Multivariate Time Series Methods for Empirical Macroeconomics" by Gary Koop and Dimitris Korobilis. The user is referred to that monograph which is available here A manual which provides complete technical details (e.g. of posterior conditionals used in MCMC algorithms) is available here. The programs are set-up so as to produce the empirical illustrations in the monograph. Minor alterations are required (as indicated in the code) for different prior choices, data sets, etc. Note that code for each model is organized so that the main program is capitalized (e.g. BVAR_GIBBS.m) and functions and scripts called by the main program are in small letters. The easiest thing to do is download the main program and all scripts into one folder. Note also that most programs are set up to either load in a data set (which is provided) or generate artificial data. Users may also be interested in knowing that Estima has been running courses using my textbook Bayesian Econometrics (published by Wiley) and has created code using the computer package RATS. You can find find this code by clicking here. MATLAB Code for Bayesian VARs
MATLAB Code for TVP-VARs
MATLAB Code for Factor Models
MATLAB Code for Dynamic Model Averaging This code is provided for doing DMA as in the paper: Forecasting inflation using DMA by Koop and Korobilis. This code is not as clean as the other code on this website, has less explanatory material and may be unsuitable for use by novices. For those trying to replicate our paper, note that the published version of the paper uses a different data set. Also, the tables in the old working paper version linked above have a small error: they present sums of forecast errors squared rather than means. We do not offer any support for this code. Health
warnings:
The
programs are reasonably easy to use and follow the empirical examples in our
monograph. There is, however, a need for caution. A
knowledge of Bayesian econometrics is assumed, including recognition
of the potential importance of prior distributions, and MCMC methods are
inherently less robust than analytic econometric methods. There is no
in-built protection against misuse. These programs can be freely downloaded for academic purposes. Although every effort has been made to ensure that these programs are error free, we cannot guarantee this. If you find any errors, please let us know (Gary.Koop@strath.ac.uk or dikorobilis@googlemail.com). We do not offer any support or user help facilities for these programs. These programs were written in MATLAB release 2008 and there may be minor incompatibilities with earlier versions. Note in particular that our programs use cell arrays which were not included in very old versions of MATLAB.
|
|||
|
|