Skip to main content

Abstract

The multivariate continuous-time ARMA model is a tool to capture the relationship between multivariate time series. In this chapter, a particular computational implementation of a stationary normal multivariate CARMA model is illustrated. A review of a parametric setup is shown. Data are assumed to be observed at irregular non-synchronous discrete time points. The computational approach for calculating the likelihood is based on a state-space form and the Kalman filter. Interpretation of the CARMA models is discussed. The computational algorithms have been implemented in R packages. Examples of a simulated and real data are shown.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 79.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 99.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info
Hardcover Book
USD 109.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Helgi Tómasson .

Editor information

Editors and Affiliations

Appendices

Appendix 1: Implementation of Kalman Filter

The likelihood function is calculated by use of the Kalman-filter recursions. The dynamics are defined by Eqs. (15.15) and (15.16). The sample selection matrix C contains 1 at coordinate ii when coordinate i is observed at time point t i and is zero otherwise. Given information at time t i−1,the optimal estimate of the state vector is X(t i−1|t i−1) and the corresponding variance matrix P X(t i−1|t i−1). The prediction step is:

$$\displaystyle \begin{aligned} \begin{array}{rcl} \boldsymbol{X}(t_i|t_{i-1})&\displaystyle =&\displaystyle \boldsymbol{e}^{A(t_i-t_{i-1})}\boldsymbol{X}(t_{i-1}|t_{i-1}),\\ P(t_i|t_{i-1})&\displaystyle =&\displaystyle \boldsymbol{e}^{A(t_i-t_{i-1})}P(t_{i-1}|t_{i-1})\boldsymbol{e}^{A'(t_i-t_{i-1})}\\ &\displaystyle &\displaystyle +\Gamma_{\boldsymbol{X}}(0)-\boldsymbol{e}^{A(t_i-t_{i-1})} \Gamma_{\boldsymbol{X}}(0) \boldsymbol{e}^{A'(t_i-t_{i-1})},\\ \boldsymbol{F}(t_i|t_{i-1})&\displaystyle =&\displaystyle \boldsymbol{C}(t_i)P(t_i|t_{i-1})\boldsymbol{C}'(t_i),\\ \hat{\boldsymbol{y}}(t_i|t_{i-1})&\displaystyle =&\displaystyle \boldsymbol{C}(t_i)\boldsymbol{X}(t_i|t_{i-1}). \end{array} \end{aligned} $$

The corresponding updating equations:

$$\displaystyle \begin{aligned} \begin{array}{rcl} \boldsymbol{X}(t_i|t_i)&\displaystyle =&\displaystyle \boldsymbol{X}(t_i|t_{i-1})+P(t_i|t_{i-1})\boldsymbol{C}(t_i)\boldsymbol{F}^*(t_i|t_{i-1})(\boldsymbol{y}(t_i) -\hat{\boldsymbol{y}}(t_i|t_{i-1})),\\ P(t_i|t_i)&\displaystyle =&\displaystyle P(t_i|t_{i-1})-P(t_i|t_{i-1})\boldsymbol{C}(t_i)\boldsymbol{F}^*(t_i|t_{i-1})\boldsymbol{C}'(t_i)P(t_i|t_{i-1}). \end{array} \end{aligned} $$

Here F (t i|t i−1) denotes a generalised inverse of F(t i|t i−1). The normal likelihood is easily calculated in the non-synchronous case, because at each time point, observed data are essentially univariate. The observed value is compared to its predicted value. The corresponding variance is the non-zero element of element of F(t i|t i−1)).

Appendix 2: A Brief Description of the R Packages

The R packages are based on objects. In the ctarmaRcpp package, a ctarma object contains the observed series, y=y(t 1), …, y(t n); the time points of observations, tt=t 1, …, t n; the AR parameters, a=(α 1, …, α p); the MA parameters b=(β 1, …, β q); and the standard deviation of the innovations, sigma=σ.

 names(ctarma1) [1] "y"     "tt"    "a"     "b"     "sigma" >ctarma1$y[1:5] [1] -1.330619311  0.215559470  0.218091305 -0.004512067 -0.124261787 >ctarma1$tt[1:5] [1] 0.08360339 0.51537932 0.65898476 0.77687963 0.86278019 >> ctarma1$a [1]  2 40 > ctarma1$b [1] 1.00 0.15 >ctarma1$sigma [1] 8

The package ctarmaRcpp contains functions on ctarma objects for, e.g., calculating and maximising the log-likelihood. Spectral densities can also be calculated and plotted.

In the multivariate mctarmaRcpp, a second compatible (same number of AR and MA coefficients) ctarma object ctarma2 can be merged with ctarma1 into a bivariate mctarma object.

> cc=cbind(as.list(ctarma0),as.list(ctarma2)) > mctobj=mctobjnonsync(cc) > mctobj$A     [,1] [,2] [,3] [,4] [1,]   -2    0    1    0 [2,]    0   -2    0    1 [3,]  -40    0    0    0 [4,]    0  -40    0    0 > mctobj$R      [,1] [,2] [1,] 0.15 0.00 [2,] 0.00 0.15 [3,] 1.00 0.00 [4,] 0.00 1.00 > mctobj$sigma      [,1] [,2] [1,]   64    0 [2,]    0   64

That is, the multivariate object mctobj now contains the matrix of AR parameters A, the matrix of MA parameters R and the variance matrix of the innovations Σ. The object also contains a vector measurements y, an ordered vector of time points of measurements tt and a vector z denoting which coordinate of the y vector was observed.

cbind(mctobj$y,mctobj$tt,mctobj$z)[1:5,]            [,1]       [,2] [,3] [1,] -0.6597594 0.03740642    2 [2,] -1.3306193 0.08360339    1 [3,]  0.9946577 0.27623398    2 [4,]  1.1272836 0.31624703    2 [5,]  1.2388762 0.32568241    2

The observations are non-synchronous, i.e. only one coordinate of the y vector is observed at each time point. Observations 1 and 3–5 are of coordinate 2; the second is of coordinate 1.

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer International Publishing AG, part of Springer Nature

About this chapter

Cite this chapter

Tómasson, H. (2018). Implementation of Multivariate Continuous-Time ARMA Models. In: van Montfort, K., Oud, J.H.L., Voelkle, M.C. (eds) Continuous Time Modeling in the Behavioral and Related Sciences. Springer, Cham. https://doi.org/10.1007/978-3-319-77219-6_15

Download citation

Publish with us

Policies and ethics