Calculating the Probability of a Type II Error
Assume that the sampled population is normally distributed, or that a large sample will be taken. Consider testing H0: μ = μ0 versus one of Ha: μ > μ0, Ha: μ < μ0, or Ha: μ ≠ μ0. Then, if we set the probability of a Type I error equal to α and randomly select a sample of size n, the probability, β, of a Type II error corresponding to the alternative value μa of μ is (exactly or approximately) equal to the area under the standard normal curve to the left of
Here z* equals zα if the alternative hypothesis is one-sided (μ > μ0 or μ < μ0), in which case the method for calculating β is exact. Furthermore, z* equals zα/2 if the alternative hypothesis is two-sided (μ ≠ μ0), in which case the method for calculating β is approximate.