Announcement

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

  • Marginal effects for interaction after Mlogit

    Dear all,

    I'm new in this forum and also pretty new to Stata, so I don't know if my question is actually quite easy or maybe stupid, but since I've been stuck with this problem for ages, I hope someone can help me:

    I have a panel dataset and since my dependent variable is categorical (with three different outcomes, whereas 0 is the base), I'm running a multinomial logit model (mlogit).
    This model includes two independent variables and also an interaction between both of the independet variables and a third variable.

    Now I read that “an explanatory variable’s marginal effect does not equal the variable’s model coefficient”. Therefore I wanted to create average marginal effects for the result of the multinomial logit model.
    So I used the following commands:

    margins, dydx(*) predict(outcome(1))
    margins, dydx(*) predict(outcome(2))

    This worked well for the "direct" effects of the variables, but not for the interaction.

    Is there a possibility, to show also the marginal effects of the two interactions?

    Thanks in advance and kind regards.




  • #2
    Is there a possibility, to show also the marginal effects of the two interactions?
    No, there isn't. The reason that Stata does not provide marginal effects for interaction terms is because, mathematically, there is no such thing.

    There are two ways to understand this. At the most abstract variable, a marginal effect is, as is suggested by the dydx() notation Stata uses, a first-order partial derivative of the outcome with respect to the explanatory variable. But interaction terms involve two variables, so the closest analogous thing would be a mixed second-order partial derivative. More concretely, an attempt to overlook that and just treat the interaction as if it were a separate independent variable would fail in two ways. First, it isn't independent. There is no way u#v can change while both u and v are held fixed--but this is what we require for calculating a marginal effect. Second, it isn't clear how you would define it anyway: u#v could change by 1, in many ways. Say we started from u = v = u*v = 0. If u changed to 2 and v changed to 0.5, that would b a unit change in u#v. But it would also be a unit change in u#v if u changed by 0.25 and v by 4, or if both u and v changed by 1. Yet all of these changes, which correspond to the same unit change in u#v, will in almost all regression models correspond to different changes in the outcome variable of the model--and there is no principled way to pick which one is the one.

    So for these reasons, the whole concept of the marginal effect of an interaction term is an illusion. Variables have marginal effects; interactions do not.
    Last edited by Clyde Schechter; 05 Jan 2022, 19:32.

    Comment


    • #3
      Thank you very much for your quick reply and help.

      It helped me a lot!

      Comment


      • #4
        Clyde Schechter
        I was reading a document from Stata Journal (link below) about how to interpret interaction in terms of marginal effects in nonlinear models.
        But reading your comment here I got a little confused.
        If concept of the marginal effect of an interaction term is an illusion, I shoudn't use this article as a support material for this kind of question, should I?

        https://journals.sagepub.com/doi/pdf...867X1001000211
        Last edited by Nayara Gomes; 30 Jan 2022, 14:07.

        Comment


        • #5
          You are misunderstanding the article or my response. If you re-read the article you attached carefully, you will see that it makes no mention at all of any marginal effect of the interaction term. The article is about interpreting marginal effects of variables when they appear in a model that includes them in an interaction term. There is no such thing as the marginal effect of the interaction term itself. Nor can we speak of the marginal effect of a single variable that is part of an interaction term. But those constituent variables do have marginal effects (emphasis on the plural here), which depend on the values of the other variables in the interaction.

          In the example shown in the article you attached, the author reviews marginal effects of black race conditional on the value of collgrad, and vice versa. Nowhere does the article mention a marginal effect of the black#collgrad term itself--because there is no such thing. There is no inconsistency between that approach and mine.

          Comment


          • #6
            Now I think I understood your point. Thanks a lot for clarifying this.
            Maybe when I saw the term "black#collgrade" at the second table of the article I had the impression that it refered to the marginal effect of the term itself.

            Comment

            Working...
            X