Announcement

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

  • marginal effect of conditional logit model

    I need to calculate marginal effect after clogit. I know that I can use margins, (pu0) to calculate assuming fixed effect is 0. I know that for clogit, the intercepts are not estimated. However, I am very confused. Using the example of individuals choosing from alternative cars made by USA, Japan, or Europe.
    1) I wonder the fixed effects is for individuals or for alternatives. (I think it is individual, but not 100% sure)
    2) if margins calculates the unconditional pu0 using Pr(yit = 1)=exp(xitβ)/(1 + exp(xitβ)). How can we use margins, (pu0) to calculate margin for conditional logit using p= exp(x β)/sum(exp(x β))?
    ​3) I have an interaction term in my model a*b, where a is attribute of individual, b is attribute of alternative. I can manually calculate the probability using p= exp(x β)/sum(exp(x β)) when a=a1 and b=b1 as well as a=a1, b=b2. But since the probability I calculated does not involve intercepts, can I compare those two probabilities and calculate a difference?
    4) Can I plot interaction graph to show the interaction effect? I manually calculate the p= exp(x β)/sum(exp(x β)). But then realized the probability shown on y axis is not accurate, since intercept is not calculated.
    Thank you so much for your help!
    Last edited by Lei Zhang; 02 Dec 2014, 10:15.

  • #2
    Regarding your first two questions see help asclogit. asclogit implements McFadden's choice model (McFadden 1974), which given that you mention the "alternative cars" example seems to be what you want. After estimating a model using asclogit you can type estat mfx to calculate the marginal effects:
    Code:
    webuse choice
    asclogit choice dealer, case(id) alternatives(car) casevars(sex income)
    estat mfx
    Note that the intercepts in this model are alternative-specific constants. You are not controlling for individual fixed effects. The reason, I suspect, that people sometimes think that individual fixed effects are controlled for is that clogit can be used to estimate both the McFadden model and the fixed effects binary logit model (Chamberlain, 1980). The models are very closely related computationally and often referred to by the same name (conditional logit), but only the McFadden model is appropriate for modelling choices among multiple alternatives.

    It is usually better to use asclogit to estimate McFadden's choice model, even though this can also be done using clogit, since there is no post-estimation command after clogit to calculate the correct marginal effects for this model.

    Arne

    References

    Chamberlain, G. 1980. Analysis of covariance with qualitative data. Review of Economic Studies 47: 225-238.
    McFadden, D. L. 1974. Conditional logit analysis of qualitative choice behavior. In Frontiers in Econometrics, ed. P. Zarembka, 105-142. New York: Academic Press.

    Comment


    • #3
      Ame, thank you very much. I guess I have been misleading in my previous question. I have to use clogit instead of asclogit, since I have matched samples (some real observations and my hypothetical observations generated by me). I mentioned the individual and alternative car example because it is easier to understand. I read online that clogit is equivalent to logit with individual dummies. Is that correct? If so, then the missing intercepts will be individual fixed effects, right?

      Comment


      • #4
        Yes, in that case it sounds like you need to use clogit. Including individual dummies in a logit model is not equivalent, as in the fixed effects logit estimator implemented by clogit the individual fixed effects are conditioned out of the likelihood function (see e.g. http://hsphsun3.harvard.edu/cgi-bin/...ticle-934.html). Since the fixed effects are not actually estimated you cannot calculate marginal effects unless you are willing to assume that the fixed effects are zero.

        Comment


        • #5
          Ame, thank you very much for your quick reply. They are very helpful. Stata calculates pc1 using p= exp(x β)/sum(exp(x β)). The sum of pc1 across alternatives for any individual is 1. I know that the probability is not accurate since intercepts are not estimated. However, I wonder, compared to calculate marginal effect assuming there is no fixed effects, whether it will be better if I calculate the probability changes by manually calculating pc1 using p= exp(x β)/sum(exp(x β)) for a*b for some combination of a and b. Then I wonder if I can claim that the interaction suggests that probability change is different when we compare 1) when a= a1 , prob changes caused by an increase from b1 to b2 and 2) when a=a2, the prob changes caused by an increase from b1 to b2. Also, Can I draw a interaction graph using this method.

          Comment


          • #6
            I’m afraid I won’t be able to help you more. I’m not completely sure what you are proposing, but as I said above there really is no way to calculate marginal effects following a fixed-effects logit regression unless you are willing to make strong (and most likely unrealistic) assumptions. You might get some other ideas for how to interpret the results from reading the relevant literature in your discipline. In my field (Economics) coefficient ratios can sometimes be given a useful interpretation and in other disciplines odds ratios are commonly used (see e.g. the discussion here http://www.statalist.org/forums/foru...mpute-properly).

            Arne

            PS Note that posters are politely asked to use their full names on Statalist

            Comment


            • #7
              Thank you again. Arne, I sincerely appreciate your help. Also, thank you for pointing out the name issue. I did not pay attention earlier and just noticed after you pointed that out. Thanks! I will correct that.
              Lei

              Comment


              • #8
                Using suggestions of Dr. Maarten Buis, if the odds ratio of interaction term x1*x2 is 1.47 and both x1 and x2 are continuous variables, can my interpretation be "on average, the effect of x1 is 47% bigger with the increase of 1 unit in x2".

                Comment

                Working...
                X