* * Example from chapter 6, pp 241-263 * open data bankdata.dat calendar(m) 1988:2 data(format=free,org=columns) 1988:2 1993:1 eom aaa govt34 * graph(footer="Figure 6-1 EOM Balances at a Mutual Savings Bank") # eom * * On page 243, the differencing of the EOM and 3-4 rates are described as * "forward" differences, that is, the value for period T is X(T+1)-X(T), rather * than the more standard backward difference (X(T)-X(T-1)). To get X(T+1) in a * SET instruction, use X{-1}. * set deom = eom{-1}-eom set d34 = govt34{-1}-govt34 * * The SPGRAPH(VFIELDS=4)...SPGRAPH(DONE) wrapper around the four GRAPH * instructions is used to stack the four graphs onto a single page * spgraph(vfields=4) graph(vlabel="D(EOM)") # deom graph(vlabel="AAA") # aaa graph(vlabel="(3-4)") # govt34 graph(vlabel="D(3-4)") # d34 spgraph(done) * @splom(labels=||"D(EOM)","AAA","(3-4)","D(3-4)"||) # deom aaa govt34 d34 * linreg deom * 53 # constant aaa govt34 d34 * * The regression F-test is included in the output from LINREG. You can use the * procedure REGANOVA to get the analysis of variance table as shown on page 254 * @reganova * * If you want to see the covariance/correlation matrix of a regression, include * the option VCV. Note that this shows the actual variances and covariances below * the diagonal, and the correlations above it. * linreg(vcv) deom * 53 # constant aaa govt34 d34 * prj fitted * spgraph(vfields=2,hfields=2,footer="Figure 6-4 Bank data: Plots of residuals") scatter(vlabel="Residuals",hlabel="AAA",axis=horiz) # aaa %resids scatter(vlabel="Residuals",hlabel="D(3-4)",axis=horiz) # d34 %resids scatter(vlabel="Residuals",hlabel="(3-4)",axis=horiz) # govt34 %resids scatter(vlabel="Residuals",hlabel="Fitted",axis=horiz) # fitted %resids spgraph(done) * @histogram(maxgrid=12,distrib=normal,footer="Figure 6-5 Bank data: histogram of residuals") %resids