# NOT RUN {
# load data
data("SMI", package = "MSGARCH")
# create model specification
# MS(2)-GARCH(1,1)-Normal (default)
spec <- CreateSpec()
# fit the model on the data by ML
fit <- FitML(spec = spec, data = SMI)
# compute the In-sample conditional volatility from the fitted model
forecast <- Forecast(object = fit, n.ahead = 5L)
plot(forecast)
# }
Run the code above in your browser using DataLab