This example is taken from Levy and Lemeshow’s Sampling of Populations.
page 285 two-stage cluster sampling: clusters sample with equal probability and all of the clusters have the same n and without replacement
data pt1; input center nurse m nbar w npatnts nrefrred; cards; 1 2 5 3 2.5 44 6 1 3 5 3 2.5 18 6 2 1 5 3 2.5 42 3 2 3 5 3 2.5 10 2 4 1 5 3 2.5 16 5 4 2 5 3 2.5 32 14 ; run; proc descript data = pt1 filetype = sas design = wor means totals; nest _one_ center; weight w; totcnt m nbar; var npatnts nrefrred; setenv colwidth = 13; setenv decwidth = 3; run;
Number of observations read : 6 Weighted count : 15 Denominator degrees of freedom : 2 Variance Estimation Method: Taylor Series (WOR) by: Variable, One. ------------------------------------------------------ | | | | Variable | | One | | | 1 | ------------------------------------------------------ | | | | | NPATNTS | Sample Size | 6.000 | | | Weighted Size | 15.000 | | | Total | 405.000 | | | SE Total | 53.245 | | | Mean | 27.000 | | | SE Mean | 3.550 | ------------------------------------------------------ | | | | | NREFRRED | Sample Size | 6.000 | | | Weighted Size | 15.000 | | | Total | 90.000 | | | SE Total | 21.679 | | | Mean | 6.000 | | | SE Mean | 1.445 | ------------------------------------------------------ proc ratio data = pt1 filetype = sas design =wor; nest _one_ center; weight w; totcnt m nbar; numer nrefrred; denom npatnts; setevn colwidth = 13; setenv decwidth = 3; run;
Number of observations read : 6 Weighted count : 15 Denominator degrees of freedom : 2 Variance Estimation Method: Taylor Series (WOR) by: Variable, One. ------------------------------------------------------ | | | | Variable | | One | | | 1 | ------------------------------------------------------ | | | | | NREFRRED/NPATN- | Sample Size | 6.000 | | TS | Weighted Size | 15.000 | | | Weighted X-Sum | 405.000 | | | Weighted Y-Sum | 90.000 | | | Ratio Est. | 0.222 | | | SE Ratio | 0.058 | ------------------------------------------------------
This example is taken from Lehtonen and Pahkinen’s Practical Methods for Design and Analysis of Complex Surveys.
page 88 Table 3.8 Estimates from a two-stage CLU sample (n = 8); the Province’91 population.
data page88; input id str clu wt ue91 lab91 fpc1 fpc2 smplrat; cards; 1 1 2 4 760 5919 8 4 .5 2 1 2 4 187 1448 8 4 .5 3 1 3 4 767 5823 8 4 .5 4 1 3 4 142 675 8 4 .5 5 1 4 4 94 831 8 4 .5 6 1 4 4 98 545 8 4 .5 7 1 7 4 262 1737 8 4 .5 8 1 7 4 219 1330 8 4 .5 ; run; proc descript data = page88 filetype = sas design = wor totals deft4; weight wt; nest _one_ clu; totcnt fpc1 fpc2; var ue91; run;
Number of observations read : 8 Weighted count : 32 Denominator degrees of freedom : 3
Variance Estimation Method: Taylor Series (WOR) by: Variable, One. ----------------------------------------------------- | | | | Variable | | One | | | 1 | ----------------------------------------------------- | | | | | UE91 | Sample Size | 8 | | | Weighted Size | 32.00 | | | Total | 10116.00 | | | SE Total | 2658.65 | | | Mean | 316.13 | | | SE Mean | 83.08 | | | DEFF Mean #4 | 0.69 | | | DEFF Total #4 | 0.69 | -----------------------------------------------------
proc ratio data = page88 filetype = sas design = wor deff; weight wt; nest _one_ clu; totcnt fpc1 fpc2; numer ue91; denom lab91; run;
Number of observations read : 8 Weighted count : 32 Denominator degrees of freedom : 3
Variance Estimation Method: Taylor Series (WOR) by: Variable, One. --------------------------------------------------- | | | | Variable | | One | | | 1 | --------------------------------------------------- | | | | | UE91/LAB91 | Sample Size | 8 | | | Weighted Size | 32.00 | | | Weighted X-Sum | 73232.00 | | | Weighted Y-Sum | 10116.00 | | | Ratio Est. | 0.14 | | | SE Ratio | 0.01 | | | DEFF Ratio #4 | 0.75 | ---------------------------------------------------
proc descript data = page88 filetype = sas design = wor ; weight wt; nest _one_ clu; totcnt fpc1 fpc2; var ue91; percentile / median; run;
Number of observations read : 8 Weighted count : 32 Denominator degrees of freedom : 3
Variance Estimation Method: Taylor Series (WOR) by: Variable, One, Percentiles. for: Variable = UE91. ----------------------------------------------------------------------------------- One Sample Weighted Lower 95% Upper 95% Percentiles Size Size Quantile Limit Limit ----------------------------------------------------------------------------------- 1 50.00 8 32.00 187.00 94.36 687.75 -----------------------------------------------------------------------------------
--------------------------------- One SE Percentiles Quantile --------------------------------- 1 50.00 93.23 ---------------------------------