TransMat {MSGARCH} | R Documentation |
Transition matrix.
Description
Method returning the transition matrix.
Usage
TransMat(object, ...)
## S3 method for class 'MSGARCH_SPEC'
TransMat(object, par = NULL, nahead = 1L, ...)
## S3 method for class 'MSGARCH_ML_FIT'
TransMat(object, nahead = 1L, ...)
Arguments
object |
Model specification of class |
... |
Not used. Other arguments to |
par |
Vector (of size d) of parameter estimates (not required when using a fit object) where d must have the same length as the default parameters of the specification. |
nahead |
Number of steps ahead. (Default: |
Value
A matrix (of size K x K) in the case of a Markov-Switching model or a vector (of size K) in the case of a Mixture of GARCH model. The row indicates the starting states while the columns indicates the transition states.
Examples
# create model specification
spec <- CreateSpec()
# load data
data("SMI", package = "MSGARCH")
# fit the model on the data by ML
fit <- FitML(spec = spec, data = SMI)
# Extract the transition matrix 10 steps ahead
trans.mat <- TransMat(fit, nahead = 10)
print(trans.mat)
[Package MSGARCH version 2.51 Index]