Financial Toolbox
  Go to function:
    Search    Help Desk 
ugarchsim    Examples   See Also

Simulate a univariate GARCH(P,Q) process with Gaussian innovations.

Syntax

Arguments

Kappa
Scalar constant term of the GARCH process.
Alpha
P-by-1 vector of coefficients, where P is the number of lags of the conditional variance included in the GARCH process. Alpha can be an empty matrix, in which case P is assumed 0; when P = 0, a GARCH(0,Q) process is actually an ARCH(Q) process.
Beta
Q-by-1 vector of coefficients, where Q is the number of lags of the squared innovations included in the GARCH process.
NumSamples
Positive, scalar integer indicating the number of samples of the innovations U and conditional variance H (see below) to simulate.

Description

[U, H] = ugarchsim(Kappa, Alpha, Beta, NumSamples) Simulates a univariate GARCH(P,Q) process with Gaussian innovations.

U is a number of samples (NUMSAMPLES)-by-1 vector of innovations, representing a mean-zero, discrete-time stochastic process. The innovations time series U is designed to follow the GARCH(P,Q) process specified by the inputs Kappa, Alpha, and Beta.

H is a NUMSAMPLES-by-1 vector of the conditional variances corresponding to the innovations vector U. Note that U and H are the same length, and form a "matching" pair of vectors. To model the GARCH(P,Q) process, the conditional variance time series, H(t), must be constructed (see below). Thus, H(t) represents the time series inferred from the innovations time series vector U.

GARCH(P,Q) coefficients {Kappa, Alpha, Beta} are subject to constraints:

The time-conditional variance, H(t), of a GARCH(P,Q) process is modeled as:

H(t) = Kappa + Alpha(1)*H(t-1) + Alpha(2)*H(t-2) +...+ Alpha(P)*H(t-P)+ Beta(1)*U^2(t-1)+ Beta(2)*U^2(t-2)+...+ Beta(Q)*U^2(t-Q)

Note that U is a vector of innovations, or regression residuals of an econometric model, representing a mean-zero, discrete-time stochastic process. That is, it is assumed that a regression model has already been run, and that U(t) = y(t) - F(X(t),B) is the time series of innovations derived from the model.

Although H is generated via the equation above, U and H are related as

where v(t) is an i.i.d. sequence ~ N(0,1).

The output vectors U and H are designed to be steady-state sequences; transients have arbitrarily small effect. The (arbitrary) metric used strips the first N samples of U and H such that the sum of the GARCH coefficients, excluding Kappa, raised to the N-th power, will not exceed 0.01:

Thus

Example

This example simulates a GARCH(P,Q) process with P = 2 and Q = 1.

When the above code is executed, the screen output looks like the display shown.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

See Also

ugarch, ugarchpred

Reference

James D. Hamilton, Time Series Analysis, Princeton University Press, 1994



[ Previous | Help Desk | Next ]