1

If I have a categorical variable with three levels (CatXVar) that I recode into two dummy variables (NYXVar and BostonXVar)such that:

YVar ContXVar  CatXVar NYXVar BostonXVar
0.23 10        NY      1      0
0.1  22.3      Boston  0      1
0.52 11.9      London  0      0

and I want to see whether CatXVar affects the significance of any relationship between YVar and ContXVar, should I run two separate regressions of:

Yvar ~ ContXVar + NYXVar

and

Yvar ~ ContXVar + BostonXVar

or should I run the regression as:

Yvar ~ ContXVar + NYXVar + BostonXVar
Kaleb
  • 285

1 Answers1

1

You can remove the intercept, as suggested in the comments, by including -1 in the model specification. However, you might want to consider reading this before doing that.

Yvar ~ ContXVar + NYXVar + BostonXVar seems to be the safe bet here.

Running two separate regressions essentially means you're estimating two separate models as you don't account for the New York/Boston effect respectively.