[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

From |
Maarten buis <maartenbuis@yahoo.co.uk> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: Marginal effects |

Date |
Sat, 22 Mar 2008 09:00:03 +0000 (GMT) |

--- José C. <jcreu@bol.com.br> wrote: > I am estimating a regression that has no-lineal (or product of > variables) variables in their dependent terms - for example: > > regress y x xz > > The program Stata doesn't allow logical operators in the command > regress (or other equation terms as probit) and for that it is > previously necessary to define the variable (for example: gen w = > xz). However, if the interest is to calculate marginal effects or > elasticities (using mfx or margeff or dprobit) - that procedure > invalidates the results because the terms no lineal they are not > considered (for example: dy/dx = 1 + z and no 1). > > Which the simplest way to solve that problem? I am reading between the lines of your question and I am assuming you want to use -probit-, and that one of the variables you are multiplying is a dummy (has only two values). You used the interaction term to estimate different effects of a variable (for example mpg) for different groups (for example foreign and domestic cars) and you are interested in the marginal effect of mpg: The easiest way to do that is to create two interaction terms mpgXforeign and mpgXdomestic, and leave the main effect of mpg out: *----------- begin example ----------- sysuse auto, clear recode rep78 1/3=0 2/4=1 gen domestic = !foreign gen mpgXfor = mpg*foreign gen mpgXdom = mpg*domestic logit rep78 mpgXfor mpgXdom mfx *---------- end example --------------- (For more on how to use examples I sent to the Statalist, see http://home.fsw.vu.nl/m.buis/stata/exampleFAQ.html ) The marginal effect of mpgXfor is the marginal effect of mpg for foreing cars, and the marginal effect of mpgXdom is the marginal effect of mpg for domestic cars Notice that the difference in effects has no causal interpretation due to problems discussed here: http://www.nd.edu/~rwilliam/oglm/index.html Hope this helps, Maarten ----------------------------------------- Maarten L. Buis Department of Social Research Methodology Vrije Universiteit Amsterdam Boelelaan 1081 1081 HV Amsterdam The Netherlands visiting address: Buitenveldertselaan 3 (Metropolitan), room Z434 +31 20 5986715 http://home.fsw.vu.nl/m.buis/ ----------------------------------------- ___________________________________________________________ Rise to the challenge for Sport Relief with Yahoo! For Good http://uk.promotions.yahoo.com/forgood/ * * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**References**:**st: Marginal effects***From:*José C. <jcreu@bol.com.br>

- Prev by Date:
**Re: st: Marginal effects** - Next by Date:
**st: Marginal effects** - Previous by thread:
**Re: st: Marginal effects** - Next by thread:
**st: Marginal effects** - Index(es):

© Copyright 1996–2016 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index |