在 R 中构建 GARCH 模型
Kris Boudt
Professor of finance and econometrics
$$ \mu_{t} = \mu + \lambda \sigma^2_{t} $$
$\lambda > 0$ 为风险/回报参数,表示单位方差风险带来的期望回报增量。
将 ugarchspec() 中的 mean.model 从 list(armaOrder = c(0, 0)) 改为 list(armaOrder = c(0, 0), archm = TRUE, archpow = 2):
garchspec <- ugarchspec(
mean.model = list(armaOrder = c(0, 0)),
variance.model = list(model = "gjrGARCH"),
distribution.model = "sstd")
garchspec <- ugarchspec(
mean.model = list(armaOrder = c(0, 0), archm = TRUE, archpow = 2),
variance.model = list(model = "gjrGARCH"),
distribution.model = "sstd")
估计
garchfit <- ugarchfit(data = sp500ret, spec = garchspec)
查看均值的估计系数
round(coef(garchfit)[1:2], 4)
mu archm
0.0002 1.9950
预测的均值收益
$$ \hat{\mu}_{t} = 0.0002 + 1.9950 \hat{\sigma}^2_{t} $$
plot(fitted(garchfit))

$$ \mu_{t} = \mu + \rho(R_{t-1} - \mu) $$
$$ \mu_{t} = \mu + \rho(R_{t-1} - \mu) $$
$$ \mu_{t} = \mu + \rho(R_{t-1} - \mu) $$
使用 sst 分布的 AR(1)-GJR GARCH 的设定与估计
garchspec <- ugarchspec(
mean.model = list(armaOrder = c(1, 0)),
variance.model = list(model = "gjrGARCH"),
distribution.model = "sstd")
garchfit <- ugarchfit(data = sp500ret, spec = garchspec)
AR(1) 模型估计值
round(coef(garchfit)[1:2], 4)
mu ar1
0.0003 -0.0292
一阶移动平均模型 MA(1) 使用收益相对条件均值的偏差:
$$ \mu_{t} = \mu + \theta(R_{t-1} - \mu_{t-1}) $$
ARMA(1,1) 结合 AR(1) 与 MA(1):
$$ \mu_{t} = \mu + \rho(R_{t-1} - \mu) + \theta(R_{t-1} - \mu_{t-1}) $$
MA(1)
garchspec <- ugarchspec(
mean.model = list(armaOrder = c(0, 1)),
variance.model = list(model = "gjrGARCH"),
distribution.model = "sstd")
ARMA(1, 1)
garchspec <- ugarchspec(
mean.model = list(armaOrder = c(1, 1)),
variance.model = list(model = "gjrGARCH"),
distribution.model = "sstd")
在 R 中构建 GARCH 模型