Description Usage Arguments Details Value
Time-varying cycle component
1 | tvarCycle(parmlist)
|
parmlist |
A list of parameters as generated by |
This function generates state space model matrices related to an a time-varying cyclic component. Such a specification is usually more slowly varying than a seasonal component, say for a yearly cycle with daily data. The model has the form:
y(t) = Z_c * c(t) + extra stuff
c(t+1) = Tt_c * c(t) + R * sig_cycle
In particular, the vector c(t) evolves as
c_1(t+1) = c_1(t) * cos(lam) + c_2(t) * sin(lam) + omega_1
c_2(t+1) = -c_1(t) * sin(lam) + c_2(t) * cos(lam) + omega_2
where omega_1 and omega_2 are iid normal with mean 0 and variance sig2cycle, and lam = 2π/period.
For a particular period (parmlist$period
), this function produces
the appropriate model matrices above.
A list of matrices with components Z
, Tt
, Q
, and
R
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.