. use ":Macintosh HD:Anderson - Econ 20:Data:bwght.dta" . reg bwght cigs faminc Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 2, 1385) = 21.27 Model | 17126.2088 2 8563.10442 Prob > F = 0.0000 Residual | 557485.511 1385 402.516614 R-squared = 0.0298 ---------+------------------------------ Adj R-squared = 0.0284 Total | 574611.72 1387 414.283864 Root MSE = 20.063 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- cigs | -.4634075 .0915768 -5.060 0.000 -.6430518 -.2837633 faminc | .0927647 .0291879 3.178 0.002 .0355075 .1500219 _cons | 116.9741 1.048984 111.512 0.000 114.9164 119.0319 ------------------------------------------------------------------------------ . reg cigs faminc Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 1, 1386) = 42.78 Model | 1481.60979 1 1481.60979 Prob > F = 0.0000 Residual | 47996.8419 1386 34.6297561 R-squared = 0.0299 ---------+------------------------------ Adj R-squared = 0.0292 Total | 49478.4517 1387 35.6730005 Root MSE = 5.8847 ------------------------------------------------------------------------------ cigs | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- faminc | -.0551538 .0084321 -6.541 0.000 -.0716948 -.0386129 _cons | 3.688107 .2912973 12.661 0.000 3.116676 4.259538 ------------------------------------------------------------------------------ . predict r1, r . sum r1 Variable | Obs Mean Std. Dev. Min Max ---------+----------------------------------------------------- r1 | 1388 -4.71e-11 5.882583 -3.66053 47.82862 . reg bwght r1 Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 1, 1386) = 25.32 Model | 10307.1563 1 10307.1563 Prob > F = 0.0000 Residual | 564304.563 1386 407.14615 R-squared = 0.0179 ---------+------------------------------ Adj R-squared = 0.0172 Total | 574611.72 1387 414.283864 Root MSE = 20.178 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- r1 | -.4634075 .092102 -5.031 0.000 -.6440818 -.2827333 _cons | 118.6996 .5416022 219.164 0.000 117.6371 119.762 ------------------------------------------------------------------------------ . reg bwght cigs Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 1, 1386) = 32.24 Model | 13060.4194 1 13060.4194 Prob > F = 0.0000 Residual | 561551.30 1386 405.159668 R-squared = 0.0227 ---------+------------------------------ Adj R-squared = 0.0220 Total | 574611.72 1387 414.283864 Root MSE = 20.129 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- cigs | -.5137721 .0904909 -5.678 0.000 -.6912861 -.3362581 _cons | 119.7719 .5723407 209.267 0.000 118.6492 120.8946 ------------------------------------------------------------------------------ . reg bwght cigs male Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 2, 1385) = 19.90 Model | 16053.1711 2 8026.58556 Prob > F = 0.0000 Residual | 558558.549 1385 403.291371 R-squared = 0.0279 ---------+------------------------------ Adj R-squared = 0.0265 Total | 574611.72 1387 414.283864 Root MSE = 20.082 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- cigs | -.5136516 .0902821 -5.689 0.000 -.690756 -.3365473 male | 2.939342 1.079007 2.724 0.007 .8226776 5.056007 _cons | 118.2406 .8012893 147.563 0.000 116.6687 119.8124 ------------------------------------------------------------------------------ . corr cigs male (obs=1388) | cigs male ---------+------------------ cigs | 1.0000 male | -0.0005 1.0000 . clear . use sleep75 . desc Contains data from sleep75.dta obs: 706 vars: 34 13 Sep 2000 15:38 size: 49,420 (94.6% of memory free) ------------------------------------------------------------------------------- 1. age byte %9.0g in years 2. black byte %9.0g =1 if black 3. case int %9.0g identifier 4. clerical float %9.0g =1 if clerical worker 5. construc float %9.0g =1 if construction worker 6. educ byte %9.0g years of schooling 7. earns74 float %9.0g total earnings, 1974 8. gdhlth byte %9.0g =1 if in good or excellent health 9. inlf byte %9.0g =1 if in labor force 10. leis1 int %9.0g sleep - totwrk 11. leis2 int %9.0g slpnaps - totwrk 12. leis3 int %9.0g rlxall - totwrk 13. smsa byte %9.0g = 1 if live in smsa 14. lhrwage float %9.0g log hourly wage 15. lothinc float %9.0g log othinc, unless othinc < 0 16. male byte %9.0g = 1 if male 17. marr byte %9.0g = 1 if married 18. prot byte %9.0g = 1 if Protestant 19. rlxall int %9.0g slpnaps + personal activs 20. selfe byte %9.0g =1 if self employed 21. sleep int %9.0g mins sleep at night, per week 22. slpnaps int %9.0g mins sleep, including naps, per week 23. south byte %9.0g =1 if live in south 24. spsepay float %9.0g spousal wage income 25. spwrk75 byte %9.0g =1 if spouse works 26. totwrk int %9.0g mins worked per week 27. union byte %9.0g =1 if belong to union 28. worknrm int %9.0g mins work main job 29. workscnd int %9.0g mins work second job 30. exper byte %9.0g age - educ - 6 31. yngkid byte %9.0g =1 if children < 3 present 32. yrsmarr byte %9.0g years married 33. hrwage float %9.0g hourly wage 34. agesq int %9.0g age^2 ------------------------------------------------------------------------------- Sorted by: . reg slpnaps lhrwage Source | SS df MS Number of obs = 532 ---------+------------------------------ F( 1, 530) = 5.32 Model | 1296781.81 1 1296781.81 Prob > F = 0.0214 Residual | 129074879 530 243537.507 R-squared = 0.0099 ---------+------------------------------ Adj R-squared = 0.0081 Total | 130371661 531 245521.018 Root MSE = 493.50 ------------------------------------------------------------------------------ slpnaps | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- lhrwage | -78.31265 33.93762 -2.308 0.021 -144.9814 -11.64389 _cons | 3490.295 53.06822 65.770 0.000 3386.045 3594.545 ------------------------------------------------------------------------------ . reg slpnaps lhrwage union Source | SS df MS Number of obs = 532 ---------+------------------------------ F( 2, 529) = 2.66 Model | 1297595.92 2 648797.961 Prob > F = 0.0710 Residual | 129074065 529 243996.341 R-squared = 0.0100 ---------+------------------------------ Adj R-squared = 0.0062 Total | 130371661 531 245521.018 Root MSE = 493.96 ------------------------------------------------------------------------------ slpnaps | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- lhrwage | -78.18686 34.03931 -2.297 0.022 -145.0557 -11.31804 union | -2.99276 51.8109 -0.058 0.954 -104.7731 98.7876 _cons | 3490.773 53.75937 64.933 0.000 3385.165 3596.381 ------------------------------------------------------------------------------ . corr lhrwage union (obs=532) | lhrwage union ---------+------------------ lhrwage | 1.0000 union | 0.0640 1.0000 . reg slpnaps lhrwage union Source | SS df MS Number of obs = 532 ---------+------------------------------ F( 2, 529) = 2.66 Model | 1297595.92 2 648797.961 Prob > F = 0.0710 Residual | 129074065 529 243996.341 R-squared = 0.0100 ---------+------------------------------ Adj R-squared = 0.0062 Total | 130371661 531 245521.018 Root MSE = 493.96 ------------------------------------------------------------------------------ slpnaps | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- lhrwage | -78.18686 34.03931 -2.297 0.022 -145.0557 -11.31804 union | -2.99276 51.8109 -0.058 0.954 -104.7731 98.7876 _cons | 3490.773 53.75937 64.933 0.000 3385.165 3596.381 ------------------------------------------------------------------------------ . predict yhat (option xb assumed; fitted values) (174 missing values generated) . corr slpnaps yhat (obs=532) | slpnaps yhat ---------+------------------ slpnaps | 1.0000 yhat | 0.0998 1.0000 . display .0998^2 .00996004 . reg slpnaps lhrwage union smsa south marr Source | SS df MS Number of obs = 532 ---------+------------------------------ F( 5, 526) = 1.37 Model | 1675858.29 5 335171.657 Prob > F = 0.2340 Residual | 128695802 526 244668.826 R-squared = 0.0129 ---------+------------------------------ Adj R-squared = 0.0035 Total | 130371661 531 245521.018 Root MSE = 494.64 ------------------------------------------------------------------------------ slpnaps | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- lhrwage | -74.31097 34.71075 -2.141 0.033 -142.4997 -6.122245 union | -2.395428 52.12856 -0.046 0.963 -104.8012 100.0103 smsa | -24.42704 46.27051 -0.528 0.598 -115.3247 66.47065 south | 50.36709 54.79753 0.919 0.358 -57.28179 158.016 marr | 14.11287 55.79379 0.253 0.800 -95.49314 123.7189 _cons | 3472.738 72.00131 48.232 0.000 3331.292 3614.183 ------------------------------------------------------------------------------ . clear . use bwght . reg bwght cigs Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 1, 1386) = 32.24 Model | 13060.4194 1 13060.4194 Prob > F = 0.0000 Residual | 561551.30 1386 405.159668 R-squared = 0.0227 ---------+------------------------------ Adj R-squared = 0.0220 Total | 574611.72 1387 414.283864 Root MSE = 20.129 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- cigs | -.5137721 .0904909 -5.678 0.000 -.6912861 -.3362581 _cons | 119.7719 .5723407 209.267 0.000 118.6492 120.8946 ------------------------------------------------------------------------------ . reg bwght cigs faminc Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 2, 1385) = 21.27 Model | 17126.2088 2 8563.10442 Prob > F = 0.0000 Residual | 557485.511 1385 402.516614 R-squared = 0.0298 ---------+------------------------------ Adj R-squared = 0.0284 Total | 574611.72 1387 414.283864 Root MSE = 20.063 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- cigs | -.4634075 .0915768 -5.060 0.000 -.6430518 -.2837633 faminc | .0927647 .0291879 3.178 0.002 .0355075 .1500219 _cons | 116.9741 1.048984 111.512 0.000 114.9164 119.0319 ------------------------------------------------------------------------------ . reg bwght faminc Source | SS df MS Number of obs = 1388 ---------+------------------------------ F( 1, 1386) = 16.65 Model | 6819.0527 1 6819.0527 Prob > F = 0.0000 Residual | 567792.667 1386 409.662819 R-squared = 0.0119 ---------+------------------------------ Adj R-squared = 0.0112 Total | 574611.72 1387 414.283864 Root MSE = 20.24 ------------------------------------------------------------------------------ bwght | Coef. Std. Err. t P>|t| [95% Conf. Interval] ---------+-------------------------------------------------------------------- faminc | .1183234 .0290016 4.080 0.000 .0614317 .1752152 _cons | 115.265 1.001901 115.046 0.000 113.2996 117.2304 ------------------------------------------------------------------------------ . log close