6.5 - Type I and Type II errors

6.5 - Type I and Type II errors

A test can reject a true claim or miss a real change. You will distinguish these two mistakes, calculate their probabilities from a fixed decision rule, and see why demanding stronger evidence can make a genuine change harder to detect. The distribution used in an error calculation depends on which population situation is actually true.

Two possible wrong decisions

Suppose a factory tests whether its fault probability has fallen below 0.40.4. Rejecting the null means concluding that there is evidence of a reduction. What if faults have not become less likely? The favourable conclusion is then an error. Conversely, a genuinely improved process might produce an unremarkable sample, so that the test misses the improvement.

Type I and Type II errors

A Type I error occurs when a true null hypothesis is rejected. A Type II error occurs when a false null hypothesis is not rejected. The labels describe the truth of the null together with the test's decision, rather than whether the sample calculation was performed correctly.

Actual population situationReject H0H_0Do not reject H0H_0
H0H_0 is trueType I errorCorrect decision
A specified alternative is trueCorrect decisionType II error

These errors can occur even when every calculation and comparison is correct. Random sampling causes different decisions on different samples. A significance level controls the Type I error probability; it does not directly control the probability of missing a change.

Worked example 1: a claimed improvement that is not real

Question. A factory tests H0:p=0.4H_0:p=0.4 against H1:p<0.4H_1:p<0.4, where pp is its fault probability. It rejects H0H_0, but in fact p=0.4p=0.4. Identify the error in context.

Plan. Decide whether the null is true, then combine that truth with the rejection decision.

The actual value p=0.4p=0.4 makes H0H_0 true. The test nevertheless rejects it.

Answer. A Type I error: the test finds sufficient evidence of a reduced fault probability when the fault probability is still 0.40.4.

Check. “Reject a true null” is exactly the Type I combination in the decision table.

Now change both the actual situation and the decision to examine the other possible mistake.

Worked example 2: an improvement that is missed

Question. For the same hypotheses, a test does not reject H0H_0, but the actual fault probability is 0.20.2. Identify the error in context.

Plan. Compare the true value with the null, then interpret non-rejection.

Since 0.2≠0.40.2\ne0.4, H0H_0 is false; the stated alternative of a decrease is true. The test fails to detect enough evidence for that decrease.

Answer. A Type II error: the test fails to find sufficient evidence of a reduction although the actual fault probability has decreased to 0.20.2.

Check. The conclusion is “insufficient evidence”, rather than a proof that p=0.4p=0.4. An error can occur without anyone asserting the null is certainly true.

A Type II probability must refer to a particular actual alternative value. Missing a tiny decrease and missing a large decrease do not generally have the same probability.

Watch out

The significance level is calculated assuming H0H_0 is true. It is not the probability that a rejected null is true, or the probability that the current decision is wrong after observing the data.

Identify an error from its population truth and decision.

Errors in a discrete test

Once the rejection region is fixed, an error probability is a probability of landing in one of its regions. For Type I, use the null distribution and the rejection region. For Type II, use the specified actual alternative distribution and the acceptance region.

Error probabilities for a fixed rule

Let RR be the rejection region and AA its complement. Then

P(Type I error)=PH0(X∈R),\mathrm P(\text{Type I error})=\mathrm P_{H_0}(X\in R),

while, for a specified alternative parameter θ1\theta_1,

P(Type II error at θ1)=Pθ1(X∈A).\mathrm P(\text{Type II error at }\theta_1)=\mathrm P_{\theta_1}(X\in A).

The subscripts identify which population model supplies the probabilities. Not in the formula booklet: learn the meaning of the two events. Binomial and Poisson probability formulas are supplied.

Do not redesign the rejection region using the alternative parameter. The error calculation asks what the original test does when that alternative happens to be true.

Worked example 3: errors in a binomial test

Question. A test of H0:p=0.4H_0:p=0.4 against H1:p<0.4H_1:p<0.4 uses XX, the fault count among 1010 independent items. Its fixed critical region is X≤1X\le1. Find the Type I error probability and the Type II error probability if the actual value is p=0.2p=0.2.

Plan. Use the rejection region under p=0.4p=0.4, then its complement under p=0.2p=0.2.

Under the null, X∼B(10,0.4)X\sim\mathrm B(10,0.4), so

P(Type I)=Pp=0.4(X≤1)=0.610+10(0.4)(0.6)9=0.0463574.\begin{aligned} \mathrm P(\text{Type I})&=\mathrm P_{p=0.4}(X\le1)\\ &=0.6^{10}+10(0.4)(0.6)^9\\ &=0.0463574. \end{aligned}

The acceptance region is X≥2X\ge2. Under the specified alternative, X∼B(10,0.2)X\sim\mathrm B(10,0.2):

P(Type II at p=0.2)=Pp=0.2(X≥2)=1−[0.810+10(0.2)(0.8)9]=0.6241904.\begin{aligned} \mathrm P(\text{Type II at }p=0.2)&=\mathrm P_{p=0.2}(X\ge2)\\ &=1-[0.8^{10}+10(0.2)(0.8)^9]\\ &=0.6241904. \end{aligned}

Answer. Type I probability 0.04640.0464; Type II probability 0.6240.624 when p=0.2p=0.2.

Check. Under p=0.2p=0.2, the test detects the improvement with probability 0.37580960.3758096; this and 0.62419040.6241904 sum to 11. They do not sum with the Type I probability, which uses a different population.

Apply the same two-region reasoning to a Poisson count. Its population parameter and probability formula change; the decision rule still stays fixed.

Worked example 4: errors in a Poisson test

Question. A test investigates an increase in mean calls per hour using H0:λ=4H_0:\lambda=4, H1:λ>4H_1:\lambda>4. The one-hour count has fixed critical region X≥9X\ge9. Find the Type I probability and the Type II probability when the actual mean is 66 calls per hour.

Plan. Evaluate the upper rejection tail under Po⁡(4)\operatorname{Po}(4), and the lower acceptance region under Po⁡(6)\operatorname{Po}(6).

P(Type I)=1−e−4∑r=084rr!=0.0213634,P(Type II at λ=6)=e−6∑r=086rr!=0.8472375.\begin{aligned} \mathrm P(\text{Type I}) &=1-e^{-4}\sum_{r=0}^{8}\frac{4^r}{r!}=0.0213634,\\ \mathrm P(\text{Type II at }\lambda=6) &=e^{-6}\sum_{r=0}^{8}\frac{6^r}{r!}=0.8472375. \end{aligned}

Answer. Type I probability 0.02140.0214; Type II probability 0.8470.847 at the stated alternative.

Check. The test misses the increase whenever the observed count is 00 through 88. Using X≤9X\le9 would incorrectly include a rejecting result in the Type II event.

Continue this lesson.

You’re previewing NovaLearn without an account. Create a free account to read the rest.

Create free account