* * Example 19.5 from page 580 * open data tablef5-1[1].txt calendar(q) 1950 data(format=prn,org=columns) 1950:1 2000:4 year qtr realgdp realcons realinvs realgovt realdpi $ cpi_u m1 tbilrate unemp pop infl realint * set logc = log(realcons) set logy = log(realgdp) set delc = logc-logc{1} set dely = logy-logy{1} * graph(footer="Figure 19.3 Consumption and Income Data",key=attached) 2 # logc # logy * * Estimate regression using NLLS. Note that the standard errors in the text are * computed using e'e/T for sigma**2, while RATS uses e'e/(T-k) * nonlin mu b0 gamma theta frml ecm delc = mu+(gamma-1)*(logc{1}-theta*logy{1})+b0*dely nlls(frml=ecm) * set eqerror = (gamma-1)*(logc-theta*logy) graph(footer="Figure 19.4 Consumption-Income Equilibrium Errors") 1 # eqerror