Description Usage Arguments Details See Also
Function regSSM creates a state space representation of linear regression model.
1 2 3 4 5 |
X |
A n*k matrix of explanatory variables, with each column containing one explanatory variable, or a list of length p containing X matrices for each series. If X is matrix, it is assumed that all p series use same explanatory variables. |
H |
A p*p covariance matrix (or p*p*n array in of time-varying case) of the disturbance terms epsilon[t] of the observation equation. Default gives p*p zero matrix. Omitted in case of non-Gaussian distributions. Augment the state vector if you want to add additional noise. |
Q |
A r*r (or r*r*n array in of time-varying case) covariance matrix of the disturbance terms η[t] of the system equation. Default is m*m zero matrix ie. ordinary time-invariant regression. |
The linear Gaussian state space model is given by
y[t] = Z[t]α[t] + ε[t], (observation equation)
α[t+1] = T[t]α[t] + R[t]η[t], (transition equation)
where ε[t] ~ N(0,H[t]), η[t] ~ N(0,Q[t]) and α[1] ~ N(a[1],P[1]) independently of each other. In case of non-Gaussian observations, the observation equation is of form p(y[t]|θ[t]) = p(y[t]|Z[t]α[t]), with p(y[t]|θ[t]) being one of the following:
arimaSSM for state space representation of
ARIMA model, structSSM for structural time
series model, and SSModel for custom
SSModel object.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.