nag_generate_garchGJR (g05hmc) (PDF version)
g05 Chapter Contents
g05 Chapter Introduction
NAG C Library Manual

NAG Library Function Document

nag_generate_garchGJR (g05hmc)

+ Contents

    1  Purpose
    7  Accuracy
    9  Example

1  Purpose

nag_generate_garchGJR (g05hmc) generates a given number of a GJR GARCH p,q  process (see Glosten et al. (1993)).

2  Specification

#include <nag.h>
#include <nagg05.h>
void  nag_generate_garchGJR (Integer num, Integer p, Integer q, const double theta[], double gamma, double ht[], double et[], Nag_Garch_Fcall_Type fcall, double rvec[], NagError *fail)

3  Description

A GJR GARCH p,q  process is represented by:
ε t ψ t-1 N 0, h t
h t = α 0 + i=1 q α i + γ S t-i ε t-i 2 + i=1 p β i h t-i ,   t = 1 , , T
where S t = 1 , if ε t < 0 , and S t = 0 , if ε t 0 .
Here T  is the number of observations in the sequence, ε t  is the observed value of the GARCH p,q  process at time t , h t  is the conditional variance at time t , and ψ t  the information set of all information up to time t . Symmetric GARCH p,q  sequences are generated when γ  is zero, otherwise asymmetric GARCH p,q  sequences are generated with γ  specifying the amount by which negative shocks are to be enhanced.

4  References

Bollerslev T (1986) Generalised autoregressive conditional heteroskedasticity Journal of Econometrics 31 307–327
Engle R (1982) Autoregressive conditional heteroskedasticity with estimates of the variance of United Kingdom inflation Econometrica 50 987–1008
Engle R and Ng V (1993) Measuring and testing the impact of news on volatility Journal of Finance 48 1749–1777
Glosten L, Jagannathan R and Runkle D (1993) Relationship between the expected value and the volatility of nominal excess return on stocks Journal of Finance 48 1779–1801
Hamilton J (1994) Time Series Analysis Princeton University Press

5  Arguments

1:     numIntegerInput
On entry: T , the number of terms in the sequence.
Constraints:
  • num1 ;
  • num > p + q + 1 .
2:     pIntegerInput
On entry: the GARCH p,q  argument p .
Constraint: p0 .
3:     qIntegerInput
On entry: the GARCH p,q  argument q .
Constraint: q1 .
4:     theta[q+p+1]const doubleInput
On entry: the first element contains the coefficient α o , the next q elements contain the coefficients α i , for i=1,2,,q. The remaining p elements are the coefficients β j , for j=1,2,,p.
5:     gammadoubleInput
On entry: the asymmetry argument γ  for the GARCH p,q  sequence.
6:     ht[num]doubleOutput
On exit: the conditional variances h t , for t=1,2,,T for the GARCH p,q  sequence.
7:     et[num]doubleOutput
On exit: the observations ε t , for t=1,2,,T, or the GARCH p,q  sequence.
8:     fcallNag_Garch_Fcall_TypeInput
On entry: if fcall=Nag_Garch_Fcall_True, a new sequence is to be generated, else if fcall=Nag_Garch_Fcall_False a given sequence is to be continued using the information in rvec.
9:     rvec[2×p+q+1]doubleInput/Output
On entry: the array contains information required to continue a sequence if fcall=Nag_Garch_Fcall_False.
On exit: contains information that can be used in a subsequent call of nag_generate_garchGJR (g05hmc), with fcall=Nag_Garch_Fcall_False.
10:   failNagError *Input/Output
The NAG error argument (see Section 3.6 in the Essential Introduction).

6  Error Indicators and Warnings

NE_2_INT_ARG_LT
On entry, num=value  while p + q + 1 = value. These arguments must satisfy num p + q + 1 .
NE_BAD_PARAM
On entry, argument fcall had an illegal value.
On entry, argument gamma had an illegal value.
NE_INT_ARG_LT
On entry, num=value.
Constraint: num1.
On entry, p=value.
Constraint: p0.
On entry, q=value.
Constraint: q1.

7  Accuracy

Not applicable.

8  Further Comments

None.

9  Example

See the example for nag_estimate_garchGJR (g13fec).

nag_generate_garchGJR (g05hmc) (PDF version)
g05 Chapter Contents
g05 Chapter Introduction
NAG C Library Manual

© The Numerical Algorithms Group Ltd, Oxford, UK. 2012