Why P-Values Can Jump
A p-value is a probability calculated under a null model, but the possible outcomes of a study depend on the kind of data collected. If the data are a count, the count can take only whole-number values. Its null distribution therefore assigns probability to separate outcomes rather than spreading it continuously across a scale. Summing those probabilities can make exact p-values jump from one attainable value to another, leaving many numbers between them unavailable.
This matters when reading a result such as \(p=0.05\). An exact test based on a small count might not be able to produce that value at all. Its nearest possible p-values could be well above and well below 0.05. A continuous approximation can provide a smoother numerical estimate, but it is not the exact probability calculation for the discrete null model.
A Binomial Model and an Exact P-Value
Suppose \(X\) counts the number of successes in \(n\) independent trials, each with the same success probability \(p_0\) under the null hypothesis. Then the null model is \(X\sim\operatorname{Binomial}(n,p_0)\), with \[ P_0(X=k)={n\choose k}p_0^k(1-p_0)^{n-k}, \quad k=0,1,\ldots,n. \] The notation \(P_0\) emphasizes that these probabilities are calculated assuming the null model is true. To use this model, the trials must be independent, have two possible outcomes for the count, and share the same null success probability.
For a two-sided test, one must specify what counts as “at least as extreme” as the observed result. In the examples below, extremeness is measured by distance from the null mean \(np_0\). This gives the exact two-sided p-value \[ p_{\text{exact}}(x_{\text{obs}}) = P_0\left(\left|X-np_0\right|\geq\left|x_{\text{obs}}-np_0\right|\right). \] The probability is found by adding the null probabilities of all count outcomes at least as far from the null mean as the observed count. This is one standard two-sided convention; other conventions can order discrete outcomes differently, so the convention should be stated when it matters.
For a one-sided alternative that predicts unusually large counts, the exact p-value instead sums the upper tail: \[ p_{\text{exact}}=P_0(X\geq x_{\text{obs}}). \] In either case, the possible exact p-values come from sums of probabilities assigned to count outcomes. They are not freely selectable numbers.
Worked Example: A Very Small Binomial Test
Suppose a hypothetical process is tested with \(n=4\) independent trials. Under \(H_0\), each trial has success probability \(p_0=0.5\). The alternative is two-sided, and the observed count is \(x_{\text{obs}}=4\). Use distance from the null mean to calculate the exact p-value.
The null mean is \(np_0=4(0.5)=2\). The observed count is two away from that mean. Thus, the outcomes at least as extreme are \(X=0\) and \(X=4\). Under the binomial model, \[ P_0(X=0)={4\choose 0}(0.5)^0(0.5)^4=\frac{1}{16} \] and \[ P_0(X=4)={4\choose 4}(0.5)^4(0.5)^0=\frac{1}{16}. \] Adding the tail probabilities gives \[ p_{\text{exact}}=\frac{1}{16}+\frac{1}{16}=\frac{2}{16}=0.125. \]
For this test, possible observed counts are only 0, 1, 2, 3, and 4. Their exact two-sided p-values under the stated distance convention are respectively 0.125, 0.625, 1, 0.625, and 0.125. Thus, this test cannot produce an exact p-value such as 0.10 or 0.05. Its p-value moves between a few attainable values as the observed count changes.
Why the Set of Exact Values Is Limited
For fixed \(n\), a binomial count has only \(n+1\) possible outcomes: \(0,1,\ldots,n\). A test rule assigns a p-value to each possible outcome, so there can be no more than \(n+1\) different exact p-values for that fixed test. Often there are fewer, because different outcomes can produce the same p-value. For example, in a symmetric two-sided test with \(p_0=0.5\), counts equally far below and above the null mean have the same p-value.
The sizes of the jumps depend on the probabilities of the count outcomes. If one or more outcomes included in a tail have substantial probability, adding them can change the p-value noticeably. In the four-trial example, each extreme outcome has probability \(1/16\), so the smallest two-sided p-value under the chosen rule is 2/16. No observed count falls between the central outcomes and those extremes, so no exact p-value falls between 0.125 and 0.625.
Worked Example: A Larger Count and a Normal Approximation
In another hypothetical test, \(n=20\) independent trials have null success probability \(p_0=0.5\), and the observed count is \(X=15\). Use the same two-sided distance rule to calculate the exact p-value. Then compare it with a normal approximation using a continuity correction.
Under the null, the mean is \(np_0=10\). A count at least five away from 10 is 5 or lower, or 15 or higher. By symmetry, \[ p_{\text{exact}}=P_0(X\leq5)+P_0(X\geq15)=2P_0(X\geq15). \] The probability for the upper tail is \[ P_0(X\geq15) =\sum_{k=15}^{20}{20\choose k}(0.5)^{20} =\frac{1+20+190+1140+4845+15504}{1,048,576} =\frac{21,700}{1,048,576}. \] Therefore, \[ p_{\text{exact}}=\frac{43,400}{1,048,576}\approx0.04139. \]
For a normal approximation, the null binomial mean is \(\mu=10\) and its standard deviation is \(\sqrt{np_0(1-p_0)}=\sqrt{5}\approx2.236\). Both expected counts, \(np_0=10\) and \(n(1-p_0)=10\), are large enough for a normal approximation to be reasonable as a rough method. Because the count is discrete, a continuity correction puts the upper-tail boundary halfway between 14 and 15: \[ z=\frac{14.5-10}{\sqrt{5}}\approx2.012. \] The symmetric two-sided normal approximation is \[ p_{\text{normal}}\approx2P(Z\geq2.012)\approx2(0.0221)=0.0442, \] where \(Z\sim N(0,1)\). This is close to, but not identical to, the exact value 0.04139. The exact calculation adds binomial probabilities; the approximation uses areas under a continuous normal curve.
Even when using a continuous curve, the approximation for this fixed count test is evaluated at one of the possible integer counts. It does not make every possible numerical p-value attainable from the original data. Rather, it estimates discrete tail probabilities with a continuous model and may give different values from the exact calculation.
Unequal Probabilities and Unequal Jumps
When \(p_0\) is not 0.5, binomial probabilities are generally not symmetric around the center. The probability attached to each count can differ substantially, and therefore so can the sizes of the steps between attainable tail probabilities. For an upper-tailed test, the exact p-value at count \(x\) is the sum of the probabilities for \(x,x+1,\ldots,n\). Moving the observed count up by one removes the probability at the old boundary from that sum.
Worked Example: Upper-Tail Probabilities with Unequal Masses
Suppose a hypothetical device is checked in \(n=5\) independent trials. Under \(H_0\), the success probability is \(p_0=0.2\), and the alternative predicts a higher success rate. If the observed count is \(x_{\text{obs}}=2\), the exact one-sided p-value is \(P_0(X\geq2)\).
The probabilities in that tail are \[ P_0(X=2)={5\choose2}(0.2)^2(0.8)^3=0.2048, \] \[ P_0(X=3)={5\choose3}(0.2)^3(0.8)^2=0.0512, \] \[ P_0(X=4)={5\choose4}(0.2)^4(0.8)=0.0064, \quad P_0(X=5)=(0.2)^5=0.00032. \] Adding them gives \[ p_{\text{exact}}=0.2048+0.0512+0.0064+0.00032=0.26272. \]
If the observed count had been 3 instead, the upper-tail p-value would be \(0.0512+0.0064+0.00032=0.05792\). The change is 0.2048, exactly the probability mass at \(X=2\). The p-value does not decrease by a fixed amount each time the observed count increases; the step size is determined by the null probability at the count that leaves the tail.
A Short Justification: Why the Exact P-Value Is Calibrated
The discreteness of an exact p-value does not make it mathematically invalid. Under the null model, outcomes with p-values at most a chosen cutoff \(\alpha\) have total probability no greater than \(\alpha\). For the one-sided test, list the possible counts from most extreme to least extreme in the direction of the alternative. Their upper-tail probabilities decrease as the count increases. The counts whose p-values are at most \(\alpha\) therefore form an upper tail, or an empty set. If \(c\) is the smallest count in that rejection tail, then \[ P_0(\text{p-value}\leq\alpha)=P_0(X\geq c)=p_{\text{exact}}(c)\leq\alpha. \] If no count qualifies, that probability is zero.
The key inequality arises because the p-value for the boundary count \(c\) is the probability of the entire tail beginning at \(c\). That tail has probability at most \(\alpha\) by the rule for including \(c\). This argument also explains why discrete tests can be conservative at a chosen cutoff: the actual null probability of rejection may be less than \(\alpha\), because the next available tail probability might jump past the cutoff.
Common Mistake: Treating a Discrete P-Value as Any Number
A common mistake is to assume that an exact test must be able to return a p-value of exactly 0.05, or that a reported p-value near 0.05 can be adjusted to equal it. That reasoning ignores the possible outcomes and their null probabilities. For the four-trial example, the exact values were 0.125, 0.625, and 1; none is 0.05, and rounding cannot create an attainable exact value that was not calculated.
The correction is to distinguish the exact calculation from an approximation and report what was actually used. A small count may provide only a coarse set of exact p-values. A larger sample often creates more possible values and smaller probability jumps, but that does not guarantee that any particular target value is attainable. A continuous approximation can be useful when its conditions are reasonable, but it should not be described as the exact binomial tail probability.
Check Your Understanding
Try these questions using the distinction between discrete tail sums and continuous approximations.
- For \(X\sim\operatorname{Binomial}(3,0.5)\), how many different observed counts are possible? What does that imply about the maximum number of exact p-values for a fixed test rule?
- For a one-sided upper-tail test, explain why increasing the observed count by one changes the exact p-value by the null probability at the count that leaves the tail.
- In the \(n=4\), \(p_0=0.5\) example, why is 0.05 not an attainable exact two-sided p-value under the stated convention?
- What role does the continuity correction play when approximating a binomial tail with a normal distribution?
- Why can an exact discrete test have a null rejection probability below, rather than exactly equal to, a chosen cutoff \(\alpha\)?