Motivation
I want to wrap up my own GARCH implementation
- to make sure I have understood the underlying model/assumption.
- to leverage
forecast::auto.arima
to automate model order selection (see below). - to mitigate the potential issues with parameters, so that I don't have to switch to IGARCH when the sum of parameters are close to 1, etc.
Background
Suppose $a_t$ is a residual term with zero mean and zero conditional mean, the GARCH(p, q) model is given by
$$ \begin{equation} \left\{ \begin{aligned} a_t &= \sigma_t \epsilon_t \\ \sigma_t^2 &= \alpha_0 + \sum_{i=1}^p \alpha_i a_{t-i}^2 + \sum_{j=1}^q \beta_j \sigma_{t-j}^2 \end{aligned} \right. \end{equation} $$
Where $\epsilon_t \stackrel{iid}{\sim} \text{WN}(0, 1)$. If we let $\eta_t^2 := a_t^2 - \sigma_t^2$, then an alternative representation is
$$ \begin{equation} \left\{ \begin{aligned} a_t &= \sigma_t \epsilon_t \\ a_t^2 &= \alpha_0 + \sum_{i=1}^{\max(p, q)} (\alpha_i + \beta_i)a_{t-i}^2 + \eta_t - \sum_{j=1}^q \beta_j \eta_{t-j} \end{aligned} \right. \end{equation} $$
According to my professor, $\eta_t$ can be proved to have zero mean, and are uncorrelated (but not independent).
Methodology
From above we can see that the squared residual $a_t^2$ is an ARMA process, so as stated before, I'll just fit an ARMA on $a_t^2$. As far as I know, we don't have xxx::auto.garch
but there is forecast::auto.arima
, which would help us to find the correct order of ARMA.
This lets us model/forecast the conditional mean of squared residuals. However, what we really care about is the conditional volatility of $a_t$, but I'm lost here.
$$ \begin{equation} \begin{aligned} E(a_t^2 | I_{t-1}) &= \text{var}(a_t | I_{t-1}) \\ &= \text{var}(\sigma_t \epsilon_t | I_{t-1}) \\ &= \text{var}(\sigma_t | I_{t-1}) \text{var}(\epsilon_t | I_{t-1}) + \text{var}(\sigma_t | I_{t-1}) E^2(\epsilon_t | I_{t-1}) + \text{var}(\epsilon_t | I_{t-1}) E^2(\sigma_t | I_{t-1}) \\ &= \text{var}(\sigma_t | I_{t-1}) + E^2(\sigma_t | I_{t-1}) \\ &= \text{???} \end{aligned} \end{equation} $$
Question
How do I get "conditional volatility of residuals" from "conditional mean of squared residuals"?
auto.arima
could be used for GARCH model selection much along the same lines as you did, but never had the time to work on that. If the solution is free from fatal conceptual mistakes, you could probably release a version ofauto.garch
for R users, it might become popular :) $\endgroup$