This example is taken from Levy and Lemeshow’s Sampling of Populations.
page 109 repeated systematic sampling
This example uses the
wloss2
data set.
NOTE: The PSUs are listed on the cluster statement in SAS. Also, the coloring in the (enhanced) program editor window does not work properly with the cluster statement, so don’t think that you have specified the statement incorrectly just because the keyword "cluster" does not turn blue.
proc surveymeans data = wloss2 n = 54 sum std mean; weight wt1; cluster cluster; var xi; run;The SURVEYMEANS Procedure Data Summary Number of Clusters 6 Number of Observations 18 Sum of Weights 162 Statistics Std Error Variable Mean of Mean Sum Std Dev ------------------------------------------------------------------------ XI 4.500000 0.530548 729.000000 85.948822 ------------------------------------------------------------------------