Skip to contents

Compute the sample size per occasion required to estimate the equal-weight mean of the occasion estimates of a repeated survey with a specified margin of error or coefficient of variation, given how far the occasions overlap. Sizing an annual average built from quarterly rounds is the ordinary case. This is the inverse of prec_pooled().

Usage

n_pooled(var = NULL, ...)

# Default S3 method
n_pooled(
  var = NULL,
  occasions,
  ...,
  sd = NULL,
  p = NULL,
  mu = NULL,
  moe = NULL,
  cv = NULL,
  rmoe = NULL,
  alpha = 0.05,
  N = Inf,
  deff = 1,
  resp_rate = 1,
  overlap = 0,
  overlap_cor = NULL,
  cor_decay = NULL,
  df = NULL,
  plan = NULL,
  .overlap_basis = NULL
)

# S3 method for class 'svyplan_prec'
n_pooled(var, ..., moe = NULL, cv = NULL, rmoe = NULL)

Arguments

var

For the default method: the population variance \(S^2\) on one occasion, taken to be the same on each. Estimate from a pilot study, a previous round, or published data. Supply this or p, not both. For svyplan_prec objects: a precision result from prec_pooled().

...

Additional arguments passed to methods. Unused arguments are rejected.

occasions

Number of occasions entering the average, at least 2.

sd

Population standard deviation on one occasion, an alternative spelling of var. Supply exactly one of var or sd.

p

The proportion being averaged, as an alternative to var. The occasion variance is then \(Np(1-p)/(N-1)\), the same finite population variance n_prop() uses, and mu is determined and must not be supplied.

mu

The level being averaged, on the var scale. Required when cv or rmoe is specified, both being defined against it. Determined by p on the proportion scale.

moe

Desired margin of error on the pooled estimate, the half-width of its confidence interval. Specify exactly one of moe, cv, or rmoe.

cv

Target standard error relative to the level. Requires mu. Specify exactly one of moe, cv, or rmoe.

rmoe

Target margin of error relative to the level. It is moe / abs(mu) and requires mu. Specify exactly one of moe, cv, or rmoe.

alpha

Significance level, default 0.05.

N

Population size. Inf (default) means no finite population correction.

deff

Design effect multiplier (> 0), applied to the variance of the pooled estimate rather than to any one occasion.

resp_rate

Expected response rate, in (0, 1]. Default 1 (no adjustment). Each occasion's size is inflated by 1 / resp_rate. It is a single round's response, not attrition across a panel.

overlap

Fraction of one occasion's responding sample carried into a later one, in [0, 1]. One number, meaning the same overlap at every lag, or one per lag. A design_overlap() result is accepted directly at resp_rate = 1; see prec_pooled() on why not below it. 0 (default) makes the occasions independent.

overlap_cor

Correlation between two occasions among the units they share, in [0, 1]. One number for every lag, or one per lag. Default 0, which makes overlap irrelevant. Supply this or cor_decay, not both.

cor_decay

Correlation at lag \(m\) taken as \(\rho^m\), an alternative to stating overlap_cor lag by lag.

df

Degrees of freedom of the variance estimator the planned design will have, available from design_df(). It switches the interval quantile from normal to t. NULL (default) applies no adjustment.

plan

Optional svyplan() object providing design defaults.

.overlap_basis

Internal. Records whether a stored overlap profile was resolved from a design_overlap() object ("issued") or supplied as respondent overlap ("respondent"), so that a round trip or a grid meets the same refusal the first call would have. Set from the result being re-read; there is no reason to pass it by hand.

Value

A svyplan_n object with type = "pooled":

n

Required size per occasion, continuous and gross. It already carries deff and the 1 / resp_rate inflation, so it counts the units to release on each occasion, not the completed interviews. $n and as.double() keep the unrounded value, which is what makes the round trip through prec_pooled() exact; print() rounds up. This is not a count of distinct frame units: overlap is measured among respondents, so it says how often a respondent is measured again and leaves the issued sample's own overlap unstated. At full response the two coincide and the series consumes fewer than occasions * n distinct units; below it, how many is a question this function has not been told enough to answer.

se, moe, cv, rmoe

Precision the design achieves at that size, the same values prec_pooled() reports for the same inputs. cv and rmoe are NA unless the level is known.

params

