ML PROC TSP Examples
MLPROC.ZIP
Download most of the ML PROC TSP examples as a single zip file
(12/1997)
MLPROCU.ZIP
Download all of the ML PROC TSP examples as a single zip file
(11/1999, unix version)
1. non-GARCH Examples
MLPM Normal mean and variance -- ML PROC and ML FRML. Includes example of concentrated likelihood function with PROC
REGARMA Regression with ARMA(8,2) residuals - ML PROC.
KALMANHP Kalman filter / state space model. Regression with intercept and one RHS variable; coefficients follow independent random walks. The variance of the transition equation is diagonal, and these variances (hyperparameters) are estimated.
2. Univariate GARCH Examples
ARCHML ARCH(1) -- ARCH, ML PROC and ML FRML commands
GARCHML GARCH(1,1) -- ARCH and ML PROC commands
GARCHMA GARCH(1,1) with MA(1) residual -- ML PROC command (not possible with plain ARCH command)
GARCHM GARCH(1,1)-M - ARCH and ML PROC commands. Illustrates use of SOLVE for recursive/simultaneous evaluation of h and eps equations over time
AGARCH Asymmetric GARCH(1,1) with MA(1) residual -- ML PROC
APARCH Asymmetric Power ARCH(1,1) with MA(1) residual - ML PROC
EGARCH Exponential GARCH(1,1) - ML PROC. Log of variance follows a recursive process. No asymmetric terms are used in this simple example.
3. Multivariate ARCH Examples
MARCH2 Diagonal ARCH(2) with 2 equations - ML FRML
MARCH3 Diagonal ARCH(2) with 3 equations - ML FRML
MARCH4 Diagonal ARCH(2) with 4 equations - ML FRML
Note: the above examples could be simplified slightly by using the "lagged EQSUB" feature in TSP 4.4 and higher; separate equations for lagged residuals would not be needed.
4. Multivariate GARCH Examples
MGARCH Diagonal GARCH(1,1) with 2 equations - ML PROC. Uses the BEKK parameterization, to make sure that H(t) stays positive definite. Unfortunately, this example does not work correctly; the estimates are not close to the true parameters which generated the data.
Note:The ML PROC feature is available in TSP 4.4 and higher. It is possible (but difficult) to estimate all the above models without the ML PROC feature (i.e. with TSP 4.3 or earlier). It requires a separate BFGS PROC to do the BFGS iterations (i.e. instead of using the ML command, you use a BFGS command). However, it is more difficult to use this sort of approach, because the user-written PROC that evaluates @LOGL has to be very careful to not modify any variables which exist in the BFGS PROC. Due to this difficulty and other problems (such as lack of output control options like those in the ML command), we don't recommend this method. It's easier and safer to upgrade and use ML PROC.