Time series data of which columns indicate the variables
required
lag
int
VAR lag, by default 1
1
n_chain
int
Number of MCMC chains, by default 1
1
n_iter
int
Number of MCMC total iterations, by default 1000
1000
n_burn
int
MCMC burn-in (warm-up), by default floor(n_iter / 2)
None
n_thin
int
Thinning every n_thin-th iteration, by default 1
1
bayes_config
_BayesConfig
Prior configuration, by default SsvsConfig()
SsvsConfig()
cov_config
(LdltConfig, SvConfig)
Prior configuration for covariance matrix, by default LdltConfig()
'LdltConfig'
intercept_config
InterceptConfig
Prior configuration for constant term, by default InterceptConfig()
InterceptConfig()
fit_intercept
bool
Include constant term in the model, by default True
True
minnesota
bool
If True, apply Minnesota-type group structure, by default True
True
verbose
bool
If True, print progress bar for MCMC, by default False
False
n_thread
int
Number of OpenMP threads, by default 1
1
Attributes
Name
Type
Description
coef_
ndarray
VHAR coefficient matrix.
intercept_
ndarray
VHAR model constant vector.
n_features_in_
int
Number of variables.
References
.. [1] Carriero, A., Chan, J., Clark, T. E., & Marcellino, M. (2022). Corrigendum to “Large Bayesian vector autoregressions with stochastic volatility and non-conjugate priors” [J. Econometrics 212 (1)(2019) 137–154]. Journal of Econometrics, 227(2), 506-512. .. [2] Chan, J., Koop, G., Poirier, D., & Tobias, J. (2019). Bayesian Econometric Methods (2nd ed., Econometric Exercises). Cambridge: Cambridge University Press. .. [3] Cogley, T., & Sargent, T. J. (2005). Drifts and volatilities: monetary policies and outcomes in the post WWII US. Review of Economic Dynamics, 8(2), 262–302. .. [4] Gruber, L., & Kastner, G. (2022). Forecasting macroeconomic data with Bayesian VARs: Sparse or dense? It depends! arXiv. .. [5] Huber, F., Koop, G., & Onorante, L. (2021). Inducing Sparsity and Shrinkage in Time-Varying Parameter Models. Journal of Business & Economic Statistics, 39(3), 669–683. .. [6] Korobilis, D., & Shimizu, K. (2022). Bayesian Approaches to Shrinkage and Sparse Estimation. Foundations and Trends® in Econometrics, 11(4), 230–354. .. [7] Ray, P., & Bhattacharya, A. (2018). Signal Adaptive Variable Selector for the Horseshoe Prior. arXiv.
Apply restriction to forecasting, by default False
False
med
bool
Use median instead of mean to get point forecast, by default False
False
sv
bool
Use SV term in case of SV model, by default True
True
Returns
Name
Type
Description
dict
Density forecasting results - “forecast” (ndarray): Posterior mean of forecasting - “se” (ndarray): Standard error of forecasting - “lower” (ndarray): Lower quantile of forecasting - “upper” (ndarray): Upper quantile of forecasting - “lpl” (float): Average log-predictive likelihood
Apply restriction to forecasting, by default False
False
med
bool
Use median instead of mean to get point forecast, by default False
False
sv
bool
Use SV term in case of SV model, by default True
True
Returns
Name
Type
Description
dict
Density forecasting results - “forecast” (ndarray): Posterior mean of forecasting - “se” (ndarray): Standard error of forecasting - “lower” (ndarray): Lower quantile of forecasting - “upper” (ndarray): Upper quantile of forecasting
Apply restriction to forecasting, by default False
False
med
bool
Use median instead of mean to get point forecast, by default False
False
sv
bool
Use SV term in case of SV model, by default True
True
Returns
Name
Type
Description
dict
Density forecasting results - “forecast” (ndarray): Posterior mean of forecasting - “se” (ndarray): Standard error of forecasting - “lower” (ndarray): Lower quantile of forecasting - “upper” (ndarray): Upper quantile of forecasting - “lpl” (float): Average log-predictive likelihood