ci.strat {asbio}R Documentation

Confidence intervals for stratified random samples.


A statistical estimate along with its associated confidence interval can be considered to be an inferential statement about the sampled population. However this statement will only be correct if the method of sampling is considered in the computations of standard errors. The function ci.strat provides appropriate computations given stratified random sampling.


ci.strat(data, strat, N.h, conf = 0.95, summarized = FALSE, use.t = FALSE, 
n.h = NULL, = NULL, var.h = NULL)



A vector of quantitative data. Required if summarized=FALSE.


A vector describing strata.


A vector describing the number of experimental units for each of the k strata.


Level of confidence; 1 - P(type I error).


Logical. Indicates whether summarized data are to be used.


Logical. Indicates whether t or z confidence intervals should be built.


A vector indicating the number of experimental units sampled in each of the k strata. Required if summarized=TRUE.

A vector containing the sample means for each of the k strata. Required if summarized=TRUE .


A vector containing the sample variances for each of the k strata. Required if summarized=TRUE.


the conventional formula for the sample standard error assumes simple random sampling. There are two other general types of sampling designs: stratified random sampling and cluster sampling. Since cluster sampling is generally used for surveys involving human demographics we will only describe corrections for stratified random sampling here. For more information on sample standard error adjustments for cluster sampling see Lohr (1999).

For a stratified random sampling design let N be the known total number of units in the defined population of interest, and assume that the population can be logically divided into k strata; N=N_1+N_2+N_3+…+N_k (i.e. we are assuming that we know both the total population size, and the population size of each stratum). We sample each of the k strata with n_h observations; h=1,2,…,k.

We estimate the variance in the hth stratum as:


where X_{hi} is the ith observation from the hth strata and \bar{X}_h is the hth sample mean. We estimate the true population total, T, with:


We estimate the population mean, μ, with:


An unbiased estimator for the standard error of \bar{X}_{str} is:


The standard error of \hat{T} is also of interest. Here is an unbiased estimator:


Note that these standard errors have both a finite population correction and adjustments for stratification built into them. Assuming that sample sizes within each stratum are large or that the sampling design has a large number of strata, a 100(1 - α)percent confidence interval for μ and T can be constructed using:

\bar{X}_{str}\pm z_{1-α/2}S_{\bar{X}_{str}}

\hat{T}\pm z_{1-α/2}S_{\hat{T}}

In situations where sample sizes or the number of strata are small, a t(n - k) distribution can (and should) be used for calculation of confidence intervals, where n=n_1+n_2+…+n_k.


Returns a list with two items:


A matrix with columns: N.h,n.h, and var.h


Confidence intervals for μ and T


Ken Aho


Lohr, S. L. (1999) Sampling: Design and Analysis. Duxbury Press. Pacific Grove, USA.

Siniff, D. B., and Skoog, R. O. (1964) Aerial censusing of caribou using stratified random sampling. Journal of Wildlife Management 28: 391-401.

See Also


#Data from Siniff and Skoog (1964)

[Package asbio version 1.7 Index]