AI Glossary / Statistics and probability / Intermediate
Horvitz - Thompson estimator
Definition
The Horvitz - Thompson estimator estimates a finite population total by summing each sampled unit's observed value divided by its probability of inclusion. With known, positive inclusion probabilities for all population units, it is unbiased over repeated samples from the specified probability-sampling design. It accommodates unequal selection probabilities without requiring every unit to be equally likely to appear.
What it means
A unit sampled rarely represents more of the population than a unit sampled frequently. The estimator accounts for that difference through inverse-probability weights.
Unbiased means that the average estimate across repeated applications of the sampling design equals the fixed population total. It does not mean every realized estimate is close to the total, and it does not automatically make a sample representative in every practical sense.
How it works
Define the finite population, the variable y_i, and each unit's inclusion probability pi_i. Inclusion means appearing at least once in the sample under the design. It should not be confused with a probability of selection on one draw when the design permits repeated draws.
For sampled units s, calculate the total estimate as sum over s of y_i/pi_i. Each sampled unit contributes its observed value multiplied by weight 1/pi_i. Under the inclusion-indicator formulation, a distinct unit contributes once, not once for every repeated appearance.
The unbiasedness argument is simple. If I_i indicates inclusion, then E(I_i) = pi_i. Consequently E(I_i*y_i/pi_i) = y_i, and summing these expectations gives the population total. This argument treats the population values as fixed and the sampling design as random.
If the population size N is known, divide the estimated total by N to estimate the population mean. Dividing instead by the sum of sampled weights gives a related ratio estimator, often called a Hájek estimator. That normalized form can behave differently and is not generally exactly design unbiased.
Uncertainty depends on the sampling design, including joint inclusion probabilities for pairs of units. Standard design-unbiased variance estimation generally requires appropriate positive pairwise inclusion probabilities. First-order positivity sufficient for unbiased total estimation is not the whole story for variance estimation.
Very small inclusion probabilities can create large weights and unstable estimates. Weight trimming or other stabilization can trade bias against variance, but it changes the estimator. Such modifications should be justified and reported rather than silently labeled ordinary Horvitz - Thompson estimation.
Coverage errors, nonresponse, and measurement errors are not automatically solved by design weights. If inclusion or response probabilities are estimated rather than known, additional modeling assumptions and uncertainty become relevant.
Use software and variance methods that understand the actual survey or sampling design. Treating weighted observations as if they were independent copies can produce incorrect standard errors, especially with clusters, strata, or sampling without replacement.
Three practical examples
- An AI audit deliberately samples rare request categories more often and uses recorded inclusion probabilities to estimate total error counts across the full request population.
- A survey estimates a population total from an unequal-probability sample.
- A quality team estimates total defective items when inspection probabilities differ across known production groups.
Think of it this way
Think of each sampled unit carrying a ticket stating how often the design would let it appear. A rare ticket receives a larger expansion weight. The arithmetic balances repeated sampling, but a single collection of tickets can still give a noisy result.
Worked example
Consider a population of three units with values 10, 20, and 30. The true total is 60 and the population mean is 20. A design selects exactly one unit, with probabilities 0.5, 0.3, and 0.2 respectively.
If the first unit is selected, the Horvitz - Thompson total is 10/0.5 = 20. If the second is selected, it is 20/0.3 = 200/3, approximately 66.6667. If the third is selected, it is 30/0.2 = 150.
Average over the design: 0.5 x 20 + 0.3 x (200/3) + 0.2 x 150 = 10 + 20 + 30 = 60. This verifies unbiasedness despite the large variation among possible estimates.
If the second unit is actually selected, the estimated mean using known N = 3 is (200/3)/3 = 200/9, approximately 22.2222. It need not equal the true mean in that sample.
The unweighted observed value has design expectation 0.5 x 10 + 0.3 x 20 + 0.2 x 30 = 17, so using it directly as the population mean would be biased here. Because the design selects only one unit, no distinct pair can appear together; the example therefore does not support the usual unbiased pairwise variance-estimation formula.
Illustrative case study
Fictional case: Hazel Audit reviews a sample of AI-generated responses. To inspect difficult cases more closely, it uses higher sampling rates for some categories and records the probability attached to every eligible response.
The analyst estimates the total number of responses meeting a clearly defined error criterion by inverse-probability expansion. It retains the distinction between the audit sample's raw error fraction and the estimate for the complete response population.
A few categories have very large weights, so the team examines precision and plans a more balanced allocation for the next audit. It does not quietly cap weights or claim that an unbiased estimator guarantees an accurate total from one small sample.
Common misconceptions and mistakes
Common mistakes include using draw probabilities instead of inclusion probabilities, counting repeated selections incorrectly, and normalizing weights while continuing to claim exact HT unbiasedness.
Do not assign an arbitrary small probability to units that were actually impossible to sample. A zero-probability part of the target population creates a coverage problem that the standard formula cannot repair.
Business use
The estimator helps businesses translate deliberately unequal audit or survey samples into population totals. Its usefulness depends on a documented probability design, accurate outcomes, and suitable uncertainty estimation. Reports should identify the target population, inclusion probabilities, weighting rules, and any adjustments beyond the original design.
People also ask
Can selection probabilities differ?
Yes; that is a central use case.
Does unbiased mean low variance?
No.
Is a weighted average with weights summing to one always HT?
No. Normalizing by sampled weights generally produces a ratio form rather than the known-population-size HT mean.
Check your understanding
What is the true total in the example?
Answer: Sixty.
What estimate results when the rarest unit is selected?
Answer: One hundred fifty.
Why is that compatible with unbiasedness?
Answer: Unbiasedness concerns the average over all possible samples under the design.
Related terms
- Inclusion probability
- inverse probability weighting
- probability sampling
- design-based inference
- Hájek estimator
- sampling weight
- joint inclusion probability
- survey variance
Learn next
Enumerate all samples in a tiny unequal-probability design and verify unbiasedness directly. Then study why estimating a total and estimating its variance require different inclusion-probability information.
More in Statistics and probability
- Homogeneity of regression - Homogeneity of regression usually means equality of the covariate regression slopes across groups in a common-slope analysis of covariance model.
- Homogeneity of variance - Homogeneity of variance is the condition that the populations or model-error distributions being compared have the same variance.
- Homogeneity of variance in arrays - Homogeneity of variance in arrays is the condition that the variance of an outcome Y is the same at different values of a predictor X.
- Hosmer - Lemeshow test - The Hosmer-Lemeshow test is a grouped goodness-of-fit test commonly used with binary logistic regression.
- Hot deck imputation - Hot deck imputation fills a missing value using an observed value from a suitable donor record in the same current dataset or survey collection.
- Hotelling's t-squared statistic - Hotelling's t-squared statistic, conventionally written T-squared or T^2, measures a multivariate departure while accounting for covariance among variables.
Sources
Aronow and Samii, variance estimation for Horvitz–Thompson: https://www150.statcan.gc.ca/n1/pub/12-001-x/2013001/article/11831/section2-eng.htm Statistics Canada-hosted original research, HT estimator and its drawback: https://www150.statcan.gc.ca/n1/pub/12-001-x/2019001/article/00007/02-eng.htm samplingbook developer documentation: https://samplingbook.manitz.org/reference/htestimate.html
Previous: Horseshoe distribution Next: Hosmer - Lemeshow test