clear
cd "E:\Econ 107\LAB1\data"
use cps08.dta
\[AHE=\beta_0+\beta_1 AGE+u\]
With robust standard error
reg ahe age, robust
Results:
Linear regression Number of obs = 7,711
F(1, 7709) = 225.70
Prob > F = 0.0000
R-squared = 0.0290
Root MSE = 9.9919
------------------------------------------------------------------------------
| Robust
ahe | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
age | .6049863 .0402701 15.02 0.000 .526046 .6839266
_cons | 1.082275 1.167013 0.93 0.354 -1.205388 3.369938
------------------------------------------------------------------------------
With robust standard error
reg ahe age, robust
Results:
Source | SS df MS Number of obs = 7,711
-------------+---------------------------------- F(1, 7709) = 230.43
Model | 23005.7375 1 23005.7375 Prob > F = 0.0000
Residual | 769645.718 7,709 99.8372964 R-squared = 0.0290
-------------+---------------------------------- Adj R-squared = 0.0289
Total | 792651.456 7,710 102.80823 Root MSE = 9.9919
------------------------------------------------------------------------------
ahe | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
age | .6049863 .0398542 15.18 0.000 .5268613 .6831113
_cons | 1.082275 1.184255 0.91 0.361 -1.239187 3.403737
------------------------------------------------------------------------------
The difference is the standard error Std. Err..
\[AHE=\beta_0+\beta_1 AGE+\beta_2Female+\beta_3Bachelor+u\]
reg ahe age female bachelor, robust
Results:
Linear regression Number of obs = 7,711
F(3, 7707) = 555.48
Prob > F = 0.0000
R-squared = 0.1998
Root MSE = 9.0718
------------------------------------------------------------------------------
| Robust
ahe | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
age | .5852144 .0365302 16.02 0.000 .5136052 .6568236
female | -3.664026 .2076129 -17.65 0.000 -4.071003 -3.257048
bachelor | 8.083001 .2126945 38.00 0.000 7.666062 8.49994
_cons | -.6356977 1.083075 -0.59 0.557 -2.758818 1.487423
------------------------------------------------------------------------------
The results regarding the effects of Age and AHE from (a) and (b) do not change a lot. Thus, this model does not suffer from omitted variable bias.
Bob is a 26-year-old male worker with a high school diploma:
dis 30*.5852144-3.664026*0+8.083001*0-.6356977
Alexis is a 30-year-old female worker with a college degree:
dis 30*.5852144-3.664026*1+8.083001*1-.6356977
clear
cd "E:\Econ 107\LAB1\data"
use TeachingRatings.dta
reg course_eval beauty, robust
Results:
Linear regression Number of obs = 463
F(1, 461) = 16.94
Prob > F = 0.0000
R-squared = 0.0357
Root MSE = .54545
------------------------------------------------------------------------------
| Robust
course_eval | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
beauty | .1330014 .0323189 4.12 0.000 .0694908 .1965121
_cons | 3.998272 .0253493 157.73 0.000 3.948458 4.048087
------------------------------------------------------------------------------
reg course_eval beauty, robust
outreg2 using TeacherTable.xml, replace
reg course_eval beauty age, robust
outreg2 using TeacherTable.xml
reg course_eval beauty age female, robust
outreg2 using TeacherTable.xml
reg course_eval beauty age female intro, robust
outreg2 using TeacherTable.xml
reg course_eval beauty age female intro nnenglish, robust
outreg2 using TeacherTable.xml
reg course_eval beauty age female intro nnenglish minority, robust
outreg2 using TeacherTable.xml
reg course_eval beauty age female intro nnenglish minority onecredit, robust
outreg2 using TeacherTable.xml