[Paper Review] Modeling Univariate and Multivariate Stochastic Volatility in R with stochvol and factorstochvol
This paper introduces two R packages, stochvol and factorstochvol, for Bayesian estimation of univariate and multivariate stochastic volatility (SV) models using efficient MCMC sampling via C++ integration. It extends prior software by enabling heavy-tailed errors, leverage effects, linear mean models, and multivariate factor SV models, with user-friendly interfaces and predictive inference tools for financial time series.
Stochastic volatility (SV) models are nonlinear state-space models that enjoy increasing popularity for fitting and predicting heteroskedastic time series. However, due to the large number of latent quantities, their efficient estimation is non-trivial and software that allows to easily fit SV models to data is rare. We aim to alleviate this issue by presenting novel implementations of four SV models delivered in two R packages. Several unique features are included and documented. As opposed to previous versions, stochvol is now capable of handling linear mean models, heavy-tailed SV, and SV with leverage. Moreover, we newly introduce factorstochvol which caters for multivariate SV. Both packages offer a user-friendly interface through the conventional R generics and a range of tailor-made methods. Computational efficiency is achieved via interfacing R to C++ and doing the heavy work in the latter. In the paper at hand, we provide a detailed discussion on Bayesian SV estimation and showcase the use of the new software through various examples.
Motivation & Objective
- Address the lack of accessible, efficient software for estimating stochastic volatility (SV) models in practice.
- Extend the existing stochvol package to support conditionally heavy-tailed innovations, leverage effects, and linear mean regressors in univariate SV models.
- Develop a new R package, factorstochvol, to enable Bayesian estimation of multivariate factor stochastic volatility models.
- Provide a user-friendly, computationally efficient interface for researchers and practitioners to estimate, visualize, and predict with SV models.
- Enable high-dimensional posterior inference and model selection through hierarchical shrinkage priors and eigenvalue diagnostics in multivariate settings.
Proposed method
- Implement univariate SV models with normal, Student’s t, leverage, and combined leverage-t error distributions using state-space formulations.
- Integrate C++ code via R's Rcpp interface to accelerate MCMC sampling, especially for high-dimensional latent volatility paths.
- Use Gibbs sampling with efficient conjugate priors and Metropolis-Hastings updates for latent states and hyperparameters.
- Incorporate hierarchical shrinkage priors (e.g., normal-gamma) in factorstochvol to enable automatic factor selection and dimension reduction.
- Provide generic R methods (e.g., summary, plot, predict) for seamless integration with standard R workflows.
- Use eigenvalue diagnostics of the factor loading matrix to guide automatic factor selection in multivariate models.

Experimental results
Research questions
- RQ1How can univariate stochastic volatility models with heavy-tailed errors and leverage effects be efficiently estimated in R?
- RQ2What is the impact of integrating linear mean regressors on the estimation and interpretability of SV models?
- RQ3How can multivariate stochastic volatility be modeled efficiently using a factor structure in a Bayesian framework?
- RQ4What are effective methods for selecting the number of factors in high-dimensional multivariate SV models?
- RQ5How can predictive inference for covariance, correlation, and future observations be efficiently performed in multivariate SV models?
Key findings
- The stochvol package now supports Bayesian estimation of univariate SV models with conditional heavy tails, leverage effects, and linear mean components, significantly broadening its applicability.
- The new factorstochvol package enables efficient Bayesian estimation of multivariate factor SV models using hierarchical shrinkage priors and automatic factor selection via eigenvalue diagnostics.
- MCMC sampling performance is substantially improved through C++ integration, allowing fast posterior simulation even for high-dimensional volatility paths.
- Predictive inference for covariance and correlation matrices is feasible and well-supported via the predcor() and predcov() functions, with posterior predictive means and standard deviations available.
- The packages provide intuitive visualization tools and predictive diagnostics, such as log predictive scores, enabling out-of-sample model evaluation.
- Empirical examples demonstrate that the models can capture time-varying correlations and dynamic volatility with high accuracy, especially in financial time series with heavy tails and leverage.

Better researchstarts right now
From reading papers to final review, dramatically reduce your research time.
No credit card · Free plan available
This review was created by AI and reviewed by human editors.