* PS6.6, using DATA3-3, for Application Section 6.7 TIME 1960 SAMPLE 1960 1993 READ(data3-3) YEAR PATENTS RD * Original simple regression model in Section 3.11 OLS PATENTS RD * * The GENR command is used to create four lagged variables (RD(t-1), RD(t-2), * RD(t-3), and RD(t-4)) as follows: * GENR RD1=LAG(RD) GENR RD2=LAG(RD,2) GENR RD3=LAG(RD,3) GENR RD4=LAG(RD,4) * * Next, the independent variables are squared. * GENR RDS=RD**2 GENR RD1S=RD1**2 GENR RD2S=RD2**2 GENR RD3S=RD3**2 GENR RD4S=RD4**2 * * The SAMPLE period must be changed to begin at 1964 since the variable RD * was lagged four time periods. The first four observations are lost in * this case. * SAMPLE 1964 1993 * * The most general unrestricted model is estimated * OLS PATENTS RD RD1 RD2 RD3 RD4 RDS RD1S RD2S RD3S RD4S * omit variables with p-values above 0.9 OLS PATENTS RD1 RD3 RD4 RDS RD1S RD2S RD4S * omit variables with p-values above 0.5 OLS PATENTS RD1 RD3 RDS RD4S * omit one at a time OLS PATENTS RD1 RD3 RD4S OLS PATENTS RD3 RD4S / PREDICT=PRED RESID=ERROR * COMPUTE ABSOLUTE PERCENT ERRORS GENR ABSPCERR=100*ABS(ERROR)/PATENTS PRINT RD PATENTS PRED ERROR ABSPCERR DELETE / ALL STOP