Statalist


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

Re: st: Analyze a subpopulation of survey data in Stata 10.1


From   "Michael I. Lichter" <MLichter@Buffalo.EDU>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Analyze a subpopulation of survey data in Stata 10.1
Date   Tue, 23 Jun 2009 22:45:58 -0400

Figen,

Make sure that dmrc_dum is missing if dentistrc or gender are missing.
That will generally do the right thing. It might not do the right thing
with poststratification (and I'm too lazy right now to check); if it
doesn't, try instead:

svy, subpop(dmrc_dum): proportion dentistrc ///
	if !missing(dmrc_dum, dentistrc, gender), over (gender)

If that doesn't solve your problem, please be more specific about -svyset- command, your total N (3827?); the N of cases jointly non-missing on diabetes, dentist and gender (3783?), and the number of men (517?) and women.

Michael

Karadogan, Figen wrote:
Hello,
We are using the subpopulation command while analyzing survey data. We are interested in the proportion of diabetics (dmrc_dum) who go to the dentist (dentistrc) by gender (gender). It is our understanding that the number of observations = total number of observations with non-missing data.
For our data, we have the following:
Gender x Diabetes x Dentist: N = 3783
However, the STATA output is as follows:

svy, subpop(dmrc_dum): proportion dentistrc, over (gender)

Summary of Observations
Number of strata:       1
Number of PSUs: 3827
N. of poststrata:       108

Number of obs:  3827
Population size:        365510
Subpop. No. obs:        517
Subpop size:    44819.8

Design df:      3826


Do you have any suggestions as to why the number of observations differs?
Thank you very much for your assistance.

Figen Karadogan


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


--
Michael I. Lichter, Ph.D. <mlichter@buffalo.edu>
Research Assistant Professor & NRSA Fellow
UB Department of Family Medicine / Primary Care Research Institute
UB Clinical Center, 462 Grider Street, Buffalo, NY 14215
Office: CC 126 / Phone: 716-898-4751 / FAX: 716-898-3536
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index