Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: margeff/margins discrepancy


From   "Joanne W. Hsu" <[email protected]>
To   [email protected]
Subject   st: margeff/margins discrepancy
Date   Sun, 25 Apr 2010 09:57:22 -0400

Here is a replicable example:

sysuse nlsw88.dta, clear
probit married wage if age==45
margeff
margins, dydx(wage)

Here, margeff produces a standard error of .0149933 (z statistic of -0.48) whereas margins reports 0.0150751 (z statistic -0.47). Margeff reports the same coefficients and standard errors regardless of whether version 9: probit is run or just probit.

Now, if one runs the following after the probit:

keep if e(sample)==1
margeff

margeff now produces the same output as margins did.

Note that while these standard error differences are relatively small, I'm getting a similar discrepancy that is much larger in my own data (standard errors on an order of 3 times larger with margins than margeff).

Any ideas on what's going on here?

Date: Sat, 24 Apr 2010 18:40:44 -0500
From: Richard Williams<[email protected]>
Subject: Re: st: margeff/margins discrepancy

A replicable example, or at least seeing your code, could help.  In
particular, you want to be sure that the margins command really is
doing the same thing as margeff.

I have found that in some instances using version control on the
estimation command is helpful with margeff, e.g.

version 9: probit y x
margeff

This is because margeff was written for Stata 9, and some of the
ereturned results from estimation commands changed in Stata 10 or 11.

If that doesn't solve it why don't you post your code, or better yet
a replicable example.


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index