[Stata Program] use http://www.gseis.ucla.edu/courses/data/laochi regress api99 district tabulate district,summ (pctmeal) tabulate district,summ (pctel) tabulate district,summ (pctcred) tabulate district,summ (avged) sw regress api99 pctmeal pctel pctcred avged district, pe(.05) vif generate inter=pctmeal*district regress api99 pctmeal pctel pctcred avged district inter vif test inter [Stata Program] use http://www.gseis.ucla.edu/courses/data/laochi regress api99 district Source | SS df MS Number of obs = 307 -------------+------------------------------ F( 1, 305) = 30.02 Model | 496972.375 1 496972.375 Prob > F = 0.0000 Residual | 5049389.03 305 16555.3739 R-squared = 0.0896 -------------+------------------------------ Adj R-squared = 0.0866 Total | 5546361.41 306 18125.3641 Root MSE = 128.67 ------------------------------------------------------------------------------ api99 | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- district | 95.42236 17.4162 5.48 0.000 61.15123 129.6935 _cons | 487.1412 22.66658 21.49 0.000 442.5385 531.7439 ------------------------------------------------------------------------------ tabulate district,summ (pctmeal) | Summary of percent free/reduced | meal 1=LA, 2=OC | Mean Std. Dev. Freq. ------------+------------------------------------ 1 | 55.651042 27.186733 192 2 | 36.436364 27.51482 55 ------------+------------------------------------ Total | 51.37247 28.358745 247 tabulate district,summ (pctel) | Summary of percent english language | learners 1=LA, 2=OC | Mean Std. Dev. Freq. ------------+------------------------------------ 1 | 26.025424 16.929874 236 2 | 25.816901 21.633512 71 ------------+------------------------------------ Total | 25.977199 18.088277 307 tabulate district,summ (pctcred) | Summary of percent credentialed | teachers 1=LA, 2=OC | Mean Std. Dev. Freq. ------------+------------------------------------ 1 | 78.521186 12.835273 236 2 | 94.098592 6.125252 71 ------------+------------------------------------ Total | 82.123779 13.356022 307 tabulate district,summ (avged) | Summary of average parent education 1=LA, 2=OC | Mean Std. Dev. Freq. ------------+------------------------------------ 1 | 2.7158621 .66753092 232 2 | 2.8973134 .74186413 67 ------------+------------------------------------ Total | 2.7565217 .68778554 299 sw regress api99 pctmeal pctel pctcred avged district, pe(.05) begin with empty model p = 0.0000 < 0.0500 adding avged p = 0.0000 < 0.0500 adding pctcred p = 0.0000 < 0.0500 adding pctmeal p = 0.0146 < 0.0500 adding district p = 0.0061 < 0.0500 adding pctel Source | SS df MS Number of obs = 240 -------------+------------------------------ F( 5, 234) = 344.62 Model | 3528999.67 5 705799.935 Prob > F = 0.0000 Residual | 479240.489 234 2048.03628 R-squared = 0.8804 -------------+------------------------------ Adj R-squared = 0.8779 Total | 4008240.16 239 16770.8793 Root MSE = 45.255 ------------------------------------------------------------------------------ api99 | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- avged | 108.8152 9.034357 12.04 0.000 91.01616 126.6143 pctcred | 2.556331 .3042847 8.40 0.000 1.956843 3.155818 pctmeal | -.6542403 .180714 -3.62 0.000 -1.010275 -.298206 district | 27.49939 8.692214 3.16 0.002 10.37439 44.62438 pctel | -.7927081 .2864709 -2.77 0.006 -1.3571 -.2283164 _cons | 113.9728 39.74609 2.87 0.005 35.66689 192.2787 ------------------------------------------------------------------------------ vif Variable | VIF 1/VIF -------------+---------------------- avged | 4.17 0.239822 pctel | 3.27 0.306259 pctmeal | 3.02 0.331065 pctcred | 1.71 0.585984 district | 1.50 0.665468 -------------+---------------------- Mean VIF | 2.73 generate inter=pctmeal*district regress api99 pctmeal pctel pctcred avged district inter Source | SS df MS Number of obs = 240 -------------+------------------------------ F( 6, 233) = 289.23 Model | 3533784.73 6 588964.121 Prob > F = 0.0000 Residual | 474455.437 233 2036.28943 R-squared = 0.8816 -------------+------------------------------ Adj R-squared = 0.8786 Total | 4008240.16 239 16770.8793 Root MSE = 45.125 ------------------------------------------------------------------------------ api99 | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- pctmeal | -1.112564 .3490872 -3.19 0.002 -1.800335 -.424793 pctel | -.9115164 .2959759 -3.08 0.002 -1.494647 -.3283854 pctcred | 2.484215 .3070363 8.09 0.000 1.879293 3.089137 avged | 109.8655 9.034425 12.16 0.000 92.06587 127.6651 district | 11.3647 13.63468 0.83 0.405 -15.49831 38.22771 inter | .4318347 .2817046 1.53 0.127 -.123179 .9868484 _cons | 137.7663 42.563 3.24 0.001 53.90878 221.6238 ------------------------------------------------------------------------------ vif Variable | VIF 1/VIF -------------+---------------------- inter | 12.07 0.082848 pctmeal | 11.34 0.088213 avged | 4.19 0.238443 district | 3.72 0.268906 pctel | 3.51 0.285259 pctcred | 1.75 0.572227 -------------+---------------------- Mean VIF | 6.10 test inter ( 1) inter = 0.0 F( 1, 233) = 2.35 Prob > F = 0.1266