Estimate Univariate Gaussian or Student's t Mixture Autoregressive Model

Maximum likelihood estimation of univariate Gaussian Mixture Autoregressive (GMAR), Student's t Mixture Autoregressive (StMAR), and Gaussian and Student's t Mixture Autoregressive (G-StMAR) models, quantile residual tests, graphical diagnostics, forecast and simulate from GMAR, StMAR and G-StMAR processes. Leena Kalliovirta, Mika Meitz, Pentti Saikkonen (2015) , Mika Meitz, Daniel Preve, Pentti Saikkonen (2021) , Savi Virolainen (2021) .


The goal of uGMAR is to provide tools to work with Gaussian Mixture Autoregressive (GMAR), Student's t Mixture Autoregressive (StMAR) and Gaussian and Student's t Mixture Autoregressive (G-StMAR) models. G-StMAR is such model that some of its mixture components are similar to the ones that GMAR model uses and some similar to the ones that StMAR model uses. Most importantly uGMAR provides function fitGSMAR for two phase maximum likelihood estimation, but it also contains tools for quantile residual based model diagnostics, forecasting and simulations for example. With uGMAR it's easy to apply general linear constraints to the autoregressive parameters or to restrict them to be the same for regimes.


This is a basic example how to estimate a GMAR, StMAR or G-StMAR model to data. The data "VIX", that is used in this example, comes with the package (for details see ?VIX). The estimation process is computationally heavy and uses parallel computing.

fit12 <- fitGSMAR(data=VIX, p=1, M=2)
## Estimate StMAR(1, 1) model to VIX data
fit11t <- fitGSMAR(data=VIX, p=1, M=1, model="StMAR")
## Estimate G-StMAR(1, 1, 1) model to VIX data
fit12gs <- fitGSMAR(data=VIX, p=1, M=c(1, 1), model="G-StMAR")


  • Kalliovirta L., Meitz M. and Saikkonen P. 2015. Gaussian Mixture Autoregressive model for univariate time series. Journal of Time Series Analysis, 36, 247-266.
  • Meitz M., Preve D., Saikkonen P. 2018. A mixture autoregressive model based on Student's t-distribution. arXiv:1805.04010 [econ.EM].
  • There are currently no published references for G-StMAR model, but it's a straightforward generalization with theoretical properties similar to GMAR and StMAR models.


Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


3.4.0 by Savi Virolainen, 2 months ago

Browse source code at

Authors: Savi Virolainen [aut, cre]

Documentation:   PDF Manual  

Task views: Time Series Analysis

GPL-3 license

Imports Brobdingnag, parallel, pbapply, stats, gsl

Suggests testthat, knitr, rmarkdown

See at CRAN