3.7 When only one direction matters
Sometimes we care about one end only. Why pay for the other?
A confidence interval spends half its error budget at each end. Often only one end is of interest.
A regulator checking whether a pollutant exceeds a limit does not care how low it might be. A funder asking whether attendance is at least 24 classes does not care how high it might be. In these cases the whole of \(\alpha\) can be spent on the side that matters, which buys a tighter bound.
A one-sided confidence bound uses \(z_{\alpha}\) rather than \(z_{\alpha/2}\):
\[\text{upper bound:}\quad \bar{x} + z_{\alpha}\frac{\sigma}{\sqrt{n}} \qquad\qquad \text{lower bound:}\quad \bar{x} - z_{\alpha}\frac{\sigma}{\sqrt{n}}\]
At 95% confidence, \(z_{\alpha} = 1.645\) rather than 1.960.
x_bar <- 26.4; sigma <- 5.45; n <- 40
round(c(two_sided_lower = x_bar - qnorm(0.975) * sigma / sqrt(n),
two_sided_upper = x_bar + qnorm(0.975) * sigma / sqrt(n),
one_sided_upper = x_bar + qnorm(0.950) * sigma / sqrt(n),
one_sided_lower = x_bar - qnorm(0.950) * sigma / sqrt(n)), 3)#> two_sided_lower two_sided_upper one_sided_upper one_sided_lower
#> 24.71 28.09 27.82 24.98
The one-sided bound is closer to the estimate than the two-sided one at the same confidence level. Nothing has been gained for free: we have given up any claim about the other direction entirely.
The choice between one-sided and two-sided must be made before looking at the data, on the basis of what the question is.
Computing a two-sided interval, noticing it just fails to exclude some value of interest, and switching to a one-sided bound to obtain a tighter result is not a calculation. It is a way of arranging to be right, and the stated confidence level no longer describes what was done.