Corey Phelps --
Do you mean like this?
webuse grunfeld, clear
xtnbreg mva kstock inv, fe i(com)
mat li e(b)
predict xb if e(sample)
gen exp=exp(xb)
su exp, meanonly
mat mfx=r(mean)*e(b)
mat li mfx
On 3/5/07, Corey Phelps <[email protected]> wrote:
I am trying to calculate marginal effects using the "mfx compute" command
for a xtnbreg model. Because mfx computes marginal effects from the
post-estimated linear predictions, the default dydx calculation returns the
regresssion betas as marginal effects. However, I am interested in the
marginal effect (exp^BX)Bj, evaluated at the sample means of the covariates.
How do I go about obtaining this?
Corey Phelps
*
* 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/