Processing math: 100%
+ - 0:00:00
Notes for current slide
Notes for next slide

GARCH Models

Zhentao Shi

Nov 8, 2021

1 / 12
2 / 12

Variance and volatility

  • To quantify uncertainty, variance must be evaluated

    • Examples: interval forecast, VaR, ...
  • In financial econometrics, applications include

    • Portfolio management
    • Pricing of options
    • ...
  • Mean is difficult to predict

  • Variance is easier to predict
    • Unconditional vs. conditional variance
3 / 12

Real data example

  • S&P500 returns
  • Raw data: daily, 1960--2017
  • Here we use data after 2015-01-01
d0 <- read.csv("SPX.csv", header = TRUE)
d0$datevec <- as.Date(d0$datevec, format = "%d/%m/%Y")
d0$r <- c(NA, diff(log(d0$SP500)) )
d0 <- d0[-1,]
d1 <- d0[d0$datevec > "2015-01-01", ]
plot(y = d1$r, x = d1$datevec,
xlim = as.Date( c("2015-01-01", "2017-01-01") ),
type = "l")

4 / 12

Real data example (continue)

  • Square of returns

  • Dynamic patterns

  • Volatility clustering

plot( y = d1$r^2, x = d1$datevec,
xlim = as.Date( c("2015-01-01", "2017-01-01") ), type = "l")
abline(h = mean(d1$r^2), col = "blue", lty = 2)
abline(h = 0, col = "red", lty = 2)

plot( y = d1$r^2, x = d1$datevec,
ylim = c(0, 2*mean(d1$r^2)),
xlim = as.Date( c("2016-01-01", "2017-01-01") ),
type = "l")
abline(h = mean(d1$r^2), col = "blue", lty = 2)

5 / 12

Real data example (continue)

  • Naively fit an AR(1) model for rt
arima(d1$r, order = c(1,0,0))
##
## Call:
## arima(x = d1$r, order = c(1, 0, 0))
##
## Coefficients:
## ar1 intercept
## -0.0094 3e-04
## s.e. 0.0416 4e-04
##
## sigma^2 estimated as 7.27e-05: log likelihood = 1927.09, aic = -3848.18
  • Naively fit an AR(1) model for r2t
arima(d1$r^2, order = c(1,0,0))
##
## Call:
## arima(x = d1$r^2, order = c(1, 0, 0))
##
## Coefficients:
## ar1 intercept
## 0.3058 1e-04
## s.e. 0.0396 0e+00
##
## sigma^2 estimated as 2.257e-08: log likelihood = 4253.34, aic = -8500.68
6 / 12

Definitions

A time series (yt) is called

  • a martingale difference sequence if Et1[yt]=0
  • white noise if
    • E[yt]=0,
    • E[y2t]=σ2y, and
    • E[yt,ytk]=0 for all k
7 / 12

Conditional volatility model

  • For simplicity, let

rt=htϵt,

where

  • ϵtiidN(0,1)
  • ht=Et1[r2t] is the conditional variance

  • Suppose ht is adaptive to past information up to (t1). In other words, Et1[ht]=ht

    • For example, if for some etiidN(0,1) independent from all other variables we have ht=0.5+0.5e2t1, then ht is strictly stationary, and E[ht]=1
8 / 12
N = 100
e = rnorm(N)
h = 0.5 + 0.5 * c(0,e)^2 # at a `0` to the head of `e` to reflect `lag`
h = h[-1]
plot(h, type = "l", main = "conditional variance")
abline(h = 0.5, col = "red")

  • In this example, (rt) is strictly stationary
  • Any function of (rt,rt1,,r) is still strictly stationary
r <- h * rnorm(N)
plot(r, type = "l", main = "the series of returns")
abline(h = 0, col = "red")

9 / 12

Mean and variance

  • Conditional mean Et1[rt]=Et1[htϵt]=ht×0=0 (martingale difference sequence)
  • Unconditional mean E[rt]=E[Et1[rt]]=0
  • Conditional variance

Et1[r2t]=Et1[htϵ2t]=htEt1[ϵ2t]=ht×1=ht

  • Unconditional variance

E[r2t]=E[Et1[r2t]]=E[ht]

  • Unconditional covariance: for k>0, we have

E[rtrtk]=E[hthtkϵtϵtk]=E[Et1[hthtkϵtϵtk]]=E[hthtkϵtkEt1[ϵt]]=E[hthtkϵtk×0]=0

  • If E[ht] is a constant, (rt) is a white noise with time-varying conditional heteroskedasticity.
10 / 12

Simple volatility models

  • Historical model

$$ ht = \frac{1}{M} \sum{i=1}^M r_{t-i}^2 $$

  • Common choices for M can be 22 (monthly average) or 250 (yearly average)
  • Exponentially weighted moving average (EWMA)

