{
  "id": "effective-sample-size",
  "title": "Effective Sample Size",
  "lang": "en",
  "source_lang": "en",
  "summary": "Effective sample size expresses the precision of an estimator as the number of independent, equally weighted observations needed to achieve comparable precision.",
  "category": "mathematics",
  "subcategory": "probability-statistics",
  "type": "concept",
  "aliases": [
    "ESS",
    "effective number of observations",
    "effective number of samples"
  ],
  "generated_at": "2026-11-05",
  "model": "pro/gpt-6.1-sol",
  "url": "https://aiwiki.page/en/effective-sample-size/",
  "translations": {
    "zh-Hans": {
      "url": "https://aiwiki.page/zh/effective-sample-size/",
      "json": "https://aiwiki.page/zh/effective-sample-size.json"
    }
  },
  "sections": [
    {
      "heading": "",
      "text": "Effective sample size (ESS) is a measure in statistics that translates the precision of an estimate into an equivalent number of observations under a specified reference sampling scheme. It is commonly used when observations are correlated, carry unequal weights, or arise from a complex sampling design. A dataset containing \\(n\\) observations may provide substantially less information than \\(n\\) independent, equally weighted observations, although some designs and dependence structures can produce an effective sample size greater than \\(n\\). ESS is not a single universal quantity: its definition depends on the estimator, the reference experiment, and the aspect of precision being measured."
    },
    {
      "heading": "Variance-based definition",
      "text": "For \\(n\\) independent observations from the same distribution, each with variance \\(\\sigma^2\\), the sample mean has variance\n\n\\[\\operatorname{Var}(\\bar X)=\\frac{\\sigma^2}{n}.\\]\n\nIf an estimator \\(\\hat\\mu\\) estimates the same population mean under a different sampling scheme, a natural variance-matching definition is\n\n\\[n_{\\mathrm{eff}} = \\frac{\\sigma^2}{\\operatorname{Var}(\\hat\\mu)}.\\]\n\nThus, if an estimator has variance \\(0.01\\sigma^2\\), its effective sample size is 100 relative to independent sampling from that population.\n\nMore generally, suppose the reference estimator based on \\(m\\) independent observations has variance approximately \\(V/m\\). Then\n\n\\[n_{\\mathrm{eff}}\\approx \\frac{V}{\\operatorname{Var}(\\hat\\theta)}.\\]\n\nHere \\(V\\) depends on the target quantity and the reference estimator. Consequently, the same observations can have different effective sample sizes for a mean, a proportion, a regression coefficient, or a quantile.\n\nThis interpretation concerns sampling precision, not every aspect of information. In particular, it does not account directly for bias. A highly precise estimate can still be systematically wrong, so a large ESS does not by itself imply small mean squared error."
    },
    {
      "heading": "Unequal observation weights",
      "text": "Kish effective sample size\n\nSuppose observations \\(X_1,\\ldots,X_n\\) have a common mean, common variance \\(\\sigma^2\\), and are independent. For fixed, nonnegative weights \\(w_i\\), with at least one positive weight, consider the weighted mean\n\n\\[\\hat\\mu_w = \\frac{\\sum_{i=1}^{n}w_iX_i} {\\sum_{i=1}^{n}w_i}.\\]\n\nIts variance is\n\n\\[\\operatorname{Var}(\\hat\\mu_w) = \\sigma^2 \\frac{\\sum_{i=1}^{n}w_i^2} {\\left(\\sum_{i=1}^{n}w_i\\right)^2}.\\]\n\nMatching this to \\(\\sigma^2/n_{\\mathrm{eff}}\\) gives the Kish effective sample size:\n\n\\[n_{\\mathrm{eff}} = \\frac{\\left(\\sum_{i=1}^{n}w_i\\right)^2} {\\sum_{i=1}^{n}w_i^2}.\\]\n\nFor normalized weights\n\n\\[a_i=\\frac{w_i}{\\sum_jw_j},\\]\n\nthe same expression becomes\n\n\\[n_{\\mathrm{eff}}=\\frac{1}{\\sum_i a_i^2}.\\]\n\nMultiplying all weights by the same positive constant leaves ESS unchanged. Equal weights give \\(n_{\\mathrm{eff}}=n\\); a single nonzero weight gives \\(n_{\\mathrm{eff}}=1\\). For nonnegative weights,\n\n\\[1\\le n_{\\mathrm{eff}}\\le n,\\]\n\nwith the upper bound following from the Cauchy–Schwarz inequality.\n\nFor example, normalized weights \\(0.7,0.1,0.1,0.1\\) give\n\n\\[n_{\\mathrm{eff}} = \\frac{1}{0.7^2+3(0.1^2)} \\approx1.92.\\]\n\nAlthough four observations are present, their weighted average has the same variance as approximately 1.92 independent, equally weighted observations under the stated assumptions.\n\nRelationship to weight variability\n\nDefine the coefficient of variation of the weights using divisor \\(n\\):\n\n\\[\\operatorname{CV}_w^2 = \\frac{n^{-1}\\sum_i(w_i-\\bar w)^2}{\\bar w^2}.\\]\n\nThen\n\n\\[n_{\\mathrm{eff}} = \\frac{n}{1+\\operatorname{CV}_w^2}.\\]\n\nThis identity expresses how concentration of weight reduces the effective number of contributing observations.\n\nIts interpretation requires care. If weights depend on observed outcomes, observations have different variances, or observations are dependent, the weight-only formula need not equal a variance-matched ESS. For fixed normalized weights and covariance matrix \\(\\Sigma\\), the general variance is\n\n\\[\\operatorname{Var}(\\hat\\mu_w)=a^\\mathsf{T}\\Sigma a,\\]\n\nwhich cannot generally be inferred from weight dispersion alone."
    },
    {
      "heading": "Complex survey sampling",
      "text": "In survey sampling, precision depends on features such as clustering, stratification, unequal selection probabilities, and weighting adjustments.\n\nThe design effect for an estimator is\n\n\\[\\operatorname{DEFF} = \\frac{\\operatorname{Var}_{\\mathrm{design}}(\\hat\\theta)} {\\operatorname{Var}_{\\mathrm{reference}}(\\hat\\theta)}.\\]\n\nWhen the reference variance for a nominal sample of size \\(n\\) scales as \\(1/n\\), a corresponding effective sample size is\n\n\\[n_{\\mathrm{eff}} = \\frac{n}{\\operatorname{DEFF}}.\\]\n\nThe reference is commonly simple random sampling, but whether sampling is with or without replacement, and whether a finite-population correction is included, matters. If the reference variance does not scale exactly as \\(1/n\\), the expression is an approximation or a reporting convention rather than an exact variance match.\n\nClustered observations\n\nUnder a simple model with equal cluster size \\(m\\), equal individual variances, common within-cluster correlation \\(\\rho\\), and independent clusters, the design effect for the overall mean is\n\n\\[\\operatorname{DEFF}=1+(m-1)\\rho.\\]\n\nHence\n\n\\[n_{\\mathrm{eff}} = \\frac{n}{1+(m-1)\\rho}.\\]\n\nFor example, 1,000 observations arranged in independent clusters of 10, with within-cluster correlation \\(0.1\\), have\n\n\\[n_{\\mathrm{eff}} = \\frac{1000}{1.9} \\approx526.\\]\n\nThe result does not extend unchanged to unequal cluster sizes or arbitrary correlation structures.\n\nClustering with positive within-cluster correlation usually reduces precision relative to independent sampling. Effective stratification can instead reduce variance below the reference variance, giving \\(\\operatorname{DEFF}<1\\) and \\(n_{\\mathrm{eff}}>n\\). This is greater efficiency relative to the chosen reference, not an increase in the actual number of observations."
    },
    {
      "heading": "Correlated sequences",
      "text": "For observations from a stationary process, the variance of a mean depends on correlations across time. Let each observation have variance \\(\\sigma^2\\), and define the lag-\\(k\\) autocorrelation as\n\n\\[\\rho_k = \\frac{\\operatorname{Cov}(X_t,X_{t+k})}{\\sigma^2}.\\]\n\nThe exact variance of the mean of \\(n\\) consecutive observations is\n\n\\[\\operatorname{Var}(\\bar X_n) = \\frac{\\sigma^2}{n} \\left[ 1+2\\sum_{k=1}^{n-1} \\left(1-\\frac{k}{n}\\right)\\rho_k \\right].\\]\n\nThe corresponding effective sample size is therefore\n\n\\[n_{\\mathrm{eff}} = \\frac{n}{ 1+2\\sum_{k=1}^{n-1} \\left(1-\\frac{k}{n}\\right)\\rho_k }.\\]\n\nThis expression shows that correlations at many lags can matter; adjusting only for the correlation between neighboring observations is generally insufficient.\n\nWhen the autocorrelations are absolutely summable and an appropriate central limit theorem holds, the large-sample approximation is\n\n\\[n_{\\mathrm{eff}} \\approx \\frac{n}{\\tau_{\\mathrm{int}}}, \\qquad \\tau_{\\mathrm{int}} = 1+2\\sum_{k=1}^{\\infty}\\rho_k.\\]\n\nHere \\(\\tau_{\\mathrm{int}}\\) is the integrated autocorrelation time under a convention in which independent observations have \\(\\tau_{\\mathrm{int}}=1\\).\n\nPositive serial correlation generally reduces ESS. Negative correlation can make \\(\\tau_{\\mathrm{int}}<1\\), producing ESS greater than the number of observations.\n\nFirst-order autoregressive example\n\nFor a stationary first-order autoregressive model with \\(\\rho_k=\\phi^k\\), where \\(|\\phi|<1\\),\n\n\\[\\tau_{\\mathrm{int}} = \\frac{1+\\phi}{1-\\phi},\\]\n\nso\n\n\\[n_{\\mathrm{eff}} \\approx n\\frac{1-\\phi}{1+\\phi}.\\]\n\nIf \\(\\phi=0.8\\), the effective sample size is approximately \\(n/9\\). This is a large-sample approximation; the finite-sample formula retains the factors \\(1-k/n\\)."
    },
    {
      "heading": "Markov chain Monte Carlo",
      "text": "In Markov chain Monte Carlo (MCMC), successive simulation draws are usually dependent. ESS describes the precision of a Monte Carlo estimate relative to independent draws from the target distribution.\n\nFor a target function \\(f\\), define\n\n\\[\\hat\\mu_f=\\frac{1}{n}\\sum_{t=1}^{n}f(X_t).\\]\n\nUnder suitable stationarity and limit-theorem conditions,\n\n\\[n_{\\mathrm{eff},f} \\approx \\frac{n}{ 1+2\\sum_{k=1}^{\\infty}\\rho_k^{(f)} },\\]\n\nwhere \\(\\rho_k^{(f)}\\) is the autocorrelation of the transformed sequence \\(f(X_t)\\). The Monte Carlo standard error is then approximately\n\n\\[\\operatorname{MCSE}(\\hat\\mu_f) \\approx \\sqrt{ \\frac{\\operatorname{Var}_{\\pi}(f(X))} {n_{\\mathrm{eff},f}} }.\\]\n\nThis dependence on \\(f\\) is essential. A chain may estimate a mean efficiently while estimating tail probabilities poorly.\n\nPractical diagnostics distinguish bulk ESS, commonly calculated from rank-normalized draws, from tail ESS, which assesses sampling efficiency in distributional tails. These diagnostics need not equal the ESS for the original-scale mean.\n\nAutocorrelations must be estimated from finite runs. Summing noisy estimates over many lags is unstable, so software uses truncation, paired-sequence methods, or other long-run variance estimators. Multi-chain methods can also account for disagreement between chains.\n\nESS alone does not establish convergence to the posterior distribution or another target. A chain trapped in one region can yield an apparently favorable autocorrelation-based ESS while failing to explore important regions. Convergence diagnostics and ESS address related but distinct questions."
    },
    {
      "heading": "Importance sampling and particle methods",
      "text": "In importance sampling, draws from a proposal distribution are assigned weights to represent a target distribution. For normalized weights \\(\\tilde w_i\\), a common diagnostic is\n\n\\[n_{\\mathrm{eff,weights}} = \\frac{1}{\\sum_i\\tilde w_i^2}.\\]\n\nThis measures weight concentration and is algebraically identical to the Kish formula. It approaches \\(n\\) for nearly uniform weights and approaches 1 when one weight dominates.\n\nHowever, it is not generally the exact ESS for an importance-sampling estimate. For independent proposal draws \\(X_i\\sim q\\), normalized target density \\(\\pi\\), and weights \\(w(x)=\\pi(x)/q(x)\\), the self-normalized estimate of\n\n\\[\\mu=\\operatorname{E}_{\\pi}[f(X)]\\]\n\nhas, under suitable moment and support conditions, asymptotic variance\n\n\\[\\frac{1}{n} \\operatorname{E}_{q} \\left[w(X)^2\\bigl(f(X)-\\mu\\bigr)^2\\right].\\]\n\nIts variance-matched ESS therefore depends on both the weights and the integrand \\(f\\). A weight-only diagnostic cannot capture that dependence.\n\nIn sequential Monte Carlo, weight-based ESS is often used to trigger resampling. Resampling can restore equal weights, but it may create repeated particles sharing the same ancestors. An ESS equal to the particle count immediately after resampling does not imply that all particles contain independent information."
    },
    {
      "heading": "Interpretation and limitations",
      "text": "An ESS value is meaningful only with its definition and reference specified.\n\n- It is estimator-specific. Means, quantiles, tail probabilities, and model parameters can have different effective sample sizes.\n- It is not necessarily an integer. ESS is an equivalence measure, not a literal count of retained observations.\n- It need not be bounded by nominal sample size. The nonnegative-weight Kish formula is bounded by \\(n\\), whereas variance-based definitions can exceed \\(n\\).\n- It does not correct systematic error. Selection bias, model misspecification, and incomplete simulation exploration are not removed by reporting ESS.\n- It is itself estimated. Short sequences, slowly decaying dependence, and unstable weights can make ESS estimates unreliable.\n- It is not automatically a degrees-of-freedom adjustment. Replacing nominal sample size with ESS in a test or confidence interval does not by itself establish the correct reference distribution or coverage.\n- Its standard interpretation can fail without finite variances. Heavy-tailed importance weights or dependence that prevents an ordinary central limit theorem may invalidate conventional variance-based ESS calculations.\n\nA reproducible report identifies the estimator or diagnostic being assessed, the nominal sample size, the reference sampling scheme, and the method used to calculate ESS."
    }
  ],
  "links": [
    "statistics",
    "variance",
    "sample-mean",
    "quantile",
    "estimator-bias",
    "mean-squared-error",
    "cauchy-schwarz-inequality",
    "covariance-matrix",
    "survey-sampling",
    "stationary-process",
    "autocorrelation",
    "central-limit-theorem",
    "autoregressive-model",
    "markov-chain-monte-carlo",
    "standard-error",
    "posterior-distribution",
    "importance-sampling",
    "selection-bias",
    "confidence-interval"
  ],
  "sources": [],
  "license": "https://creativecommons.org/licenses/by/4.0/"
}