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

Re: st: svy: proportion [version 9]

From   Steven Samuels <>
Subject   Re: st: svy: proportion [version 9]
Date   Tue, 17 Feb 2009 08:40:08 -0500


Keith, this is probably one for support. "gweight" is an option in the ado file which handles prefix commands like "svy:".

A few things for your colleague to do:
1. Update Stata 9 to the latest version.
2. Run -svydes- and check that the data look right
3. Run some other -svy- commands. -svy: mean- should give the same result as -svy: prop-.

On Feb 17, 2009, at 5:30 AM, Keith Dear (home) wrote:

I'm posting this question from a colleague, because I don't know the answer.

The gastro survey done in 2002 had weights attached and I used STATA 8
'svy' commands to do procedures which worked fine. However, the change
in version has meant there is a new syntax for invoking the svy
procedures and I can't get it to work. Would you be able to help with
this please?

I have run the svyset command which seems to go OK

svyset [pweight=newwt], strata(statenum) vce(linearized)

     pweight: newwt
         VCE: linearized
    Strata 1: statenum
        SU 1: <observations>
       FPC 1: <zero>

Then I try a procedure like 'proportions' and get the following error
message about 'option gweight not allowed'

svy: proportion respdefn
option gweight not allowed

Are you able to shed any light on this please? (also I am not sure what
gweight is compared to the pweight in the svyset command.)

Dr Keith Dear
Senior Fellow
National Centre for Epidemiology and Population Health
ANU College of Medicine, Biology and Environment
Building 62, cnr Mills and Eggleston Roads
Australian National University
Canberra ACT 0200 Australia
T: 02 6125 4865
F: 02 6125 0740
M: 0424 450 396

CRICOS provider #00120C

*   For searches and help try:

*   For searches and help try:

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