* NONLINEAR LEAST SQUARES AND TESTING FOR AUTOCORRELATED ERRORS * * Example: Estimation of a CES production function * * Data set: Table 22.4, page 724 of Griffiths, Hill and Judge, * LEARNING AND PRACTICING ECONOMETRICS, Wiley, 1993. * SAMPLE 1 30 READ L K Q 0.228 0.802 0.256918 0.258 0.249 0.183599 0.821 0.771 1.212883 0.767 0.511 0.522568 0.495 0.758 0.847894 0.487 0.425 0.763379 0.678 0.452 0.623130 0.748 0.817 1.031485 0.727 0.845 0.569498 0.695 0.958 0.882497 0.458 0.084 0.108827 0.981 0.021 0.026437 0.002 0.295 0.003750 0.429 0.277 0.461626 0.231 0.546 0.268474 0.664 0.129 0.186747 0.631 0.017 0.020671 0.059 0.906 0.100159 0.811 0.223 0.252334 0.758 0.145 0.103312 0.050 0.161 0.078945 0.823 0.006 0.005799 0.483 0.836 0.723250 0.682 0.521 0.776468 0.116 0.930 0.216536 0.440 0.495 0.541182 0.456 0.185 0.316320 0.342 0.092 0.123811 0.358 0.485 0.386354 0.162 0.934 0.279431 GENR LOGQ=LOG(Q) * Estimate the CES production function NL 1 / NCOEF=4 PCOV ZMATRIX=Z COEF=BETA PREDICT=YHAT EQ LOGQ=GAMMA-(ETA/RHO)*LOG(DELTA*L**(-RHO)+(1-DELTA)*K**(-RHO)) COEF RHO 1 DELTA .5 GAMMA 1 ETA 1 END * Estimate the elasticity of substitution TEST 1/(1+RHO) * Generate the linear pseudomodel and compute the DURBIN-WATSON p-value MATRIX YBAR=LOGQ-YHAT+Z*BETA OLS YBAR Z / NOCONSTANT DWPVALUE STOP