$$ ht = (1-\lambda) \sum{j=0}^{\infty} \lambda^i r_{t-i-1}^2 $$

  • The coefficient λ can be either estimated or imposed
11 / 12

ARCH

  • Autoregressive conditional heteroskedastic model (Engle, 1982)

  • ARCH(q): Models ht as autoregressive on past (rt,rt1,,rtq)

$$ ht = \alpha_0 + \sum{i=1}^q \alphai r{t-i}^2 $$

  • ARCH(1): ht=α0+α1r2t1
    • Analogy with AR(1): let yt=r2t, and then Et1[yt]=α0+α1yt1
    • ARCH(1) can be interpreted as an AR(1) in terms of r2t
    • Take unconditional expectation on both sides, we solve E[ht]=α0/(1α1)

GARCH

  • To make ARCH more flexible, Bollerslev (1986) proposes the generalized ARCH (GARCH)

ht=α0+qi=1αir2ti+pi=1βihti

  • The special case GARCH(1,1)

$$ ht = \alpha_0 + \alpha_1 r{t-1}^2 + \beta1 h{t-1} $$

is the leading model in practice

ARCH vs GARCH

  • To understand how GARCH generalizes ARCH, write ARCH(1) as

ht=α0+α1r2t1=α0+α1(r2t1Et2[r2t1])+α1Et2[r2t1]=α0+α1(r2t1ht1)+α1ht1

  • Notice ht1 is the conditional mean of r2t1, and (r2t1ht1) is the demeaned r2t1
  • ARCH entails that these two terms share the same coefficient
  • GARCH allows distinct coefficients

IGARCH

  • In GARCH(1,1), if α1+β1=1, then

ht=α0+α1r2t1+β1ht=α0+α1(r2t1ht1)+(α1+β1)ht1=α0+α1(r2t1ht1)+ht1

  • Take conditional expectation up to time (t2), we have

ht|t2=Et2[α0+α1(r2t1ht1)+ht1]=α0+0+ht1=α0+ht1

  • (ht) behaves similar to unit root (Remind that a unit root process with a drift satisfies Et1[yt]=α0+yt1)
  • Integrated-GARCH (IGARCH)

  • Empirically, ˆα1+ˆβ1 is often close to 1

Additional explanatory regressors

  • Regressors can be added to better fit the mean and the variance

  • Return rμ,x,t=μ0+Kk=1γkxkt+ut

  • Variance ht=α0+qi=1αir2ti+pi=1βihti+Kk=1ψkxkt

  • Distribution rtN(0,ht)

Estimation

  • GARCH is a nonlinear model
  • Maximum likelihood estimation
  • Specification: rt|past historyN(0,ht)

  • Observed time series (rμ,t)Tt=1, where we allow an unknown mean in rμ,t=μ0+rt

  • Unknown parameters θ=(μ,(αi)qi=0,(βi)pi=1)

Likelihood

  • Density

$$ f(r{\mu, t} | r{\mu, t-1}, r{\mu, t-2},\ldots;\theta) = \frac{1}{\sqrt{2\pi h_t}} \exp\left(-\frac{(r{\mu, t}-\mu)^2}{2h_t}\right) $$

  • Log-likelihood

t(θ)=logf(rμ,t|rμ,t1,rμ,t2,;θ)=12log2π12loght(rtμ)22ht

where ht=α0+qi=1αir2ti+pi=1βihti

  • The dynamic system requires initial value to generate h1=α0+α1r20+β1h0
    • Often time, we set r0=0 and h0 as the unconditional sample variance
  • Given the full sample, maximum likelihood estimation seeks to

$$ \max{\theta} \sum{t=1}^T \log \ell_t(\theta) $$

  • If heavy tail is a concern, we specify the rt with a t distribution
    • The degree of freedom of the t distribution ν(2,) is an additional parameter to be estimated
    • AIC can be useful to determine the model specification

Real data example

  • R package fGarch
