SAMPLE 1 1974 READ (DMBP.txt) Y DAYDUM * Covariance matrix - Information matrix HET Y / GARCH=1 PRESAMP COEF=BETA STDERR=IM COV=AINV GMATRIX=G * Compute robust standard errors (see Weiss and Bollerslev-Wooldridge) MATRIX V=AINV*(G'G)*AINV MATRIX BW=SQRT(DIAG(V)) * Covariance matrix - outer product of gradient (OP) ?HET Y / GARCH=1 PRESAMP OPGCOV STDERR=OP * Covariance matrix - Hessian estimation by numerical derivatives ?HET Y / GARCH=1 PRESAMP NUMCOV STDERR=HNUM * List the coefficients and standard errors SAMPLE 1 4 PRINT BETA HNUM OP IM BW * Compare with the benchmark results in McCullough and Renfro * Benchmark coefficients READ BMARK / BYVAR -0.00619041 0.0107613 0.153134 0.805974 * Calculate the log relative error -- the number of digits of accuracy GENR LRE=-LOG(ABS(BETA-BMARK)/ABS(BMARK))/2.3026 PRINT BMARK BETA LRE * Benchmark standard error estimates READ BH BOP BIM BBW 0.00846212 0.00843359 0.00837628 0.00873092 0.00285271 0.00132298 0.00192881 0.00312364 0.0265228 0.0139737 0.0194012 0.0273219 0.0335527 0.0165604 0.0218399 0.0301509 GENR LRE1=-LOG(ABS(HNUM-BH)/ABS(BH))/2.3026 GENR LRE2=-LOG(ABS(OP-BOP)/ABS(BOP))/2.3026 GENR LRE3=-LOG(ABS(IM-BIM)/ABS(BIM))/2.3026 GENR LRE4=-LOG(ABS(BW-BBW)/ABS(BBW))/2.3026 FORMAT(4F12.2) PRINT LRE1 LRE2 LRE3 LRE4 / FORMAT STOP