4
$\begingroup$

I am confused trying to interpret how two observations are otherwise identical but differ by a dummy variable. For example if we have the following model with a factor variable race being White race the reference category:

Call:
lm(formula = Score ~ ., data = pisaTrain)

Residuals:
    Min      1Q  Median      3Q     Max 
-247.44  -48.86    1.86   49.77  217.18 

Coefficients:
                                                Estimate Std. Error t value Pr(>|t|)    
(Intercept)                                   143.766333  33.841226   4.248 2.24e-05 ***
grade                                          29.542707   2.937399  10.057  < 2e-16 ***
male                                          -14.521653   3.155926  -4.601 4.42e-06 ***
raceEuropean                                  -67.277327  16.786935  -4.008 6.32e-05 ***
raceAsian                                     -4.110325   9.220071  -0.446  0.65578    
raceBlack                                     -67.012347   5.460883 -12.271  < 2e-16 ***
raceHispanic                                   38.975486   5.177743  -7.528 7.29e-14 ***
raceOther                                     -16.922522   8.496268  -1.992  0.04651 *  

Given two people that are otherwise identical, what would be the absolute difference in predicted score given that one person is European and the other is Hispanic? Also in the case when the race is white, the difference will differ by the coefficient on other variables?

Somebody might help me out, thank you in advance!

$\endgroup$
5
$\begingroup$

If your only difference is European vs Hispanic you can reason like this. Everything besides the race factor is the same, so let's just call the contributions of all of those $S$ for same. Then:

$$ E = S + -67.27 \times 1 $$ $$ H = S + 38.98 \times 1 $$

So the difference is:

$$ E - H = (S + -67.27) - (S + 38.98) = -67.27 - 39.98 $$

because the $S$'s cancel. In the case of white, the calculation would be:

$$ W = S $$

so

$$ E - W = (S + -67.27) - S = -67.27 $$

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.