Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Question regarding interpretation of interaction effect in logistic regression

    Hello,

    I was wondering if it would be possible to get some feedback on my interpretation of interaction effects in my logistic regression model? I have done a lot of research but have found it hard to find a clear answer as to how interaction effects should be interpreted.

    For context, my model aims to test whether exposure to online political media has an effect on individual-level voter volatility during an election campaign - that is, the likelihood that a voter switches their party preference between the election campaign and the election itself. My hypothesis is tested using panel data with a pre- and post-election wave.

    - The dependent variable (totalvolatility) is a binary variable, with 1 indicating the voter switched their party preference from between the pre- and post-election wave, and 0 indicating the voter's preference did not change.
    - The main independent variable (onlinemed) is also a binary variable, with 1/0 indicating high/low exposure to online political news.
    - The moderating variable (highknow) is coded as 1/0 indicating a respondent with a high/low level of political knowledge.

    One of my hypotheses states that the effect of onlinemed on totalvolatility will be moderated by highknow, such that only those with high levels of political knowledge will become less volatile in response to exposure to online political media. I have included the results of the regression models along with marginal effects outputs below.


    Code:
     logit totalvolatility i.onlinemed##i.highknow socmedqw4 age_i female income_i partyclose_binary leftright_i politicalmood2 networkhet12_i nptvnews [pw = w5_weightp]
    Code:
     -----------------------------------------------------------------------------------------------
                                  |               Robust
                  totalvolatility |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
    ------------------------------+----------------------------------------------------------------
                        onlinemed |
                   high exposure  |   .0790074   .2651313     0.30   0.766    -.4406405    .5986553
                                  |
                         highknow |
                  high knowledge  |   .3470785   .2892094     1.20   0.230    -.2197616    .9139185
                                  |
               onlinemed#highknow |
    high exposure#high knowledge  |  -1.198582   .4915158    -2.44   0.015    -2.161935   -.2352283
                                  |
                        socmedqw4 |   .0293968   .0625581     0.47   0.638    -.0932147    .1520084
                            age_i |  -.0178674   .0075429    -2.37   0.018    -.0326512   -.0030836
                           female |  -.4590877   .2108023    -2.18   0.029    -.8722527   -.0459227
                         income_i |   .0053713   .0166909     0.32   0.748    -.0273422    .0380848
                partyclose_binary |  -1.478461   .5034873    -2.94   0.003    -2.465278   -.4916444
                      leftright_i |  -.1820593   .0411686    -4.42   0.000    -.2627483   -.1013703
                   politicalmood2 |   .0233802   .0074988     3.12   0.002     .0086827    .0380777
                   networkhet12_i |   .0351173   .0390751     0.90   0.369    -.0414686    .1117032
                         nptvnews |   .0649076   .0397017     1.63   0.102    -.0129063    .1427214
                            _cons |    -1.4158   .6960173    -2.03   0.042    -2.779969   -.0516316
    -----------------------------------------------------------------------------------------------

    Code:
      margins, dydx(onlinemed) at(highknow=(0(1)1)) atmeans vsquish
    
    Conditional marginal effects                    Number of obs     =      1,540
    Model VCE    : Robust
    
    Expression   : Pr(totalvolatility), predict()
    dy/dx w.r.t. : 1.onlinemed
    1._at        : 0.onlinemed     =    .6599114 (mean)
                   1.onlinemed     =    .3400886 (mean)
                   highknow        =           0
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    2._at        : 0.onlinemed     =    .6599114 (mean)
                   1.onlinemed     =    .3400886 (mean)
                   highknow        =           1
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    
    ------------------------------------------------------------------------------
                 |            Delta-method
                 |      dy/dx   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    0.onlinemed  |  (base outcome)
    -------------+----------------------------------------------------------------
    1.onlinemed  |
             _at |
              1  |     .00811   .0274501     0.30   0.768    -.0456913    .0619112
              2  |  -.0964874   .0367689    -2.62   0.009     -.168553   -.0244218
    ------------------------------------------------------------------------------
    Note: dy/dx for factor levels is the discrete change from the base level.
    Code:
     Adjusted predictions                            Number of obs     =      1,540
    Model VCE    : Robust
    
    Expression   : Pr(totalvolatility), predict()
    1._at        : onlinemed       =           0
                   highknow        =           0
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    2._at        : onlinemed       =           0
                   highknow        =           1
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    3._at        : onlinemed       =           1
                   highknow        =           0
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    4._at        : onlinemed       =           1
                   highknow        =           1
                   socmedqw4       =    4.131148 (mean)
                   age_i           =    46.30343 (mean)
                   female          =    .4765431 (mean)
                   income_i        =    13.44298 (mean)
                   partyclose~y    =    .1003665 (mean)
                   leftright_i     =    5.204464 (mean)
                   politicalm~2    =    31.69004 (mean)
                   networkhet~i    =    4.545937 (mean)
                   nptvnews        =    6.076544 (mean)
    
    ------------------------------------------------------------------------------
                 |            Delta-method
                 |     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
    -------------+----------------------------------------------------------------
             _at |
              1  |   .1121286   .0157127     7.14   0.000     .0813323    .1429249
              2  |   .1516006   .0323344     4.69   0.000     .0882264    .2149748
              3  |   .1202385   .0220698     5.45   0.000     .0769824    .1634946
              4  |   .0551132   .0175233     3.15   0.002     .0207682    .0894581
    ------------------------------------------------------------------------------
    As you can see, the inclusion of the interaction between onlinemed and highknow in the logistic regression model indicates a significant interaction at p = 0.015. However, the marginal effects output in table 2 indicate that the interaction is only significant for those with high levels of knowledge (p = 0.009), and not significant for those with low levels of knowledge (p = 0.768) (which is in line with my hypothesis).

    Overall, my question is the following: I am correct in saying that "there is a significant interaction between onlinemed and highknow, such that high exposure to online media reduces the likelihood of an individual being volatile compared to an individual with low exposure to online media (by 9.64874% on average), but this effect is only significant for individuals with high levels of political knowledge (p = 0.009). For those with low levels of knowledge, the effect of moving from low to high online media consumption on the probability of volatility is positive (+0.811%), but insignificant (p = 0.768)?"

    Thanks in advance.

  • #2
    I am not very good at this, but I think you are misinterpreting the first set of margins. The margin in the first is the DYDX on onlinemed so it doesn't really tell you about the significance of the interacting variable, knowledge. By the way, if you have continuous data, it is usually a mistake to make it into a dummy.

    For k=0, moving from 0 on online to 1 increases predicted prob from .11 to .12. This is probably not a statistically significant change (you can use contrasts to check) which is consistent with your DY DX above. For K equals one, moving from on equals 0 to on equals one reduces the predicted probability from .15 to .055. So again consistent with your DY DX, Don has an influence only where K equals one.

    Comment


    • #3
      Hi Phil,

      Thanks very much for your help. The -0.0964874 coefficient in the dydx table is the same as the difference in margins between _at 2 and _at 4 in the second margins table, and the 0.00811 corresponds to the difference between _at 1 and _at 3. That's why I interpreted the second margins table as showing the predicted probability of the binary dependent variable being 1 at different levels of the interaction term, with the dydx margins table just showing the difference between these probabilities (and their significance). I'll have a look at contrasts and see if that provides any more info. It doesn't seem as if it should be that complicated but it's been hard to find a clear answer online.

      Comment

      Working...
      X