Description Usage Arguments Details Value Note Author(s) References See Also Examples
View source: R/mskfModel.mskfSkeleton.R
Generate an mskfModel
from an mskfSkeleton
specifying values for the different model parameters, starting values, and upper and or lower bounds for the parameter values.
1 2 |
object |
Object returned by |
... |
Extra arguments which can be zero or more of
the arrays |
start |
a named numeric vector with starting values for the freely estimated parameters; see details |
lower |
a named vector, compatible with |
upper |
a named vector, compatible with |
See mskf
for precise definition of the regime switching state-space model.
Arrays and matrix may be specified as strings.
Can be used to name the free parameters using numbers, and to
constrain free parameters to be equal (by using the same
number). Parameter estimates will be presented in the same
order as they were numbered. Numbering does not need to be
consecutively.
The vector start
can be used to initialize the parameters at specific values. The names in this
vector are the parameter names as given for the model matrices. As an example, if paW
is specified as
paW=diag(1:2)
, and paH
is specified as paH=2
, then if start=c('1'=0.25, '2'=0.8)
,
then paW
will be initialized to diag(c(0.25, 0.8))
and paH
will be initialized to
matrix(0.8,1,1)
.
An object of class mskfSkeleton
with components
const |
A list wich contains all of the components below for which
|
pattern |
A list wich contains all of the components below for which |
y |
time series |
x |
(optional) predictor time series |
# MOET JE DIT NOG STEEDS ZO ZEGGEN? HET IS IN DE VORIGE FUNCTIE NAMELIJK AL GEMAAKT
ny |
number of time series in |
nx |
number of time series in |
nt |
length of the time series in |
ne |
number of state variables. |
nm |
number of regimes. |
ipat |
|
# MOET DAT HIER WEER ZO WORDEN GEZEGD? HIJ MAAKT HIER GEEN DEFAULTS MEER NAMELIJK
theta |
a named vector with starting values with the same names as |
lobo |
a vector with lower bound values |
upbo |
a vector with upper bound values |
a0 |
a vector with ne zeros as the initial state vector |
P0 |
a matrix of ne by ne with 100 on the diagonal, which serves as the initial mean squared error matrix. |
The
object returned by this function is to be used with
mskfModel
for full model specification.
Ellen L. Hamaker and Raoul P. P. P. Grasman
Kim, C.-J. (1994). Dynamic linear models with Markov-switching. Journal of Econometrics, 60, 1-22.
Kim, C.-J., and Nelson, C. R. (1999). State-Space Models with Regime Switching: Classical and Gibbs-Sampling Approaches with Applications. Cambridge, MIT press.
1 | 1:10
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.