gar <- garchFit(formula = ~ garch(1,1), data = d1$r, cond.dist = c("norm"))
##
## Series Initialization:
## ARMA Model: arma
## Formula Mean: ~ arma(0, 0)
## GARCH Model: garch
## Formula Variance: ~ garch(1, 1)
## ARMA Order: 0 0
## Max ARMA Order: 0
## GARCH Order: 1 1
## Max GARCH Order: 1
## Maximum Order: 1
## Conditional Dist: norm
## h.start: 2
## llh.start: 1
## Length of Series: 576
## Recursion Init: mci
## Series Scale: 0.008534223
##
## Parameter Initialization:
## Initial Parameters: $params
## Limits of Transformations: $U, $V
## Which Parameters are Fixed? $includes
## Parameter Matrix:
## U V params includes
## mu -0.29301831 0.2930183 0.02930183 TRUE
## omega 0.00000100 100.0000000 0.10000000 TRUE
## alpha1 0.00000001 1.0000000 0.10000000 TRUE
## gamma1 -0.99999999 1.0000000 0.10000000 FALSE
## beta1 0.00000001 1.0000000 0.80000000 TRUE
## delta 0.00000000 2.0000000 2.00000000 FALSE
## skew 0.10000000 10.0000000 1.00000000 FALSE
## shape 1.00000000 10.0000000 4.00000000 FALSE
## Index List of Parameters to be Optimized:
## mu omega alpha1 beta1
## 1 2 3 5
## Persistence: 0.9
##
##
## --- START OF TRACE ---
## Selected Algorithm: nlminb
##
## R coded nlminb Solver:
##
## 0: 762.16113: 0.0293018 0.100000 0.100000 0.800000
## 1: 759.57018: 0.0293031 0.0788547 0.0992305 0.785324
## 2: 756.70937: 0.0293060 0.0786691 0.124553 0.789998
## 3: 756.63443: 0.0293121 0.0591280 0.137720 0.779615
## 4: 755.45163: 0.0293156 0.0694988 0.144753 0.782574
## 5: 755.11502: 0.0293278 0.0716495 0.148522 0.770459
## 6: 754.84923: 0.0293825 0.0771521 0.169095 0.756102
## 7: 754.65299: 0.0297599 0.0937332 0.181315 0.710690
## 8: 754.46118: 0.0298784 0.0926112 0.187934 0.716471
## 9: 754.44556: 0.0299193 0.0883728 0.189186 0.716695
## 10: 754.42417: 0.0300197 0.0885991 0.191146 0.719122
## 11: 754.41693: 0.0301539 0.0879314 0.191044 0.718804
## 12: 754.36809: 0.0323237 0.0912530 0.189018 0.715188
## 13: 754.06029: 0.0449843 0.0887579 0.194768 0.717037
## 14: 753.90002: 0.0576412 0.0917023 0.200796 0.706803
## 15: 753.88511: 0.0604351 0.0891227 0.195525 0.713504
## 16: 753.87586: 0.0632386 0.0896136 0.198517 0.710881
## 17: 753.87506: 0.0643934 0.0898699 0.199565 0.709794
## 18: 753.87506: 0.0643908 0.0898665 0.199589 0.709790
## 19: 753.87506: 0.0643904 0.0898671 0.199589 0.709789
##
## Final Estimate of the Negative LLH:
## LLH: -1989.999 norm LLH: -3.45486
## mu omega alpha1 beta1
## 5.495216e-04 6.545287e-06 1.995887e-01 7.097889e-01
##
## R-optimhess Difference Approximated Hessian Matrix:
## mu omega alpha1 beta1
## mu -1.307989e+07 -2.443104e+08 5204.893 -11956.368
## omega -2.443104e+08 -1.702545e+12 -42924455.368 -76179748.158
## alpha1 5.204893e+03 -4.292446e+07 -2516.685 -2876.809
## beta1 -1.195637e+04 -7.617975e+07 -2876.809 -4397.969
## attr(,"time")
## Time difference of 0.01220894 secs
##
## --- END OF TRACE ---
##
##
## Time to Estimate Parameters:
## Time difference of 0.04920602 secs
## Warning: Using formula(x) is deprecated when x is a character vector of length > 1.
## Consider formula(paste(x, collapse = " ")) instead.

Real data example (continue)

  • fGarch notation:

rμ,t=μ+rtht=ω+α1r2t1+β1ht1

print(gar)
##
## Title:
## GARCH Modelling
##
## Call:
## garchFit(formula = ~garch(1, 1), data = d1$r, cond.dist = c("norm"))
##
## Mean and Variance Equation:
## data ~ garch(1, 1)
## <environment: 0x00000000213c2820>
## [data = d1$r]
##
## Conditional Distribution:
## norm
##
## Coefficient(s):
## mu omega alpha1 beta1
## 5.4952e-04 6.5453e-06 1.9959e-01 7.0979e-01
##
## Std. Errors:
## based on Hessian
##
## Error Analysis:
## Estimate Std. Error t value Pr(>|t|)
## mu 5.495e-04 2.801e-04 1.962 0.049789 *
## omega 6.545e-06 1.805e-06 3.627 0.000287 ***
## alpha1 1.996e-01 4.478e-02 4.457 8.31e-06 ***
## beta1 7.098e-01 5.374e-02 13.208 < 2e-16 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Log Likelihood:
## 1989.999 normalized: 3.45486
##
## Description:
## Wed Jun 08 23:17:27 2022 by user: zhent

Asymmetric effects

  • GARCH implies that shocks, positive and negative, have symmetric effects
  • Theory and empirical evidence support asymmetry
    • Negative shocks have a larger effect
  • TARCH(1,1) ("T" for threshold)

