Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: RE: RE: Svytab subgroup analysis with more than two subgroups


From   "L Allen" <[email protected]>
To   [email protected]
Subject   Re: st: RE: RE: Svytab subgroup analysis with more than two subgroups
Date   Wed, 23 Jul 2003 13:14:44 +0000

That is what I want. However, the problem I ran into when constructing the subgroup, both previously and as suggested below, is that the 3 groups not in the subgroup are still levels in the groupvar and generate a 0 count in half the cells in the table. With zeros in the marginals, a chi-square cannot be computed.

Richard Clerkin
Ph.D. Student
Indiana Nonprofit Project
Indiana University-Bloomington



From: Lee Sieswerda <[email protected]>
Reply-To: [email protected]
To: "'[email protected]'" <[email protected]>
Subject: st: RE: RE: Svytab subgroup analysis with more than two subgroups
Date: Mon, 21 Jul 2003 09:31:24 -0400

I'm not sure that I completely understand your problem either, but something
like this:

tab groupvar, gen(group)
gen dichot = (group1==1 | group2==1 | group3==1)
svytab groupvar catvar, subpop(dichot)

would give you a chi-square test for the association between groupvar and
catvar for three out of your six groups. Is that not what you are looking
for?

Lee Sieswerda, Epidemiologist
Thunder Bay District Health Unit
[email protected]


-----Original Message-----
From: L Allen [mailto:[email protected]]
Sent: Monday, July 14, 2003 1:56 PM
To: [email protected]
Subject: st: Svytab subgroup analysis with more than two subgroups


Dear Statalist,

We have survey data with 39 strata. We have categorized the respondents
into 6 groups. This grouping was not used in the sampling design (it is not
one of our stratifying variables). We want to do a svytab on 3 of the 6
groups against responses to a categorical variable; however, the survey
manual warns us not to us an if restriction to select these three groups
because it will not produce correct statistics and variance estimates.
However, the subpop() option does not appear to meet our needs either
because we want to test the association among these three groups. Any
suggestions on how to proceed would be appreciated.

Richard Clerkin
Ph.D. Student
Indiana Nonprofit Project
Indiana University-Bloomington

_________________________________________________________________
The new MSN 8: smart spam protection and 2 months FREE*
http://join.msn.com/?page=features/junkmail

*
* 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/
*
* 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/
*
* 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/
_________________________________________________________________
MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus

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