The validated inputs, including whichever of moe, cv, or rmoe was the target, overlap and overlap_cor as resolved vectors of one entry per lag, and the overlap_basis they were resolved under.

Details

The pooled variance is \(deff\{A/(n r) + B\}\) in the gross size per occasion, with \(r\) the response rate, \(T\) the number of occasions and

$$A = \frac{S^2}{T^2}\Big[T + 2\sum_{m=1}^{T-1}(T-m)\rho_m o_m\Big], \qquad B = -\frac{S^2}{NT^2}\Big[T + 2\sum_{m=1}^{T-1}(T-m)\rho_m \mathbb{1}\{o_m > 0\}\Big],$$

so the target inverts in closed form,

$$n = \frac{deff\,A}{r\,(se^2 - deff\,B)}.$$

\(B \le 0\) always under the nonnegative correlation contract, since its bracket is at least \(T\), so the divisor cannot vanish and no target is out of reach for want of precision however much the occasions overlap. Overlap raises the size a target needs; it does not put a floor under the precision. The size can still exceed \(N\), which is the ordinary boundary and is reported as unattainable there as everywhere else.

Sizing for a pooled estimate or for a change

The two arms pull in opposite directions against one design lever, and which arm gains depends on the sign of the covariance the overlap induces. Above a sampling fraction of \(o_m > n/N\), the ordinary case and the only one without a finite population correction, overlap improves a change and raises the size a pooled target needs. Below it the occasions share fewer units than chance would give them and the directions reverse; prec_pooled() works the boundary. The level at a single occasion is unaffected either way. A design serving a pooled target and a change target is sized by taking the larger of n_pooled() and n_change(), since neither dominates.

References

Kish, L. (1965). Survey Sampling. Wiley. Chapter 12.

See also

prec_pooled() for the inverse (compute precision from a size) and for what the covariance assumes, n_change() for the other arm of the trade-off, design_overlap() for the overlap a rotation schedule gives, n_mean() and n_prop() for a single occasion.

Other sample size functions: n_alloc(), n_change(), n_cluster(), n_mean(), n_multi(), n_multi_cluster(), n_panel(), n_prop(), n_twophase()

Examples

# Four independent quarterly rounds averaged into an annual figure
n_pooled(var = 100, moe = 1, occasions = 4)
#> Sample size for pooled estimate (mean scale)
#> n = 97 per occasion, 4 occasions (var = 100, deff = 1)
#> No between-occasion covariance (overlap x overlap_cor = 0)
#> se = 0.5102, moe = 1

# The same target from a rotating panel needs more per occasion
n_pooled(var = 100, moe = 1, occasions = 4, overlap = 0.75,
         cor_decay = 0.8)
#> Sample size for pooled estimate (mean scale)
#> n = 248 per occasion, 4 occasions (var = 100, deff = 1)
#> overlap = 0.75, overlap_cor = 0.8 at lag 1, shared out to lag 3
#> se = 0.5102, moe = 1

# An annual average of a proportion, to within one point
n_pooled(p = 0.3, moe = 0.01, occasions = 12, overlap = 0.75,
         cor_decay = 0.9)
#> Sample size for pooled estimate (proportion scale)
#> n = 4321 per occasion, 12 occasions (p = 0.3, deff = 1)
#> overlap = 0.75, overlap_cor = 0.9 at lag 1, shared out to lag 11
#> se = 0.005102, moe = 0.01, cv = 0.01701, rmoe = 0.03333

# Relative target: the average to within 5 percent of itself
n_pooled(var = 100, mu = 20, rmoe = 0.05, occasions = 4)
#> Sample size for pooled estimate (mean scale)
#> n = 97 per occasion, 4 occasions (var = 100, mu = 20, deff = 1)
#> No between-occasion covariance (overlap x overlap_cor = 0)
#> se = 0.5102, moe = 1, cv = 0.02551, rmoe = 0.05

# With FPC, design effect, and response
n_pooled(var = 100, moe = 1, occasions = 4, N = 50000, deff = 1.5,
         resp_rate = 0.8)
#> Sample size for pooled estimate (mean scale)
#> n = 180 per occasion (net: 144), 4 occasions (var = 100, deff = 1.50)
#> No between-occasion covariance (overlap x overlap_cor = 0)
#> se = 0.5102, moe = 1