1-sample Poisson rate test: exact test for defects per unit
The 1-sample Poisson rate test checks whether a rate of events per unit of exposure, such as defects per square meter, breakdowns per 1,000 hours or errors per batch, differs from a target. It treats the total count as a Poisson variable and computes the p-value exactly from the Poisson distribution. Its confidence interval for the rate comes from the chi-square distribution.
When to use it
- You count events that can happen any number of times in a stretch of time, length, area or volume: pinholes in a coating, flaws in a fabric roll, unplanned stops on a line.
- You want to check that rate against a requirement or a historical value.
- You need a confidence interval for a rate, for example "0.74 to 1.64 pinholes per 100 m²".
- If each unit is either defective or not (at most one event per unit), use the 1 proportion test instead. To track a rate over time, use a U chart or a C chart.
How it works
Let x be the total count observed over a total exposure T (in whatever unit you choose: hours, m², batches), and λ the true rate per unit of exposure. The estimated rate is λ̂ = x/T.
- H₀: λ = λ₀.
- H₁: λ ≠ λ₀, or λ > λ₀, or λ < λ₀.
Under H₀, the count X is Poisson with mean μ₀ = λ₀T. The exact test sums Poisson probabilities:
p-value (H₁: λ > λ₀) = P(X ≥ x) = 1 − Σ_{k=0}^{x−1} e^(−μ₀) μ₀ᵏ / k!For H₁: λ < λ₀ the p-value is P(X ≤ x). For a two-sided test, a common choice is twice the smaller tail, capped at 1.
The exact confidence interval uses the link between the Poisson and chi-square distributions:
λ_lower = χ²(α/2, 2x) / (2T) λ_upper = χ²(1 − α/2, 2x + 2) / (2T)Assumptions: events occur independently of each other, at a constant rate over the exposure. Clusters of events (one bad spot causing several defects) break the assumption; the Poisson goodness-of-fit test can check it.
Example
A coil coating line paints steel strip for appliance panels. The customer requirement is at most 0.8 pinholes per 100 m². After a change of primer, an inspector checks 12 coils, 200 m² of each (2,400 m² in total, so T = 24 units of 100 m²), and finds 27 pinholes:
| Coil | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Pinholes in 200 m² | 4 | 1 | 3 | 4 | 2 | 2 | 3 | 2 | 1 | 2 | 1 | 2 |
The estimated rate is λ̂ = 27/24 = 1.125 pinholes per 100 m², above the 0.8 requirement. Is that evidence that the new primer misses the requirement? Test H₀: λ = 0.8 against H₁: λ > 0.8, α = 0.05.
- Expected count under H₀: μ₀ = 0.8 × 24 = 19.2.
- Exact p-value: P(X ≥ 27 | μ = 19.2) = 0.054.
- One-sided 95% lower bound: χ²(0.05, 54)/(2 × 24) = 0.794 pinholes per 100 m².
- Two-sided 95% CI: χ²(0.025, 54)/48 = 0.741 to χ²(0.975, 56)/48 = 1.637 pinholes per 100 m².
A normal approximation, z = (27 − 19.2)/√19.2 = 1.78, would give p = 0.038 and the opposite decision at the 5% level.
How to read the results
- The exact p-value of 0.054 is just above 0.05. The data suggest the rate is higher than 0.8, but they do not establish it at the 5% level. The lower bound of 0.794, just under 0.8, says the same thing.
- Do not read this as "the primer is fine". The best estimate is 1.125, about 40% above the requirement, and the interval reaches 1.64. The risk is clearly on the high side.
- The practical answer is to collect more coils. If twice the area showed the same rate (54 pinholes in 4,800 m²), the exact p-value would be about 0.01. Meanwhile, compare with the old primer's rate using the 2-sample Poisson rate test.
- Exact versus approximate. With counts around 20, the normal approximation can still shift a borderline p-value across 0.05. Prefer the exact test.
Common mistakes
- Ignoring the exposure. 27 pinholes in 2,400 m² and 27 in 1,200 m² are very different rates. Always state the count and the exposure together.
- Testing clustered defects as Poisson. If one coil had 15 pinholes from a single contaminated roll, the events are not independent and the exact test overstates the evidence.
- Choosing the exposure unit after the fact. The unit (per m², per 100 m²) changes the numbers, not the conclusion, but keep it the same as in the requirement to avoid confusion.
- Using a normal approximation with small counts. Below about 10 events, it can be badly off. The exact test costs nothing extra.
Frequently asked questions
What is the difference between a Poisson rate test and a proportion test?
A proportion test counts units that are defective or not, so each unit contributes 0 or 1. A Poisson rate test counts events, and one unit or one square meter can have several. Use the one that matches how you count.
Why does the confidence interval use the chi-square distribution?
Because the probability that a Poisson count is at most x equals a chi-square tail probability with 2x + 2 degrees of freedom. That identity gives exact limits without trial and error.
Can the exposure be different for each unit?
Yes. Only the total count and the total exposure enter the test, so coils, rolls or shifts of different sizes are fine, as long as the rate is the same throughout.
What if I observed zero events?
The estimated rate is 0, and the exact one-sided 95% upper bound is χ²(0.95, 2)/(2T), which is about 3/T. For example, zero stops in 1,000 hours gives an upper bound of about 3 stops per 1,000 hours.