options nodate nonumber ps=54 ls=80; data arg_wheat; infile "argentine_wheat.dat"; input year 1-8 wheatyld 9-16 rain 17-24 temp 25-32; raintemp=rain*temp; run; ods PDF file="argwheat_sas1.pdf"; ods graphics on; proc reg plots=diagnostics plots(label)=(residuals); var year; model wheatyld = rain temp raintemp / dw; output out=arg_wheat_r r=e; run; data arg_wheat_r; set arg_wheat_r; e2=e**2; proc reg; model e2 = rain temp raintemp; run; ods graphics off; ods PDF close; quit; proc model data=arg_wheat; parms b0 b1 b2 b3; wheatyld = b0 + b1*rain + b2*temp + b3*raintemp; fit wheatyld / breusch = (1 rain temp raintemp); /* This is based on studentized residuals */ run; quit;