>>We’ve addressed confidence intervals and hypothesis testing for differences in the
means of two populations. And, as you might have guessed, we can also address problems
of statistical inference for the differences in proportions from two populations.
It might be that we’re not interested in the mean performance of a process or system,
but we’re interested in the proportion of the occurrences of a particular outcome in
that process or system.
For example, we might want to know whether the proportion of component parts produced
outside of specifications by one machine is similar to those outside of specs by another
machine. Or whether the proportion of detected objects found using the current radar design
differs from a new design. Or whether the proportion of orders filled under a particular
cycle time with one facility layout is the same as another layout.
In all of those cases, we collect a sample from each population, we count the number
of “successes” – that occurrence that we’re interested in measuring, and we calculate
the proportion of successes in the sample. Then we use that sample proportion to estimate
the population proportion, in the form of a confidence interval.
We know, of course, that a sample proportion is itself a random variable. And the difference
in sample proportions, p-one-hat minus p-two-hat, is also a random variable. The sampling distribution
for p-one-hat minus p-two-hat has a mean p-one minus p-two and a standard deviation that
is shown on the screen. Much like with previous population parameters, we use this sampling
standard deviation in the calculation of the confidence interval for the difference in
proportions. Note that you might encounter some textbooks that use an approximation for
the standard deviation.
And so we have a one minus alpha times one hundred percent confidence interval within
which the true difference in population proportions of two populations lies. We have a point estimate
for the difference in proportions, p-one-hat minus p-two-hat, then we add to that and subtract
from it a margin of error. And as always, that margin of error is a function of variability,
sample size, and confidence. For confidence, we use a Z distribution, as we assume that
sample sizes are sufficiently large.
Let’s look at an example. Say you’re a production engineer for Designs by Leslie,
which produces a line of puffy shirts. There are two different stitching machines that
are used for the puffy shirts, and you want to study the difference in quality of the
two machines, Machine A and Machine B. Here, we’re going to measure quality with the
proportion of defective puffy shirts. You gather a sample of three hundred seventy-one
puffy shirts made from Machine A, and in those three hundred seventy one, you found twenty-eight
that had some stitching problems significant enough to consider them defective. And from
Machine B, you sample three hundred fourteen puffy shirts and found fourteen to be defective.
Let’s calculate a confidence interval for the real difference in proportions of defective
puffy shirts made by these two machines.
If we want ninety percent confidence, alpha would be point one, and the z value with point
oh five in each tail is one point six four five. So, the ninety percent confidence interval
for the true difference in proportions of puffy shirt defects between Machine A and
Machine B is point zero zero one three to point zero six zero five.
And we can also answer hypotheses about the differences in proportions. We might want
to know if the proportion of successes in population one is equal to that of population
two. Or are those two proportions not equal to each other? Much like before in our discussion
of the differences in two means, we can rearrange these two hypotheses to have the appearance
of testing for a difference. And we don’t have to test for just a difference of zero.
We can specify a particular difference D-naught in the hypotheses: is the difference in proportions
equal to a particular value or not? And just like always, we can addresses three different
forms of hypotheses: strict equality versus strict inequality, greater than or equal to
in the null versus strictly less than in the alternative, and less than or equal to in
the null versus strictly greater than in the alternative. Equality always in the null,
with a rejection region in one or two tails governed by the statement in the alternative.
The test statistic works much like you’d think it would. We have a point estimate for
a difference in proportions – our sample evidence. And from that we subtract off the
difference in population proportions that we’d like to determine, D-naught. So, in
the numerator, we have the difference between the sample evidence and the hypothesized value.
That is, how different are these two quantities from each other? And we find that difference
not in terms of raw numbers, but in terms of standard deviations. So in the denominator,
we have the standard deviation of the sampling distribution. Naturally this is a Z test statistic,
as we’re dealing with proportions.
Let’s apply this test statistic to answer a set of hypotheses. Kruger Industrial Smoothing
produces bearings that are used in a variety of applications. The bearing production process
requires several operations to get a bearing to be an appropriate diameter. If the final
bearing product has too big of a diameter, it can be repolished to reduce a small amount
of excess diameter. But sometimes repolishing doesn’t always work, and too much is taken
off. Operators at Facility A seem to be pretty good at the repolishing operation relative
to Facility B. We take a sample of two hundred seventeen bearings that need to be repolished
from Facility A and found that a hundred eighty nine of them were within specifications after
the repolishing operation. That would result in a sample proportion of point eight seven
one. From Facility B, we collected a sample of two hundred and forty-six bearings that
needed to be repolished, and two hundred four of those were within specifications afterward,
or a sample proportion of point eight two nine. And say we want to know if the proportion
within specification after repolishing is greater for those repolished in Facility A
versus Facility B. “Greater than” suggests an alternative hypothesis statement, as it
doesn’t contain equality.
We plug the sample proportions and sample sizes into the test statistic equation, and
we find that z-naught is one point two seven. We find that the p-value associated with this
one tail test is the area above one point two seven on the z-axis, or point one zero
two. This is a borderline p-value. It’s really close to point one, which would usually
be the maximum value at which we’d be moderately compelled to reject the null hypothesis. For
better or worse, personal feelings toward the conclusion that is being drawn by the
experimenter or by the company for whom the experiment is being formed can often sway
the conclusions of a hypothesis test, particularly in a case like this. Ultimately, this is a
judgment call for which there is no correct answer. I’d probably conclude that the evidence
wasn’t strong enough to reject the null hypothesis, and that Facility A had no greater
a proportion of repolished bearings within specs relative to Facility B.
And this wraps up our discussion of statistical inference for the difference in proportions
in two populations. We’ll move on to inferences about the difference in variances.