Skip to content

Commit

Permalink
add some docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon Broda committed Sep 20, 2019
1 parent 84417ad commit 4ffe93e
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 3 deletions.
43 changes: 41 additions & 2 deletions docs/src/multivariateintro.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,41 @@
# Introduction and type hierarchy
hi
# Introduction

ARCH models naturally generalize to the multivariate setting. Consider a time series of daily asset returns $\{r_t\}_{t\in 1, \ldots, T}$, where now $r_t\in\mathbb{R}^d$. Similarly to the univariate case, the general model structure is

\[
r_t=\mu_t+\Sigma_t^{1/2}z_t,\quad \mu_t\equiv\mathbb{E}[r_t\mid\mathcal{F}_{t-1}],\quad \Sigma_t\equiv\mathbb{E}[(r_t-\mu_t)(r_t-\mu_t)^\mathrm{T}]\mid\mathcal{F}_{t-1}].
\]

A multivariate ARCH model specifies the conditional covariance matrix $\Sigma_t$ in terms of past returns, conditional (co)variances, and potentially other variables. The main challenge in multivariate ARCH modelling is the _curse of dimensionality_: allowing each of the $(d)(d+1)/2$ elements of $\Sigma_t$ to depend on the past returns of all $d$ other assets requires $O(d^4)$ parameters without imposing additional structure. Multivariate ARCH models differ in which structure they impose.

The following multivariate ARCH models are currently available in this package:

* The CCC model of [Bollerslev (1990)](https://doi.org/10.2307/2109358)
* The DCC model of [Engle (2002)](https://doi.org/10.1198/073500102288618487)

These may be combined with different mean specifications as in the univariate case, and (in principle) with different specifications for the joint distribution of the $z_t$, although at present, only the multivariate standard normal is supported. Multivariate ARCH models are represented as instances of [`MultivariateARCHModel`](@ref), which like [`UnivariateARCHModel`](@ref) subtypes [`ARCHModel`](@ref).

# Type hierarchy
## [Covariance specifications](@id covspec)
Volatility specifications describe the evolution of $\Sigma_t$. They are modelled as subtypes of [`MultivariateVolatilitySpec`](@ref).

### CCC
The CCC (and DCC, see below) models are examples of _conditional correlation_ models. They decompose
$\Sigma_t$ as
\[
\Sigma_t=D_t R_t D_t,
\]
where $R_t$ is the conditional correlation matrix and $D_t$ is a diagonal matrix containing the volatilities of the individual assets, which are modelled as univariate ARCH processes. In the constant conditional correlation (CCC) model, $R_t=R$ is assumed constant. The model is typically, including here, estimated in a two-step procedure: first, univariate ARCH models are fitted to the $d$ asset returns, and then $R$ is estimated as the sample correlation matrix of the standardized residuals.

### DCC
The DCC model extends the CCC model by making the $R_t$ dynamic (hence the name, dynamic conditional correlation model). In particular,

\[
R_{ij, t} = \frac{Q_{ij,t}}{\sqrt{Q_{ii,t}Q_{jj,t}}}, \
\]
where
\[Q_{t} =(1-\theta _{1}-\theta _{2})\bar{Q}+\theta _{1}\epsilon
_{t-1}\epsilon _{t-1}^{\prime }+\theta _{2}Q_{t-1},
\]
$\epsilon _{t}=D_{t}^{-1}a_{t}$, $Q_{t}=\mathrm{cov}%
(\epsilon _{t}|F_{t-1})$, and $\bar{Q}=\mathrm{cov}(\epsilon _{t})$.
3 changes: 2 additions & 1 deletion docs/src/univariateintro.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Introduction and type hierarchy
# Introduction
Consider a sample of daily asset returns ``\{r_t\}_{t\in\{1,\ldots,T\}}``. All models covered in this package share the same basic structure, in that they decompose the return into a conditional mean and a mean-zero innovation:
```math
r_t=\mu_t+\sigma_tz_t,\quad \mu_t\equiv\mathbb{E}[r_t\mid\mathcal{F}_{t-1}],\quad \sigma_t^2\equiv\mathbb{E}[(r_t-\mu_t)^2\mid\mathcal{F}_{t-1}],
Expand All @@ -7,6 +7,7 @@ where ``z_t`` is identically and independently distributed according to some law

This package represents a univariate (G)ARCH model as an instance of [`UnivariateARCHModel`](@ref), which implements the interface of `StatisticalModel` from [`StatsBase`](http://juliastats.github.io/StatsBase.jl/stable/statmodels.html). An instance of this type contains a vector of data (such as equity returns), and encapsulates information about the [volatility specification](@ref volaspec) (e.g., [GARCH](@ref) or [EGARCH](@ref)), the [mean specification](@ref meanspec) (e.g., whether an intercept is included), and the [error distribution](@ref Distributions).

# Type hierarchy
## [Volatility specifications](@id volaspec)
Volatility specifications describe the evolution of ``\sigma_t``. They are modelled as subtypes of [`UnivariateVolatilitySpec`](@ref). There is one type for each class of (G)ARCH model, parameterized by the number(s) of lags (e.g., ``p``, ``q`` for a GARCH(p, q) model). For each volatility specification, the order of the parameters in the coefficient vector is such that all parameters pertaining to the first type parameter (``p``) appear before those pertaining to the second (``q``).
### ARCH
Expand Down

0 comments on commit 4ffe93e

Please sign in to comment.