Estimating CAViaR with Quantile Loss and Numerical Optimization
Summary
The answer describes estimating a dynamic conditional quantile model in which the current quantile depends on its lag and the previous return’s absolute value. Because the quantile appears on both sides through its autoregressive structure, the parameters are not obtained by applying ordinary linear quantile regression directly. Instead, the proposed method recursively generates quantile estimates for a candidate parameter set and evaluates them with an asymmetric quantile loss based on returns relative to the negative quantile threshold.
The initialization described uses a sample quantile from the first 300 observations. The answer then outlines a search procedure: generate many random parameter combinations, retain promising candidates, refine them with numerical optimization, and repeat refinement. It names MATLAB and R optimization routines as examples. These are replication-oriented instructions rather than a full implementation; they omit code details and diagnostics, and the random search counts and iteration schedule are specific to the cited paper’s procedure, not a guarantee of robust estimation in every dataset.
Key ideas
- CAViaR parameters can be estimated by minimizing quantile loss over recursively generated quantiles.
- The autoregressive quantile path requires an initial value, illustrated with a sample quantile from the first 300 observations.
- A random parameter search can identify promising starting points for numerical optimization.
- The described optimizer sequence follows a paper-specific procedure and does not provide implementation diagnostics or robustness guarantees.
Tags
Full text
# How to estimate CAViaR (Engle and Manganelli 2004) using non linear quantile regression?
# How to estimate CAViaR (Engle and Manganelli 2004) using non linear quantile regression?
I am trying to replicate results from Engle and Manganelli (2004). The following is one of their specifications, $q_t(\theta)=\gamma_0+\gamma_1q_{t-1}(\theta)+\alpha|r_{t-1}|$, $q$ is the quantile of return distribution, $r$ is the return.
I do not know how to use quantile regression to estimate this process, since we have quantiles on both sides of equation. Any suggesions?
## Answer by Marco Aurélio Guerra (score 1)
https://quant.stackexchange.com/a/63295
You have to minimize RQ = - ( $I$($r$ < - $q$ ) - $\theta$ ) * ( $r$ + $q$ ). Where $r$,$q$ are the vectors of returns and quantiles found (for a given $\gamma$0, $\gamma$1, $\alpha$ ), * is the matrix multiplication, and $I$( ) is the indicator function. Note that because we have an autoregressive function, you must have a first $q$ (VaR) which in the paper is the choosen $\theta$ quantile of the first 300 observations. The minimization problem is solved by finding which coefficents ($\gamma$0,$\gamma$1 and $\alpha$ ) is the ones that minimizes RQ. In the paper this is done by generating 10000 random coefficients combinations, then using the top 10 $a$ results in a optimizer ( he uses 'fminsearch' and 'fminunc' functions from MATLAB, in R you can use optim() ) and reiterating 5 times to refine the results.
Manganelli has a site where you can find the code for MATLAB.
$a$ - for the simetric absolute CAViaRShown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.