Announcement

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

  • Export the marginal effects of Mixed Logit estimation with each column focusing on an outcome

    Hi, I am trying to estimate a mixed logit model and export the marginal effects of variables afterwards. I would like to make the exported table have the outcomes in each column and the variables in each row. When I tried the codes below (just for example, not my data), the exported table instead has the variables in each column and the outcomes in each row. I know I can estimate the model several times and for each time of estimating, I compute the marginal effect for an outcome and store it and export the marginal effects for each outcome. However, the estimation with my data takes hours because the random effects, it will cost lots of time to use the aforementioned method. Thanks a lot for any advice!

    Example codes that give the table with the variables in each column:

    set more off
    webuse inschoice, clear
    cmmixlogit choice premium, random(deductible)
    estpost margins, dydx(*)
    esttab, unstack

  • #2
    I think an alternative way is to store the estimation results and recall it and estimate the marginal effects for each outcome. This is bit faster, but still costs lots of time.

    Comment

    Working...
    X