cultivars.multivariate.large_dim.bayesian#

The conjugate Bayesian VAR: an exact posterior, and the number that ranks priors.

This module is the conjugate core of the large-dimensional family. It defines the public pair BVAR and BVARResult and nothing else; the estimator itself lives one layer down. A Bayesian VAR earns its place here because shrinkage is what makes a large system estimable at all: under the Normal-inverse-Wishart form of the Minnesota prior a hundred-variable VAR is routine (Banbura, Giannone & Reichlin 2010), and the prior’s tightness, not the sample size, sets the effective dimensionality. The posterior over coefficients and innovation covariance is exact, drawn rather than approximated, so every band the result reports is a posterior statement, not an asymptotic one, and every propagated object – impulse responses, the predictive – is propagated draw by draw.

Two design commitments distinguish the surface. First, conjugacy is verified, not assumed. The prior’s coefficient variances must factor as an equation-scale times a column-profile, \(\sigma_i^2 \cdot \omega_j\), which is the Minnesota structure with the cross-equation weight pinned at one. A prior that keeps Litterman’s extra cross-variable shrinkage is refused at fit with directions to the per-equation point path, because the two are different estimators with different claims, not the same object with different numbers; the priors this model refuses are what gibbs.py exists to accept. Second, the scalar the result reports is the log marginal likelihood of the sample, computed in closed form with any dummy-observation content divided out (Giannone, Lenza & Primiceri 2015). Differences of that number across priors are log Bayes factors, which is what hyperparameter choice should maximize, and hierarchical.py is built on this model to do exactly that. There is deliberately no llf and no information criterion on the result: a posterior has neither, and the marginal likelihood is the honest replacement.

Layout. BVAR is a thin specification class: it substitutes the default prior, guards the order, and delegates to _BayesianVectorAutoRegressionModel._fit_conjugate(), which assembles the design and the prior’s dummy rows, runs the closed-form update through _solvers._conjugate_posterior, and packs the numerics into a _VectorConjugateFit. BVARResult._from_fit() joins that packed fit with the specification into the frozen public record. The result’s own code is the propagation – lag-stack slicing, companion powers for the responses, draw-by-draw simulation for the predictive – and the summary; summary(), convergence(), simulate(), and posterior_replications() come from the shared mixins. The other Bayesian VARs in this package share the layout and differ in the innovation model or the sampler: student.py for Student-t innovations, volatility.py for stochastic volatility, gibbs.py for non-conjugate priors, hierarchical.py for estimated tightness.

References

Litterman, R. B. (1986). Forecasting with Bayesian vector autoregressions: Five years of experience. Journal of Business & Economic Statistics, 4(1), 25-38.

Doan, T., Litterman, R., & Sims, C. (1984). Forecasting and conditional projection using realistic prior distributions. Econometric Reviews, 3(1), 1-100.

Kadiyala, K. R., & Karlsson, S. (1997). Numerical methods for estimation and inference in Bayesian VAR-models. Journal of Applied Econometrics, 12(2), 99-132.

Banbura, M., Giannone, D., & Reichlin, L. (2010). Large Bayesian vector auto regressions. Journal of Applied Econometrics, 25(1), 71-92.

Giannone, D., Lenza, M., & Primiceri, G. E. (2015). Prior selection for vector autoregressions. Review of Economics and Statistics, 97(2), 436-451.

Classes#

BVAR

Conjugate Normal-inverse-Wishart Bayesian VAR, after Banbura, Giannone and Reichlin.

BVARResult

A fitted conjugate Bayesian VAR: an exact posterior over \((B, \Sigma)\).