5

My dependent variable is corruption. I want to test the effect of press freedom and democracy on corruption. The measure for press freedom varies from 1-100 and the democracy variable is ordinal scaled from 1-7. Can I make an interaction term between press freedom and democracy?

Scortchi - Reinstate Monica
  • 27,560
  • 8
  • 81
  • 248
daja
  • 377
  • 1
  • 5
  • 12
  • From your description, I'm guessing you mean that corruption is your *dependent* variable, and I'm guessing that it is ordinal as well at press freedom & democracy. Is that right? – gung - Reinstate Monica May 04 '14 at 21:21
  • yes, I meant corruption is the dependent variable. Some claim the corruption index is ordinal but many treat it as continuous. The same holds for press freedom. But the democracy index ranges from 1-7, and I have not seen anybody used it in an interaction term? – daja May 05 '14 at 06:47

1 Answers1

4

Yes you can. If $x_1$ is a continuous predictor modelled with a single linear term, & $z_1$, $z_2$ are dummies for a 3-level categorical predictor then the model without interaction for the response $Y$ is

$$\operatorname{E} Y = \alpha + \beta_1 x_1 + \gamma_1 z_1 + \gamma_2 z_2$$

For the 1st level of the categorical predictor $z_1=z_2=0$, &

$$\operatorname{E} Y = \alpha + \beta_1 x_1$$

For the 2nd level $z_1=1$ & $z_2=0$, &

$$\operatorname{E} Y = (\alpha + \gamma_1) + \beta_1 x_1$$

For the 3rd level $z_1=0$ & $z_2=1$, &

$$\operatorname{E} Y = (\alpha + \gamma_2) + \beta_1 x_1$$

So at each level of the categorical predictor the intercepts are different, but the slopes for $x_1$ are the same. If you include interaction terms the model is

$$\operatorname{E} Y = \alpha + \beta_1 x_1 + \gamma_1 z_1 + \gamma_2 z_2 + \delta_1 x_1 z_1 + \delta_2 x_1 z_2$$

For the 1st level of the categorical predictor $z_1=z_2=0$, &

$$\operatorname{E} Y = \alpha + \beta_1 x_1 $$

For the 2nd level $z_1=1$ & $z_2=0$, &

$$\operatorname{E} Y = (\alpha + \gamma_1) + (\beta_1 + \delta_1) x_1$$

For the 3rd level $z_1=0$ & $z_2=1$, &

$$\operatorname{E} Y = (\alpha + \gamma_2) + (\beta_1 + \delta_2) x_1$$

So at each level of the categorical predictor the intercepts & the slopes for $x_1$ are different.

Scortchi - Reinstate Monica
  • 27,560
  • 8
  • 81
  • 248
  • I am not sure if I understand it. If I have a scale of 1-7 I should have 6 interactions? I think that they in the literature only use one interaction? – daja May 14 '14 at 14:28
  • @daja: Yes, typically there'd be six coefficients for the interaction of a seven-level categorical predictor with a linear continuous predictor - it would be unusual to want to allow only certain levels to have slopes for the effect of the continuous predictor different from the reference level. – Scortchi - Reinstate Monica May 14 '14 at 14:51
  • You could, if you wanted, treat the ordinal predictor as continuous for the interaction, and use just one degree of freedom for that, though still using 6 for its main effects - the usual caveats about treating ordinal predictors as continuous apply. (If you did that it would perhaps be easier to make sense of the model if you used an orthogonal polynomial coding for the main effects.) – Scortchi - Reinstate Monica May 14 '14 at 15:42
  • thanks, I think it makes sense, then i would have the following regression: Y= a + x1 + z1 + z2 + z3 + z4 + z5 + z6+ x1z1 + x1z2 + x1z3 + x1z4 + x1z5 + x1z6? The problem is that my sample size is small and I also need to include other varibales. How would I be able to interpret the outputs? – daja May 14 '14 at 16:16
  • Yes, except there'd be a coefficient in front of each term after $a$ (& of course a term for error). You then have to consider whether you've enough data to fit a model of this size - how big is your sample size, & how many degrees of freedom do you need for other variables? – Scortchi - Reinstate Monica May 14 '14 at 16:21
  • My sample size is panel data of 144 observations through 3 years. I think I will include additional 5 control variables. I want to test whether an increase in press freedom is associated with a decrease in corruption when democracy is present, but not when democracy is absent. I seems like you know a lot about it, so I was thniking what happens if I use a dummy for democracy and interacts it with press freedom. Then I dont use that many degrees of freedom. What if the main effect (press freedom) is insignificant when interaction term is added to the regression? – daja May 14 '14 at 16:30
  • You mean a single dummy variable for democracy? - All right if theory suggests it's an either/or thing with respect to press freedom, but otherwise you can spare degrees of freedom by treating it as a continuous variable with a linear, perhaps quadratic, effect with a linear interaction: 13 df on just two predictors sounds rather a lot for just 140 observations. And don't try to interpret main effects separately when you have interactions - look at the whole picture. – Scortchi - Reinstate Monica May 14 '14 at 17:16
  • Yes, I mean a single dummy for democracy!But sometimes the main effect of press freedom is insignificant while the interaction term is always significant. Why is this, and what can I say about this? Thanks a lot for your answers. I cant find any proper articles about this topic. – daja May 15 '14 at 08:41
  • See [here](http://stats.stackexchange.com/questions/85940/). The main-effect coefficient for a predictor is just the slope of the response vs that predictor when all the interaction terms it's involved in are zero, which occurs when the other predictors involved in the interactions are zero (i.e. the reference level for categorical predictors). So it's rarely of especial interest. And to be clear, it'd usually be a bad idea to throw away information about the degree of democracy by dichotomizing the variable. – Scortchi - Reinstate Monica May 16 '14 at 14:03