Independent Samples: Comparing Proportions Lecture 40 Section 11.5

advertisement
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Independent Samples:
Comparing Proportions
Lecture 40
Section 11.5
Robb T. Koether
Hampden-Sydney College
Tue, Nov 11, 2008
Outline
Independent
Samples:
Comparing
Proportions
1
Homework Review
2
Introduction
Robb T.
Koether
3
Comparing Proportions
4
Example - The Gender Gap
5
The Hypothesis Testing for p1 − p2
The Sampling Distribution of p̂1 − p̂2
The Test Statistic
The Pooled Estimate of p
6
The Rest of the Hypothesis-Testing Procedure
7
Hypothesis Testing on the TI-83
8
Confidence Intervals for p1 − p2
9
Confidence Intervals for p1 − p2 on the TI-83
10
Assignment
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Exercise 11.25, page 714.
A sensory psychologist wants to study the effect of
temperature on the sense of touch.
For the experiment there are two groups of randomly
and independently selected subjects.
Group 1 places their right index finger in water at 81
degrees (warm), while Group 2 places their right index
finger in water at 40 degrees (cold).
The sensitivity of the right index finger to slight
pressure variations is then measured, with higher
scores indicating greater sensitivity.
It can be assumed that for each temperature condition,
the sensitivity measurements are normally distributed
with equal population standard deviations.
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Exercise 11.25, page 714.
The data are summarized below:
Group
1 = warm
2 = cold
Sample Size
12
8
Sample Mean
11
7
Sample SD
2.2
2
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Exercise 11.25, page 714.
(a) Give an estimate of the common population standard
deviation.
(b) Give a 90% confidence interval for the difference in the
mean population sensitivity scores µ1 − µ2 .
(c) True or false? If this method were repeated many times,
the difference in the mean population sensitivity scores
µ1 − µ2 would fall in the interval you just computed in
part (b) 90% of the time.
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Solution
(a) Find the pooled estimate for σ:
r
11 · 2.22 + 7 · 22
sp =
18
= 2.124.
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Solution
(b) For the 90% confidence interval, we should use the
formula
r
1
1
(x1 − x2 ) ± t0.05,18 sp
+ .
n1 n2
Use the t-table to look up t0.05,18 and get 1.734.
r
1
1
+
95%C.I. = (11 − 7) ± (1.734)(2.124)
12 8
= 4 ± (1.734)(2.124)(0.4564)
= 4 ± 0.8895
Homework Review
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Solution
(c) False. This interval is just one fixed interval. It could be
way off in which case other computed differences might
almost never lie in it.
The correct interpretation is that if we computed many
such intervals, about 90% of them would contain the
one true difference.
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In the days before the recent election, news reports
said that the gap between McCain’s poll numbers and
Obama’s poll numbers was closing.
Real Clear Politics daily poll averages showed the
following:
Oct 28 Oct 29
Obama 50.5% 49.9%
McCain 43.8% 43.9%
Does that indicate that the gap is closing?
Or does it simply exhibit the randomness of the
sampling process?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In the days before the recent election, news reports
said that the gap between McCain’s poll numbers and
Obama’s poll numbers was closing.
Real Clear Politics daily poll averages showed the
following:
Oct 28 Oct 29
Obama 50.5% 49.9%
McCain 43.8% 43.9%
Does that indicate that the gap is closing?
Or does it simply exhibit the randomness of the
sampling process?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In the days before the recent election, news reports
said that the gap between McCain’s poll numbers and
Obama’s poll numbers was closing.
Real Clear Politics daily poll averages showed the
following:
Oct 28 Oct 29
Obama 50.5% 49.9%
McCain 43.8% 43.9%
Does that indicate that the gap is closing?
Or does it simply exhibit the randomness of the
sampling process?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In the days before the recent election, news reports
said that the gap between McCain’s poll numbers and
Obama’s poll numbers was closing.
Real Clear Politics daily poll averages showed the
following:
Oct 28 Oct 29
Obama 50.5% 49.9%
McCain 43.8% 43.9%
Does that indicate that the gap is closing?
Or does it simply exhibit the randomness of the
sampling process?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Introduction
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
In this situation, we have two populations:
The population of voters on Oct 28, 2008.
The population of voters on Oct 29, 2008.
Let p1 = proportion who favored Obama on Oct 28,
2008.
Let p2 = proportion who favored Obama on Oct 29,
2008.
The question is, is p2 < p1 ?
Or is p1 = p2 ?
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The “gender gap” refers to the difference between the
proportion of men who vote Republican and the
proportion of women who vote Republican.
The are a couple of ways to view this.
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
We could view this as two populations: one of all males
and one of all females.
Comparing
Proportions
Then measure the division between Democrat and
Republican in each population.
Example - The
Gender Gap
Let p1 = proportion of Republicans among males.
The
Hypothesis
Testing for
p1 − p2
Let p2 = proportion of Republicans among females.
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
All people
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Males
Females
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Rep
(p1)
Rep
(p2)
Dem
Dem
Males
Females
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Or we could view this as one one population of
Democrats and another population of Republicans.
Comparing
Proportions
Then measure the division between male and female in
each population.
Example - The
Gender Gap
Let p1 = proportion of males among Republicans.
The
Hypothesis
Testing for
p1 − p2
Let p2 = proportion of males among Democrats.
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
All people
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Rep
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Dem
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Rep
Male
(p1)
Female
Dem
Male
(p2)
Female
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
The two methods are equivalent.
Comparing
Proportions
That is, it does not matter which way we do it.
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The Gender Gap
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Article
CNN Exit Polls
Test the hypothesis that a greater proportion of males
vote Republican than do females.
The Gender Gap
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Let p1 = proportion of men who voted for McCain.
Comparing
Proportions
Let p2 = proportion of women who voted for McCain.
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The Gender Gap
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
17,836 people were surveyed.
47% were male: 0.47 × 17836 = 8383 males.
53% were male: 0.53 × 17836 = 9453 males.
Among males, 48% voted for McCain.
Among females, 43% voted for McCain.
Hypothesis Testing Procedure
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Example (Testing hypotheses concerning p1 − p2 )
Homework
Review
(1) The hypotheses are
Introduction
Comparing
Proportions
H0 : p1 = p2
Example - The
Gender Gap
H1 : p1 > p2
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
(2) The significance level is α = 0.05.
Hypothesis Testing Procedure
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
What is the test statistic?
That depends on the sampling distribution of p̂1 − p̂2 .
Here we go again...
The Sampling Distribution of p̂1 − p̂2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
If the sample sizes are large enough, then p̂1 is
N(p1 , σp̂1 ), where
s
p1 (1 − p1 )
σp̂1 =
n1
and p̂2 is N(p2 , σp̂2 ), where
s
σp̂2 =
p2 (1 − p2 )
n2
The Sampling Distribution of p̂1 − p̂2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The sample sizes will be large enough if
n1 p1 ≥ 5, and n1 (1 − p1 ) ≥ 5, and
n2 p2 ≥ 5, and n2 (1 − p2 ) ≥ 5.
The Sampling Distribution of p̂1 − p̂2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Therefore, p̂1 − p̂2 is normal with
µp̂1 −p̂2
σp̂1 −p̂2
= µpˆ1 − µpˆ2 = p1 − p2
s
q
p1 (1 − p1 ) p2 (1 − p2 )
=
σp̂21 + σp̂21 =
+
n1
n2
The Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Therefore, the test statistic would be
Introduction
Z=q
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
except that...
(p̂1 − p̂2 ) − 0
p1 (1−p1 )
n1
+
p2 (1−p2 )
n2
The Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
...we do not know the values of p1 and p2 .
Homework
Review
We will use p̂1 and p̂2 to approximate p1 and p2 .
Introduction
Therefore, the test statistic would be
Comparing
Proportions
Z=q
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
except that...
(p̂1 − p̂2 ) − 0
p̂1 (1−p̂1 )
n1
+
p̂2 (1−p̂2 )
n2
Pooled Estimate of p
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
...we can do better by pooling the data.
Under the assumption of the null hypothesis (p1 = p2 ),
p̂1 and p̂2 are both estimators of a common value,
which we will call p.
Pooled Estimate of p
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The pooled estimate is the proportion that we would get
if we pooled the two samples together into one.
We would have a total count of x1 + x2 members out of
a sample of n1 + n2 , for a pooled proportion of
p̂ =
x1 + x2
.
n1 + n2
The Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
This leads to a better estimator of the standard
deviation of p̂1 − p̂2 .
s
1
1
σp̂1 −p̂2 = p̂(1 − p̂)
+
.
n1 n2
The Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Example (Testing hypotheses concerning p1 − p2 )
(3) The test statistic is
Introduction
Z=r
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
(p̂1 − p̂2 ) − 0
,
1
1
p̂(1 − p̂) n1 + n2
where
p̂ =
x1 + x2
.
n1 + n2
The Gender Gap
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Example (Testing hypotheses concerning p1 − p2 )
Now we may compute the value of the test statistic.
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
(4)
Each sample contains 8918 members.
48% of the males is 0.48 × 8383 = 4024.
43% of the females is 0.43 × 9453 = 4065.
The pooled estimate for p is
p̂ =
4024 + 4065
8089
=
= 0.4535.
8383 + 9453
17836
The Value of the Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Example (Testing hypotheses concerning p1 − p2 )
(4) Then
s
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
σp̂1 −p̂2 =
(0.4535)(0.5465)
1
1
+
8383 9453
= 0.007469.
Now compute z:
z=
0.48 − 0.43
0.05
=
= 6.695.
0.007469
0.007469
The Value of the Test Statistic
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Example (Testing hypotheses concerning p1 − p2 )
(5) Compute the p-value:
P(Z > 6.695) = normalcdf(6.695,E99)
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
= 1.088 × 10−11 .
(6) Reject H0 .
(7) A greater proportion of males than females vote
Republican.
TI-83 - Testing Hypotheses Concerning p1 − p2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
TI-83 Testing Hypotheses Concerning p1 − p2
Press STAT > TESTS > 2-PropZTest...
Enter x1
Enter n1
Enter x2
Enter n2
Choose the correct alternative hypothesis.
Select Calculate and press ENTER.
TI-83 - Testing Hypotheses Concerning p1 − p2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
TI-83 Testing Hypotheses Concerning p1 − p2
A window appears with the following information.
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The title.
The alternative hypothesis.
The value of the test statistic z.
The p-value.
p̂1 .
p̂2 .
The pooled estimate p̂.
n1 .
n2 .
Practice
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Practice
According to the same web page, of the 17,836 people
surveyed,
29% were aged 30 - 44.
37% were aged 45 - 64.
Furthermore,
46% of those aged 30 - 44 voted for McCain.
49% of those aged 45 - 64 voted for McCain.
Test the claim at the 1% significance level that a greater
proportion of those aged 45 - 64 than those aged 30 44 voted for McCain.
Confidence Intervals for p1 − p2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
The formula for a confidence interval for p1 − p2 is
s
p̂1 (1 − p̂1 ) p̂2 (1 − p̂2 )
(p̂1 − p̂2 ) ± zα/2
+
.
n1
n2
Note that we do not use the pooled estimate for p̂
because we are not assuming that p1 = p2 .
TI-83 - Confidence Intervals for p1 − p2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
To find a confidence interval for p̂1 − p̂2 on the TI-83, do
the following.
Press STAT > TESTS > 2-PropZInt...
Enter x1
Enter n1
Enter x2
Enter n2
The confidence level.
Select Calculate and press ENTER.
TI-83 - Confidence Intervals for p1 − p2
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
A window appears with the following information.
The title.
The confidence interval.
p̂1 .
p̂2 .
n1 .
n2 .
Example
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Find a 95% confidence interval for the difference
between the proportions of whites and blacks who
believe that Mayor Wilder is doing a good or excellent
job.
Assignment
Independent
Samples:
Comparing
Proportions
Robb T.
Koether
Homework
Review
Introduction
Comparing
Proportions
Example - The
Gender Gap
The
Hypothesis
Testing for
p1 − p2
The Sampling
Distribution of
p̂1 − p̂2
The Test Statistic
The Pooled Estimate
of p
The Rest of
the
Hypothesis-
Homework
Read Section 11.5, pages 718 - 724.
Let’s Do It! 11.8, 11.9.
Exercises 34(omit e), 35, page 725.
Chapter Review 45(e), 46, 48(omit d), 50, 51(omit f),
52, 54 - 56, page 728.
Download