Confidence interval (source code)

= Confidence interval
{title2=$C(X)=[L(X),U(X)]$}
{wiki}

A <confidence interval> is a random interval constructed from a <statistical sample> to cover a fixed unknown <statistical parameter> with a prescribed <coverage probability>. For a scalar target $\theta$, a procedure with nominal confidence $1-\alpha$ satisfies
$$
\mathbb P_\theta\{L(X)\leq\theta\leq U(X)\}\geq1-\alpha
\quad\text{for every admissible }\theta.
$$
The subscript records which <probability distribution> generates the repeated samples. The endpoints are <statistics>, so they vary from sample to sample; the target is fixed. Equality gives exact nominal <coverage probability>, while the inequality also permits conservative procedures. For a general <estimand> $\psi(\theta)$, replace the target inside the interval by $\psi(\theta)$.

A realized <confidence interval> communicates the precision of an estimate in the target's own units. Reporting $1.2$ alone conceals the difference between an estimate with <standard error> $0.5$ and one with <standard error> $0.05$. A narrow <confidence interval> indicates greater precision for the stated <statistical model>, rather than a guarantee that its assumptions describe the experiment correctly.

Once $x$ is observed, $C(x)$ either contains the fixed target or does not. The 95% statement concerns the random procedure $C(X)$, not a <posterior probability> of 0.95 that this particular interval contains $\theta$. A <credible interval> instead assigns specified <posterior probability> to a region under <Bayesian inference>. These interpretations can differ even when the numerical endpoints agree. The repeated-sampling interpretation is explained in https://www.itl.nist.gov/div898/handbook/eda/section3/eda352.htm[NIST's confidence-limits teaching reference].

Jerzy Neyman's 1937 paper formulates the fixed-target, random-endpoint construction in Section II, especially equation (20) on page 348. Its confidence coefficient must hold across the allowed <statistical parameters>, rather than only at the value suggested by one sample. See https://doi.org/10.1098/rsta.1937.0005[Neyman, Outline of a Theory of Statistical Estimation Based on the Classical Theory of Probability] and the https://wwwusers.ts.infn.it/~milotti/Didattica/StatisticaAvanzata/Neyman_1937.pdf[original paper scan].