++++++++++++++++++++++++++++
Date: Thu, 19 Oct 2006 09:07:29 -0700 (PDT)
From: Anna Gueorguieva <[email protected]>
Subject: st: Stata 9 --> sepov is not recongnizing the svyset
variables. Any ideas?
Dear Statalist Brainiacs :),
Switching to stata 9 problem: I need your help to figure out what is
going wrong now that I am using stata 9 (just switched two weeks ago,
yay!!!) with my old code.
Basically, the command sepov which estimates poverty indices taking
into account survey design effects does not preserve the strata and
the psu after svyset (and in 8 it was no problem).
Here is what I get:
*FIRST stata is reading correctly my variables for the survey set up
svyset [pw=repweight_s], strata(strata_unique) psu(psu) fpc(fpc)|| _n
pweight: repweight_s
VCE: linearized
Strata 1: strata_unique
SU 1: psu
FPC 1: fpc
Strata 2: <one>
SU 2: <observations>
FPC 2: <zero>
.
*WHEN I CALL THE COMMAND sepov, however, it does not show strata
.
. sepov real_totc_per_ae [pw=repweight_s], p(povline_m) subpop(wave2)
Poverty measures for the variable real_totc_per_ae: (unlabeled)
Survey mean estimation
pweight: repweight_s Number of obs =
4785
Strata: <one> Number of strata =
1
PSU: <observations> Number of PSUs =
4785
Subpop.: ==1 Population size =
3639689.6
-
----------------------------------------------------------------------
--------
Mean | Estimate Std. Err. [95% Conf. Interval] Deff
-
---------+------------------------------------------------------------
--------
p0 | .4513918 .0154961 .4210124 .4817712 2.318254
p1 | .1225897 .0053558 .1120899 .1330895 2.152049
p2 | .0468943 .0026791 .0416422 .0521465 1.932348
-
----------------------------------------------------------------------
--------
Has anybody dealt with this yet? How do I fix this?
Thank you in advance for your time and support!
Best,
Anna
++++++++++++++++++++++++++++++++++++++++++++++
Nick Cox and Jeff Pitblado provided useful code and work arounds.
A third solution is not to use this program at all -- you can
calculate the indices and their standard errors in a couple of lines.
As Nick pointed out, these poverty measures are means, so all one
needs do is generate some appropriate variables first, and then use
-svy- and -mean-, having first -svyset- your data.
For examples, see:
Jenkins, S. P. (2006). 'Estimation and interpretation of measures of
inequality, poverty, and social welfare using Stata'. Presentation at
North American Stata Users' Group Meeting 2006, Boston MA.
http://econpapers.repec.org/paper/bocasug06/16.htm
Stephen
-------------------------------------------------------------
Professor Stephen P. Jenkins <[email protected]>
Institute for Social and Economic Research
University of Essex, Colchester CO4 3SQ, U.K.
Tel: +44 1206 873374. Fax: +44 1206 873151.
http://www.iser.essex.ac.uk
Survival Analysis using Stata:
http://www.iser.essex.ac.uk/teaching/degree/stephenj/ec968/
Downloadable papers and software: http://ideas.repec.org/e/pje7.html
*
* 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/