1.2 Example model
An unconstrained MARSS model, meaning all the elements in a parameter matrices are allowed to be different and none constrained to be equal or related.
\[\begin{equation*} \begin{gathered} \begin{bmatrix}x_1\\ x_2\end{bmatrix}_t = \begin{bmatrix}b_{11}&b_{12}\\b_{21}&b_{22}\end{bmatrix} \begin{bmatrix}x_1\\x_2\end{bmatrix}_{t-1} + \begin{bmatrix}w_1\\ w_2\end{bmatrix}_t,\quad \begin{bmatrix}w_1\\ w_2\end{bmatrix}_t \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}u_1\\u_2\end{bmatrix},\begin{bmatrix}q_{11}&q_{12}\\q_{21}&q_{22}\end{bmatrix} \end{pmatrix} \\ \\ \begin{bmatrix}y_1\\ y_2\\ y_3\end{bmatrix}_t = \begin{bmatrix}z_{11}&z_{12}\\ z_{21}&z_{22}\\ z_{31}&z_{32}\end{bmatrix} \begin{bmatrix}x_1\\ x_2\end{bmatrix}_t + \begin{bmatrix}v_1\\ v_2\\ v_3\end{bmatrix}_t, \begin{bmatrix}v_1\\ v_2\\ v_3\end{bmatrix}_t \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}a_1\\ a_2\\ a_3\end{bmatrix}, \begin{bmatrix}r_{11}&r_{12}&r_{13}\\r_{21}&r_{22}&r_{23}\\r_{31}&r_{32}&r_{33}\end{bmatrix} \end{pmatrix} \\ \\ \begin{bmatrix}x_1\\ x_2\end{bmatrix}_0 \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}\pi_1\\ \pi_2\end{bmatrix},\begin{bmatrix}\nu_{11}&\nu_{12}\\ \nu_{21}&\nu_{22}\end{bmatrix} \end{pmatrix} \quad or\quad \begin{bmatrix}x_1\\ x_2\end{bmatrix}_1 \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}\pi_1\\ \pi_2\end{bmatrix},\begin{bmatrix}\nu_{11}&\nu_{12}\\ \nu_{21}&\nu_{22}\end{bmatrix} \end{pmatrix} \end{gathered} \end{equation*}\]
A constrianed MARSS model. The MARSS package allows you to specify constraints by fixing elements in a parameter matrix or specifying that some elements are estimated—or have a linear relationship to other elements. Here is an example:
\[\begin{equation*} \begin{gathered} \begin{bmatrix}x_1\\ x_2\end{bmatrix}_t = \begin{bmatrix}a&0\\0&a\end{bmatrix} \begin{bmatrix}x_1\\x_2\end{bmatrix}_{t-1} + \begin{bmatrix}w_1\\ w_2\end{bmatrix}_t,\quad \begin{bmatrix}w_1\\ w_2\end{bmatrix}_t \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}0.1\\u\end{bmatrix},\begin{bmatrix}q_{11}&q_{12}\\q_{12}&q_{22}\end{bmatrix} \end{pmatrix} \\ \\ \begin{bmatrix}y_1\\ y_2\\ y_3\end{bmatrix}_t = \begin{bmatrix}d&d\\ c& c\\ 1+2d+3c&2+3d\end{bmatrix} \begin{bmatrix}x_1\\ x_2\end{bmatrix}_t + \begin{bmatrix}v_1\\ v_2\\ v_3\end{bmatrix}_t,\quad \begin{bmatrix}v_1\\ v_2\\ v_3\end{bmatrix}_t \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}a_1\\ a_2\\ 0\end{bmatrix}, \begin{bmatrix}r&0&0\\0&r&0\\0&0&r\end{bmatrix} \end{pmatrix} \\ \\ \begin{bmatrix}x_1\\ x_2\end{bmatrix}_0 \sim \,\text{MVN}\begin{pmatrix}\begin{bmatrix}\pi\\ \pi\end{bmatrix},\begin{bmatrix}1&0\\ 0&1\end{bmatrix} \end{pmatrix} \end{gathered} \end{equation*}\]
Notice that some elements are fixed (in this case to 0, but could be any fixed number), some elements are shared (have the same value), and some elements are linear combinations of other estimated values: \(c\), \(1+2d+3c\) and \(2+3d\) are linear combinations of \(c\) and \(d\).