---------------------------------------------------------------------------------------------------------------- log: C:\EC471\ch6.log log type: text opened on: 14 Dec 2003, 23:53:15 . set more 1; . ***********************************; . use caschool.dta; . *; . *; . * Decription of Data; . * dist_code -- district Code; . * Read_scr -- avg Reading Score; . * Math_scr -- avg Math Score; . * County -- county; . * District -- District; . * gr_span -- grade span of district; . * enrl_tot -- total enrollment; . * teachers -- number of teachers; . * computer -- number of computers; . * testscr -- avg test score (= (read_scr+math_scr)/2 ); . * comp_stu -- computers per student ( = computer/enrl_tot); . * expn_stu -- expentitures per student; . * str -- student teacher ration (teachers/enrl_tot); . * el_pct -- percent of English Learners; . * Meal_pct -- Percent qualifying for reduced-price lunch; . * calw_pct -- Percent qualifying for CalWorks; . * avginc -- district average income (in $1000's); . **************************************************************; . ***** Transformed Variables ********; . *************************************************************; . gen avginc2 = avginc*avginc; . gen avginc3 = avginc2*avginc; . gen loginc = ln(avginc); . gen logtest = ln(testscr); . gen loginc2 = loginc*loginc; . gen loginc3 = loginc2*loginc; . gen histr = (str>=20); . gen hiel = (el_pct >= 10); . gen hisxhie = histr*hiel; . gen strxhiel = str*hiel; . gen strxelpc = str*el_pct; . gen sttr2 = str*str; . gen sttr3 = sttr2*str; . gen str2hiel = sttr2*hiel; . gen str3hiel = sttr3*hiel; . reg logtest str el_pct, r; Regression with robust standard errors Number of obs = 420 F( 2, 417) = 225.38 Prob > F = 0.0000 R-squared = 0.4328 Root MSE = .02198 ------------------------------------------------------------------------------ | Robust logtest | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.0016339 .000655 -2.49 0.013 -.0029214 -.0003465 el_pct | -.0010025 .0000478 -20.99 0.000 -.0010964 -.0009087 _cons | 6.530823 .0131872 495.24 0.000 6.504901 6.556745 ------------------------------------------------------------------------------ . **************************************************************; . ***** EQ 6.2 ********; . *************************************************************; . reg testscr avginc avginc2, r; Regression with robust standard errors Number of obs = 420 F( 2, 417) = 428.52 Prob > F = 0.0000 R-squared = 0.5562 Root MSE = 12.724 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- avginc | 3.850995 .2680941 14.36 0.000 3.32401 4.377979 avginc2 | -.0423085 .0047803 -8.85 0.000 -.051705 -.0329119 _cons | 607.3017 2.901754 209.29 0.000 601.5978 613.0056 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .55404453 . **************************************************************; . ***** EQ 6.11 ********; . *************************************************************; . reg testscr avginc avginc2 avginc3, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 270.18 Prob > F = 0.0000 R-squared = 0.5584 Root MSE = 12.707 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- avginc | 5.018677 .7073505 7.10 0.000 3.628251 6.409104 avginc2 | -.0958052 .0289537 -3.31 0.001 -.1527191 -.0388913 avginc3 | .0006855 .0003471 1.98 0.049 3.27e-06 .0013677 _cons | 600.079 5.102062 117.61 0.000 590.0499 610.108 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .555228 . test avginc2 avginc3; ( 1) avginc2 = 0 ( 2) avginc3 = 0 F( 2, 416) = 37.69 Prob > F = 0.0000 . **************************************************************; . ***** EQ 6.18 ********; . *************************************************************; . reg testscr loginc, r; Regression with robust standard errors Number of obs = 420 F( 1, 418) = 679.70 Prob > F = 0.0000 R-squared = 0.5625 Root MSE = 12.618 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- loginc | 36.41968 1.396943 26.07 0.000 33.67378 39.16559 _cons | 557.8323 3.83994 145.27 0.000 550.2843 565.3803 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .56146052 . **************************************************************; . ***** EQ 6.23 ********; . *************************************************************; . reg logtest loginc, r; Regression with robust standard errors Number of obs = 420 F( 1, 418) = 667.78 Prob > F = 0.0000 R-squared = 0.5578 Root MSE = .01938 ------------------------------------------------------------------------------ | Robust logtest | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- loginc | .055419 .0021446 25.84 0.000 .0512035 .0596345 _cons | 6.336349 .0059246 1069.50 0.000 6.324704 6.347995 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .5567249 . **************************************************************; . ***** EQ 6.24 ********; . *************************************************************; . reg logtest avginc, r; Regression with robust standard errors Number of obs = 420 F( 1, 418) = 263.86 Prob > F = 0.0000 R-squared = 0.4982 Root MSE = .02065 ------------------------------------------------------------------------------ | Robust logtest | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- avginc | .0028441 .0001751 16.24 0.000 .0024999 .0031882 _cons | 6.439362 .0028938 2225.21 0.000 6.433674 6.445051 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .49701045 . **************************************************************; . ***** EQ 6.26 ********; . *************************************************************; . reg testscr loginc loginc2 loginc3, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 255.16 Prob > F = 0.0000 R-squared = 0.5631 Root MSE = 12.639 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- loginc | 113.3807 87.88362 1.29 0.198 -59.37061 286.132 loginc2 | -26.91059 31.74566 -0.85 0.397 -89.3125 35.49131 loginc3 | 3.063112 3.736877 0.82 0.413 -4.282403 10.40863 _cons | 486.1352 79.3825 6.12 0.000 330.0944 642.176 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .55999444 . **************************************************************; . ***** EQ 6.30 ********; . *************************************************************; . reg testscr hiel histr hisxhie, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 60.20 Prob > F = 0.0000 R-squared = 0.2956 Root MSE = 16.049 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- hiel | -18.16295 2.345952 -7.74 0.000 -22.77435 -13.55155 histr | -1.907842 1.932215 -0.99 0.324 -5.705964 1.890279 hisxhie | -3.494335 3.121226 -1.12 0.264 -9.629676 2.641006 _cons | 664.1433 1.388089 478.46 0.000 661.4147 666.8718 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .29047511 . **************************************************************; . ***** EQ 6.34 ********; . *************************************************************; . reg testscr str hiel strxhiel, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 63.67 Prob > F = 0.0000 R-squared = 0.3103 Root MSE = 15.88 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.9684601 .5891016 -1.64 0.101 -2.126447 .1895267 hiel | 5.639141 19.51456 0.29 0.773 -32.72029 43.99857 strxhiel | -1.276613 .9669194 -1.32 0.187 -3.17727 .6240435 _cons | 682.2458 11.86781 57.49 0.000 658.9175 705.5742 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .30536755 . **************************************************************; . ***** EQ 6.37 ********; . *************************************************************; . reg testscr str el_pct strxelpc, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 155.05 Prob > F = 0.0000 R-squared = 0.4264 Root MSE = 14.482 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -1.117018 .5875135 -1.90 0.058 -2.271884 .0378468 el_pct | -.6729116 .3741231 -1.80 0.073 -1.408319 .0624958 strxelpc | .0011618 .0185357 0.06 0.950 -.0352736 .0375971 _cons | 686.3385 11.75935 58.37 0.000 663.2234 709.4537 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .42229896 . **************************************************************; . ***** Table 6.2 ********; . *************************************************************; . ** col(1); . reg testscr str el_pct meal_pct, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 453.48 Prob > F = 0.0000 R-squared = 0.7745 Root MSE = 9.0801 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.9983092 .2700799 -3.70 0.000 -1.529201 -.4674179 el_pct | -.1215733 .0328317 -3.70 0.000 -.18611 -.0570366 meal_pct | -.5473456 .0241072 -22.70 0.000 -.5947328 -.4999583 _cons | 700.15 5.56845 125.74 0.000 689.2042 711.0958 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .77288978 . ** col(2); . reg testscr str el_pct meal_pct loginc, r; Regression with robust standard errors Number of obs = 420 F( 4, 415) = 417.20 Prob > F = 0.0000 R-squared = 0.7962 Root MSE = 8.6426 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.734326 .2567803 -2.86 0.004 -1.239078 -.2295738 el_pct | -.1755344 .0336606 -5.21 0.000 -.241701 -.1093678 meal_pct | -.3982342 .0331741 -12.00 0.000 -.4634443 -.333024 loginc | 11.56897 1.818811 6.36 0.000 7.993736 15.1442 _cons | 658.552 8.641528 76.21 0.000 641.5653 675.5386 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .79424845 . ** col(3); . reg testscr str hiel strxhiel, r; Regression with robust standard errors Number of obs = 420 F( 3, 416) = 63.67 Prob > F = 0.0000 R-squared = 0.3103 Root MSE = 15.88 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.9684601 .5891016 -1.64 0.101 -2.126447 .1895267 hiel | 5.639141 19.51456 0.29 0.773 -32.72029 43.99857 strxhiel | -1.276613 .9669194 -1.32 0.187 -3.17727 .6240435 _cons | 682.2458 11.86781 57.49 0.000 658.9175 705.5742 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .30536755 . test str strxhiel; ( 1) str = 0 ( 2) strxhiel = 0 F( 2, 416) = 5.64 Prob > F = 0.0038 . ** col(4); . reg testscr str hiel strxhiel meal_pct loginc, r; Regression with robust standard errors Number of obs = 420 F( 5, 414) = 335.85 Prob > F = 0.0000 R-squared = 0.7974 Root MSE = 8.6286 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | -.5310319 .3418468 -1.55 0.121 -1.203004 .1409399 hiel | 5.498208 9.795 0.56 0.575 -13.75593 24.75234 strxhiel | -.5776664 .4957779 -1.17 0.245 -1.552222 .3968895 meal_pct | -.4113776 .0288276 -14.27 0.000 -.4680443 -.3547109 loginc | 12.12447 1.797513 6.75 0.000 8.591079 15.65786 _cons | 653.6661 9.869378 66.23 0.000 634.2658 673.0665 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .79491122 . test str strxhiel; ( 1) str = 0 ( 2) strxhiel = 0 F( 2, 414) = 5.92 Prob > F = 0.0029 . ** col(5); . reg testscr str sttr2 sttr3 hiel meal_pct loginc, r; Regression with robust standard errors Number of obs = 420 F( 6, 413) = 281.14 Prob > F = 0.0000 R-squared = 0.8011 Root MSE = 8.5593 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | 64.33924 24.86058 2.59 0.010 15.47019 113.2083 sttr2 | -3.423904 1.249903 -2.74 0.006 -5.88087 -.9669381 sttr3 | .0592891 .020763 2.86 0.005 .0184748 .1001035 hiel | -5.473989 1.033762 -5.30 0.000 -7.50608 -3.441898 meal_pct | -.4200571 .0285258 -14.73 0.000 -.4761309 -.3639832 loginc | 11.74819 1.771438 6.63 0.000 8.266031 15.23035 _cons | 252.0484 163.6345 1.54 0.124 -69.61187 573.7087 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .79819613 . test str sttr2 sttr3; ( 1) str = 0 ( 2) sttr2 = 0 ( 3) sttr3 = 0 F( 3, 413) = 6.31 Prob > F = 0.0003 . test sttr2 sttr3; ( 1) sttr2 = 0 ( 2) sttr3 = 0 F( 2, 413) = 6.17 Prob > F = 0.0023 . ** col(6); . reg testscr str sttr2 sttr3 hiel strxhiel str2hiel str3hiel meal_pct loginc, r; Regression with robust standard errors Number of obs = 420 F( 9, 410) = 199.84 Prob > F = 0.0000 R-squared = 0.8031 Root MSE = 8.5475 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | 83.70232 28.49676 2.94 0.003 27.68434 139.7203 sttr2 | -4.380821 1.44102 -3.04 0.003 -7.21353 -1.548112 sttr3 | .0749233 .0240081 3.12 0.002 .027729 .1221176 hiel | 816.0914 327.6756 2.49 0.013 171.9577 1460.225 strxhiel | -123.2844 50.21297 -2.46 0.014 -221.9914 -24.57741 str2hiel | 6.121247 2.541986 2.41 0.016 1.124295 11.1182 str3hiel | -.1006001 .0425095 -2.37 0.018 -.1841639 -.0170363 meal_pct | -.4177876 .0287011 -14.56 0.000 -.4742073 -.3613679 loginc | 11.80035 1.778008 6.64 0.000 8.305203 15.2955 _cons | 122.3489 185.5184 0.66 0.510 -242.3369 487.0348 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .79875079 . test str sttr2 sttr3 strxhiel str2hiel str3hiel; ( 1) str = 0 ( 2) sttr2 = 0 ( 3) sttr3 = 0 ( 4) strxhiel = 0 ( 5) str2hiel = 0 ( 6) str3hiel = 0 F( 6, 410) = 4.96 Prob > F = 0.0001 . test sttr2 sttr3; ( 1) sttr2 = 0 ( 2) sttr3 = 0 F( 2, 410) = 5.81 Prob > F = 0.0033 . test strxhiel str2hiel str3hiel; ( 1) strxhiel = 0 ( 2) str2hiel = 0 ( 3) str3hiel = 0 F( 3, 410) = 2.69 Prob > F = 0.0460 . ** col(7); . reg testscr str sttr2 sttr3 el_pct meal_pct loginc, r; Regression with robust standard errors Number of obs = 420 F( 6, 413) = 280.81 Prob > F = 0.0000 R-squared = 0.8007 Root MSE = 8.5679 ------------------------------------------------------------------------------ | Robust testscr | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- str | 65.28538 25.2587 2.58 0.010 15.63374 114.937 sttr2 | -3.465538 1.270896 -2.73 0.007 -5.96377 -.9673058 sttr3 | .0599085 .0211206 2.84 0.005 .0183912 .1014258 el_pct | -.1656868 .0343658 -4.82 0.000 -.2332404 -.0981332 meal_pct | -.4024178 .0332667 -12.10 0.000 -.4678109 -.3370247 loginc | 11.50893 1.806404 6.37 0.000 7.958041 15.05983 _cons | 244.8062 165.7225 1.48 0.140 -80.95849 570.5709 ------------------------------------------------------------------------------ . dis "Adjusted Rsquared = " _result(8); Adjusted Rsquared = .79778898 . test str sttr2 sttr3; ( 1) str = 0 ( 2) sttr2 = 0 ( 3) sttr3 = 0 F( 3, 413) = 5.91 Prob > F = 0.0006 . test sttr2 sttr3; ( 1) sttr2 = 0 ( 2) sttr3 = 0 F( 2, 413) = 5.96 Prob > F = 0.0028 . log close; log: C:\EC471\ch6.log log type: text closed on: 14 Dec 2003, 23:53:17 --------------------------------------------------------------------------------------------------------------