arch.univariate.GARCH¶
-
class arch.univariate.GARCH(p: int =
1, o: int =0, q: int =1, power: float =2.0)[source]¶ GARCH and related model estimation.
- The following models can be specified using GARCH:
ARCH(p)
GARCH(p,q)
GJR-GARCH(p,o,q)
AVARCH(p)
AVGARCH(p,q)
TARCH(p,o,q)
Models with arbitrary, pre-specified powers
- Parameters:¶
- p: int =
1¶ Order of the symmetric innovation. Must be non-negative.
- o: int =
0¶ Order of the asymmetric innovation. Must be non-negative.
- q: int =
1¶ Order of the lagged (transformed) conditional variance. Must be non-negative.
- power: float =
2.0¶ Power to use with the innovations, abs(e) ** power. Default is 2.0, which produces ARCH and related models. Using 1.0 produces AVARCH and related models. Other powers can be specified, although these should be strictly positive, and usually larger than 0.25.
- p: int =
- Raises:¶
TypeError – If
p,oorqis not an integer, orpoweris not a real number.ValueError – If
p,oorqis negative,pandoare both 0, orpoweris not finite and strictly positive.
Notes
In this class of processes, the variance dynamics are
\[\sigma_{t}^{\lambda}=\omega + \sum_{i=1}^{p}\alpha_{i}\left|\epsilon_{t-i}\right|^{\lambda} +\sum_{j=1}^{o}\gamma_{j}\left|\epsilon_{t-j}\right|^{\lambda} I\left[\epsilon_{t-j}<0\right]+\sum_{k=1}^{q}\beta_{k}\sigma_{t-k}^{\lambda}\]where \(\lambda\) is the
power.Examples
>>> from arch.univariate import GARCHStandard GARCH(1,1)
>>> garch = GARCH(p=1, q=1)Asymmetric GJR-GARCH process
>>> gjr = GARCH(p=1, o=1, q=1)Asymmetric TARCH process
>>> tarch = GARCH(p=1, o=1, q=1, power=1.0)Methods
backcast(resids)Construct values for backcasting to start the recursion.
backcast_transform(backcast)Transform user-provided backcast values.
bounds(resids)Return bounds for parameters.
compute_variance(parameters, resids, sigma2, ...)Compute the variance for the ARCH model.
Construct parameter constraints arrays for parameter estimation.
forecast(parameters, resids, backcast, ...)Forecast volatility from the model.
Return the names of the model parameters.
simulate(parameters, nobs, rng[, burn, ...])Simulate data from the model.
starting_values(resids)Return starting values for the ARCH model.
update(index, parameters, resids, sigma2, ...)Compute the variance for a single observation.
variance_bounds(resids[, power])Construct loose bounds for conditional variances.
Properties
The name of the volatility process.
The number of parameters in the model.
Index to use to start variance subarray selection.
Index to use to stop variance subarray selection.
Flag indicating that the volatility process supports update.
Get the volatility updater associated with the volatility process.