$$ ht = \alpha_0 + [\alpha_1 + \lambda \mathbb{I}(r{t-1}>0)] r{t-1}^2 + \beta_1 h{t-1} $$

Volatility Forecast

  • Consider GARCH(1,1):

ht+1=α0+α1r2t+β1ht

  • Given information up to T, the one-step-ahead forecast

hT+1|T=α0+α1r2T+β1hThT+2|T=α0+α1ET[r2T+1]+β1hT+1|T=α0+(α1+β1)hT+1|ThT+k|T=α0+α1ET[r2T+k1]+β1hT+k1|T=α0+(α1+β1)hT+k1|T

  • In practice, use estimated coefficients to replace α0, α1 and β1

  • Long-run average variance

$$ \lim{k\to \infty} h{T+k|T} = \frac{\alpha_0}{1-\alpha_1 - \beta_1} $$

  • GARCH(1,1) is difficult to beat in terms of forecast (Hansen and Lunde, 2005)

Accumulated variance

  • Future k-period (cumulative) log return is

$$ r{T+1}(k) = r{T+1} + r{T+2} + \cdots + r{T+k} $$

  • Take conditional expectation on both sides:

$$ ET [r^2{T+1}(k)] = h{T+1|T} + h{T+2|T} + \cdots + h_{T+k|T} $$

Real data example (continue)

predict(gar, n.ahead = 5, plot = TRUE, mse = "cond", nx = 20)

## meanForecast meanError standardDeviation lowerInterval upperInterval
## 1 0.0005495216 0.005722513 0.005722513 -0.01066640 0.01176544
## 2 0.0005495216 0.006027007 0.006027007 -0.01126320 0.01236224
## 3 0.0005495216 0.006291125 0.006291125 -0.01178086 0.01287990
## 4 0.0005495216 0.006522029 0.006522029 -0.01223342 0.01333246
## 5 0.0005495216 0.006725129 0.006725129 -0.01263149 0.01373053
  • Notice the predicted mean and the sd

Forecast evaluation

  • Issue: ht=Et1[r2t] cannot observed

  • Solution: Use r2t as a proxy

    • HMPY Ch.15: realized variance
  • Compute the forecast metrics such as RMSE, MAE, ...

  • In addition, motivated from the likelihood estimation, a popular choice of the loss function is called the quasi-likelihood loss

$$ QLIKE = \log \hat{h}t + \frac{(r{\mu, t} - \hat{\mu}) ^2}{\hat{h}_t} $$

  • Risk is the average of the loss

Test evaluation

  • Test the unbiasedness of a forecast

  • Specify a regression form

r2t=δ0+δ1ˆht+et

and test the null H0: δ0=0 and δ1=1

  • The problem of this approach is its sensitivity to large shocks

  • Alternative specifications:

|rt|=δ0+δ1ˆht+etlogr2t=δ0+δ1logˆht+et

Risk-return trade-off

  • Augment CAPM model to take into account the compensation for risk

  • GARCH-M (GARCH-in-mean) model:

ritrft=μ0+μ1hωt+μ2(rmtrft)+ututN(0,ht)ht=α0+α1u2t1+β1ht1

  • Risk-return tradeoff is represented by μ1hωt, where the usual choice of ω is 1 or 0.5.

    • AIC can be used to decide the choice of the value.
  • Test: H0 μ1=0

Multivariate GARCH

  • Similar to the extension from AR to VAR

  • Consider returns of N assets rt=(r1t,r2t,,rNt)

rt=Et1[rt]+utHt=Et1[utut]

  • Ht is an N×N time-varying conditional heteroskedastic variance-covariance matrix

    • Conditional variance hiit on the diagonal line
    • Conditional covariance hijt, ij, on the off-diagonal elements
  • Examples:

    • Time-varying beta coefficient in CAPM
    • Time-varying covariance in portfolio optimization

BEKK model

  • Baba, Engle, Kraft and Kroner (1990)

$$ Ht = C C' + A u{t-1} u{t-1}' A' + B H{t-1} B' $$

  • GARCH(1,1) is BEKK's special case when N=1

  • Estimation method:

    • Model rtN(0,Ht)
    • Maximum likelihood
  • Drawback: when N is large, too many parameters to estimate as C, A and B are N×N matrices

Summary

  • Practice relevance of conditional variance
  • GARCH process
  • Variants: IGARCH, TARCH, ...
  • Estimation
  • Forecast
  • Multivariate GARCH
12 / 12
2 / 12
Paused

Help

Keyboard shortcuts

, , Pg Up, k Go to previous slide
, , Pg Dn, Space, j Go to next slide
Home Go to first slide
End Go to last slide
Number + Return Go to specific slide
b / m / f Toggle blackout / mirrored / fullscreen mode
c Clone slideshow
p Toggle presenter mode
t Restart the presentation timer
?, h Toggle this help
Esc Back to slideshow