UCLA Academic Technology Services HomeServicesClassesContactJobs
Help the Stat Consulting Group by giving a gift             
Loading

Stata FAQ
How do I analyze survey data with a systematic sample design?

The examples below use Stata 8.  If you are using Stata version 9, please see this page.

This example is taken from Lehtonen and Pahkinen's Practical Methods for Design and Analysis of Complex Surveys.

page 46 Table 2.6  Estimates from a systematic sample drawn from the Province'91 population using implicit stratification.
NOTE:  The standard error of the total is different from that shown in the text (the text shows 11802).  However, we get the 13627 in each of the statistical packages in which we have tried to recreate this example.
input id str clu wt ue91 lab91
1 1 1 4 4123 33786
2 1 5 4 721 4930
3 2 9 4 194 2069
4 2 13 4 129 927
5 2 17 4 239 2144
6 2 21 4 61 573
7 2 25 4 262 1737
8 2 29 4 166 1615
end
gen fpc = 32
svyset [pweight=wt], psu(clu) strata(str) fpc(fpc)

svytotal ue91

Survey total estimation

pweight:  wt                                      Number of obs    =         8
Strata:   str                                     Number of strata =         2
PSU:      clu                                     Number of PSUs   =         8
FPC:      fpc                                     Population size  =        32

------------------------------------------------------------------------------
   Total |   Estimate    Std. Err.   [95% Conf. Interval]        Deff
---------+--------------------------------------------------------------------
    ue91 |      23580    13191.99   -8699.644    55859.64    .9479457
------------------------------------------------------------------------------
Finite population correction (FPC) assumes simple random sampling without 
replacement of PSUs within each stratum with no subsampling within PSUs.
Weights must represent population totals for deff to be correct when
using an FPC.  Note: deft is invariant to the scale of weights.

svyratio ue91 lab91

Survey ratio estimation

pweight:  wt                                      Number of obs    =         8
Strata:   str                                     Number of strata =         2
PSU:      clu                                     Number of PSUs   =         8
FPC:      fpc                                     Population size  =        32

------------------------------------------------------------------------------
      Ratio       |   Estimate    Std. Err.   [95% Conf. Interval]        Deff
------------------+-----------------------------------------------------------
    ue91/lab91    |   .1233754    .0036606    .1144183    .1323325    1.560909
------------------------------------------------------------------------------
Finite population correction (FPC) assumes simple random sampling without 
replacement of PSUs within each stratum with no subsampling within PSUs.
Weights must represent population totals for deff to be correct when
using an FPC.  Note: deft is invariant to the scale of weights.

How to cite this page

Report an error on this page or leave a comment

UCLA Researchers are invited to our Statistical Consulting Services
We recommend others to our list of Other Resources for Statistical Computing Help
These pages are Copyrighted (c) by UCLA Academic Technology Services


The content of this web site should not be construed as an endorsement of any particular web site, book, or software product by the University of California.