Statalist The Stata Listserver


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

RE: st: RE: svy probit/logit iv


From   Richard Williams <[email protected]>
To   [email protected]
Subject   RE: st: RE: svy probit/logit iv
Date   Wed, 12 Jul 2006 08:44:14 -0500

At 08:05 AM 7/12/2006, Richard Williams wrote:
When you say it doesn't work, what exactly is the error you are getting? The following works fine for me (the nhanes2f data are already svyset with pweight = finalwgt):

webuse nhanes2f
ivprobit diabetes female (heartatk = rural) [iw=finalwgt]
est store m1
suest m1, svy
Incidentally, the reason I happen to know this is because I asked Stata Tech support a while back why svy: did not work with -hetprob-. Here was the response:
---------------------------------

> * Why doesn't hetprob work with svy:? Is it because it would be
> statistically incorrect to do so, or is it just a programming
> problem?

There is no statistical reason; we just haven't gotten around to adding -svy-
support in -hetprob-.

This is true for most of the standard Stata estimation commands that
are not commonly mentioned in the survey literature. As you could
imagine, even though getting -svy- support for an -ml- based
estimation command usually requires little extra programming, the
documentation implications are quite large. In time, we hope to have
all of these commands support the -svy- prefix.

That being said, there is a way to get survey estimation results out of
standard estimation commands that do not currently (but could) support the
-svy- prefix. Look into the -svy- option of -suest-. For example,

svyset psu [pw=pwgt]
hetprob y x1 x2 [iw=pwgt], het(z1 z2)
est store hetprob
suest hetprob, svy

---------------------------------
Incidentally, with slight modification, this procedure seems to work in Stata 8.2 as well. You just have to add the score option to your estimation command, e.g.

webuse nhanes2f
hetprob diabetes female [iw=finalwgt], het(black) score(x*)
est store m1
suest m1, svy

In both Stata 8.2 and 9.2, I'm guessing that the general rule is that the estimation command needs to support both iweights and the score option in order to use suest this way. It would not surprise me if many user-written commands do not support these, even if they potentially could.

*
* 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/




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