Description Usage Arguments Value Examples
This function takes an arima model, checks for arch effect, and fits a garch model if arch effects are present
1 | ArmaToGarch(arimamodel, max_arch_terms = 15)
|
arimamodel |
The arima model to check for arch effects |
max_arch_terms |
Maximum number of ARCH terms. A higher value will allow for more accuracy, but slower operation |
A garch model fitted on the residuals of the input arima model
1 2 3 4 5 6 7 | series1 <- c(1, 3, 2, 3, 4, 3, 4, 5, 6, 4, 5, 6, 5, 4, 7, 5, 4, 7, 8, 5, 7, 8, 9, 7, 9)
arimamodel <- forecast::auto.arima(series1)
ArmaToGarch(arimamodel)
series2 <- c(1, 3, 4, 1, 4, 1, 2, 5, 1, 4, 5, 8, 1, 4, 7, 5, 1, 7, 8, 5, 1, 8, 9, 7, 1)
arimamodel <- forecast::auto.arima(series2)
ArmaToGarch(arimamodel)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.