Options ls=74; title 'North Carolina Retail Sales in million $'; title2 "Quarterly starting in 1983"; Data NCSALES; input qsales t t2 s1 s2 s3 s4 date :yyq6.; if t2 = . then t2=t*t; t3=t*t2; qtr=qtr(date); format date YYQ4.; cards; 9485.68 2 4 1 0 0 0 1983Q1 11164.09 3 9 0 1 0 0 1983Q2 11797.33 4 16 0 0 1 0 1983Q3 12459.68 5 25 0 0 0 1 1983Q4 11176.09 6 36 1 0 0 0 1984Q1 12854.22 7 49 0 1 0 0 1984Q2 12623.74 8 64 0 0 1 0 1984Q3 13361.42 9 81 0 0 0 1 1984Q4 11733.86 10 100 1 0 0 0 1985Q1 13871.86 11 121 0 1 0 0 1985Q2 14320.36 12 144 0 0 1 0 1985Q3 13980.60 13 169 0 0 0 1 1985Q4 12689.53 14 196 1 0 0 0 1986Q1 14352.02 15 225 0 1 0 0 1986Q2 14631.02 16 256 0 0 1 0 1986Q3 14551.36 17 289 0 0 0 1 1986Q4 12841.36 18 324 1 0 0 0 1987Q1 15421.21 19 361 0 1 0 0 1987Q2 15429.38 20 400 0 0 1 0 1987Q3 15765.01 21 441 0 0 0 1 1987Q4 14550.21 22 484 1 0 0 0 1988Q1 16286.77 23 529 0 1 0 0 1988Q2 16303.19 24 576 0 0 1 0 1988Q3 16829.22 25 625 0 0 0 1 1988Q4 15142.81 26 676 1 0 0 0 1989Q1 17136.62 27 729 0 1 0 0 1989Q2 16896.99 28 784 0 0 1 0 1989Q3 16316.87 29 841 0 0 0 1 1989Q4 14856.30 30 900 1 0 0 0 1990Q1 16305.90 31 961 0 1 0 0 1990Q2 16110.51 32 1024 0 0 1 0 1990Q3 16622.21 33 1089 0 0 0 1 1990Q4 14724.70 34 1156 1 0 0 0 1991Q1 16583.98 35 1225 0 1 0 0 1991Q2 16364.86 36 1296 0 0 1 0 1991Q3 17013.34 37 1369 0 0 0 1 1991Q4 15605.81 38 1444 1 0 0 0 1992Q1 17607.50 39 1521 0 1 0 0 1992Q2 17831.79 40 1600 0 0 1 0 1992Q3 17837.50 41 1681 0 0 0 1 1992Q4 17160.43 42 1764 1 0 0 0 1993Q1 18922.63 43 1849 0 1 0 0 1993Q2 19358.83 44 1936 0 0 1 0 1993Q3 19830.99 45 2025 0 0 0 1 1993Q4 18765.37 46 2116 1 0 0 0 1994Q1 20587.12 47 2209 0 1 0 0 1994Q2 21130.73 48 2304 0 0 1 0 1994Q3 22657.68 49 2401 0 0 0 1 1994Q4 . 50 2500 1 0 0 0 1995Q1 . 51 2601 0 1 0 0 1995Q2 . 52 2704 0 0 1 0 1995Q3 . 53 2809 0 0 0 1 1995Q4 ; Proc Print data=NCSales; run; Proc Gplot data=NCSales; Plot qsales*date; symbol1 v=none i=join c=red; run; proc reg data=NCSales; model qsales = t t2 t3 S1 S2 S3; output out=out1 predicted=P; proc gplot data=out1; plot (qsales p)*date/overlay; symbol2 v=none i=join c=black; run;