Вы находитесь на странице: 1из 39

Chapter 9

Testing the Difference


Between Two Means,
Two Proportions, and
Two Variances

Copyright © 2012 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1
Testing the Difference Between Two CHAPTER
Means, Two Proportions, and Two
Variances
Outline
9
9-1 Testing the Difference Between Two Means:
Using the z Test
9-2 Testing the Difference Between Two Means
of Independent Samples: Using the t Test
9-3 Testing the Difference Between Two Means:
Dependent Samples
9-4 Testing the Difference Between Proportions
9-5 Testing the Difference Between Two
Variances
Testing the Difference Between Two CHAPTER
Means, Two Proportions, and Two
Variances
Objectives
9
1 Test the difference between sample means, using
the z test.
2 Test the difference between two means for
independent samples, using the t test.
3 Test the difference between two means for
dependent samples.
4 Test the difference between two proportions.
5 Test the difference between two variances or
standard deviations.
Introduction
 Chapter 8- we used hypothesis testing on
a statistic to see how it compared to the
proposed parameter.
 Chapter 9- the basic hypothesis testing
steps are the same, but we’ll be testing
two sample means or proportions to see
how they compare with each other.
 Example- different brands of products.

Bluman, Chapter 9 4
9.1 Testing the Difference Between
Two Means: Using the z Test
 Used when it is desired to compare the
means of two groups of data.
 The null will always be that there is no
difference between the two means.
 The alternative will always be that there is
a difference between the two means (can
be two-tailed, right-tailed, or left-tailed).

Bluman, Chapter 9 5
9.1 Testing the Difference Between
Two Means: Using the z Test
Assumptions:
1. The samples must be independent of each
other. That is, there can be no relationship
between the subjects in each sample.
2. The standard deviations of both
populations must be known, and if the
sample sizes are less than 30, the
populations must be normally or
approximately normally distributed.

Bluman Chapter 9 6
Hypothesis Testing Situations in
the Comparison of Means

Bluman Chapter 9 7
Hypothesis Testing Situations in
the Comparison of Means

Bluman Chapter 9 8
Testing the Difference Between
Two Means: Large Samples
Formula for the z test for comparing two means from
independent populations

z=
( X 1 ) (
- X 2 - m1 - m 2 )
s 12 s 22
+ Due to the null,
m1 - m2 will always = 0.
n1 n2 Yay!

Bluman Chapter 9 9
Chapter 9
Testing the Difference Between
Two Means, Two Proportions,
and Two Variances

Section 9-1
Example 9-1
Page #475

Bluman Chapter 9 10
Example 9-1: Hotel Room Cost
A survey found that the average hotel room rate in New
Orleans is $88.42 and the average room rate in Phoenix is
$80.61. Assume that the data were obtained from two
samples of 50 hotels each and that the standard deviations
of the populations are $5.62 and $4.83, respectively. At
α = 0.05, can it be concluded that there is a significant
difference in the rates?

Bluman, Chapter 9 11
Example 9-1: Hotel Room Cost
A survey found that the average hotel room rate in New
Orleans is $88.42 and the average room rate in Phoenix is
$80.61. Assume that the data were obtained from two
samples of 50 hotels each and that the standard
deviations of the populations are $5.62 and $4.83,
respectively. At α = 0.05, can it be concluded that there is
a significant difference in the rates?

Step 1: State the hypotheses and identify the claim.


H0: μ1 = μ2 and H1: μ1  μ2 (claim)

Step 2: Find the critical value.


The critical value is z = ±1.96.

Bluman Chapter 9 12
Example 9-1: Hotel Room Cost
A survey found that the average hotel room rate in New
Orleans is $88.42 and the average room rate in Phoenix is
$80.61. Assume that the data were obtained from two
samples of 50 hotels each and that the standard
deviations of the populations are $5.62 and $4.83,
respectively. At α = 0.05, can it be concluded that there is
a significant difference in the rates?

Step 3: Compute the test value.

z
 X 1  X 2    1  2 
 12  22

n1 n2

Bluman Chapter 9 13
Example 9-1: Hotel Room Cost
A survey found that the average hotel room rate in New
Orleans is $88.42 and the average room rate in Phoenix is
$80.61. Assume that the data were obtained from two
samples of 50 hotels each and that the standard
deviations of the populations are $5.62 and $4.83,
respectively. At α = 0.05, can it be concluded that there is
a significant difference in the rates?

Step 3: Compute the test value.

z
 88.42  80.61   0 
 7.45
5.622 4.832

50 50

Bluman Chapter 9 14
Example 9-1: Hotel Room Cost
Step 4: Make the decision.
Reject the null hypothesis at α = 0.05, since
7.45 > 1.96.

Step 5: Summarize the results.


There is enough evidence to support the claim
that the means are not equal. Hence, there is a
significant difference in the rates.

Bluman Chapter 9 15
Practice
 Page 480, #6.

Bluman, Chapter 9 16
Chapter 9
Testing the Difference
Between Two Means, Two
Proportions, and Two
Variances
Section 9-1
Example 9-2
Page #476

Bluman Chapter 9 17
Example 9-2: College Sports Offerings
A researcher hypothesizes that the average number of
sports that colleges offer for males is greater than the
average number of sports that colleges offer for females.
A sample of the number of sports offered by colleges is
shown. At α = 0.10, is there enough evidence to support
the claim? Assume 1 and 2 = 3.3.

Bluman Chapter 9 18
Example 9-2: College Sports Offerings
Step 1: State the hypotheses and identify the claim.
H0: μ1 = μ2 and H1: μ1 > μ2 (claim)

Step 2: Compute the test value.

For the males: X 1 = 8.6 and 1 = 3.3


For the females: X 2 = 7.9 and 2 = 3.3
Substitute in the formula.

z
 X 1  X 2    1  2 

 8.6  7.9    0 
 1.06
 12  22 3.32 3.32
 
n1 n2 50 50

Bluman Chapter 9 19
Example 9-2: College Sports Offerings
Step 3: Find the P-value.
For z = 1.06, the area is 0.8554.
The P-value is 1.0000 - 0.8554 = 0.1446.
Step 4: Make the decision.
Do not reject the null hypothesis.

Step 5: Summarize the results.


There is not enough evidence to support the
claim that colleges offer more sports for males
than they do for females.
Bluman Chapter 9 20
Confidence Intervals for the
Difference Between Two Means
Formula for the z confidence interval for the difference
between two means from independent populations

 12  22
X 1  X 2   z 2
n1

n2
  1  2 

 12  22
  X 1  X 2   z 2 
n1 n2

Bluman Chapter 9 21
Chapter 9
Testing the Difference Between
Two Means, Two Proportions,
and Two Variances

Section 9-1
Example 9-3
Page #478

Bluman Chapter 9 22
Example 9-3: Confidence Intervals
Find the 95% confidence interval for the difference
between the means for the data in Example 9–1.
 12  22
X 1  X 2   z 2
n1

n2
 1  2

 12  22
  X 1  X 2   z 2 
n1 n2

5.622 4.832
88.42  80.61  1.96   1  2
50 50
5.622 4.832
  88.42  80.61  1.96 
50 50
7.81  2.05  1  2  7.81  2.05

5.76  1  2  9.86

Bluman Chapter 9 23
9.4 Testing the Difference Between
Proportions
 Occasionally, we want to compare the
proportions of two groups of data that
meet a certain characteristic.
 Examples:
 Is there a difference in % of Mac owners who are in
education VS % of Mac owners who aren’t?
 Is prop. of males in 20’s who exercise smaller/bigger
that prop. of females in 20’s who exercise?

Bluman, Chapter 9 24
9.4 Testing the Difference
Between Proportions
 We have the same 5 steps of the
traditional hypothesis testing.
 The null is still that there is no difference in
the proportions and the alternative is still
that there is a difference.

Bluman, Chapter 9 25
9.4 Testing the Difference Between
Proportions
z=
( p̂ - p̂ ) - ( p - p )
1 2 1 2

æ1 1ö
pqç + ÷ p1 - p2 will = 0.
è n1 n2 ø
where

X1 + X 2 X1
p= p̂1 =
n1 + n2 n1
X2
q = 1- p p̂2 =
n2
Bluman Chapter 9 26
Chapter 9
Testing the Difference Between
Two Means, Two Proportions,
and Two Variances

Section 9-4
Example 9-9
Page #505

Bluman Chapter 9 27
Example 9-9: Vaccination Rates
In the nursing home study mentioned in the chapter-
opening Statistics Today, the researchers found that 12 out
of 34 small nursing homes had a resident vaccination rate
of less than 80%, while 17 out of 24 large nursing homes
had a vaccination rate of less than 80%. At α = 0.05, test
the claim that there is no difference in the proportions of the
small and large nursing homes with a resident vaccination
rate of less than 80%.

Bluman, Chapter 9 28
Example 9-9: Vaccination Rates
In the nursing home study mentioned in the chapter-
opening Statistics Today, the researchers found that 12
out of 34 small nursing homes had a resident vaccination
rate of less than 80%, while 17 out of 24 large nursing
homes had a vaccination rate of less than 80%. At
α = 0.05, test the claim that there is no difference in the
proportions of the small and large nursing homes with a
resident vaccination rate of less than 80%.
X 1 12 X 2 17
pˆ1    0.35 and pˆ 2    0.71
n1 34 n2 24
X 1  X 2 12  17 29
p    0.5, q  0.5
n1  n2 34  24 58

Bluman Chapter 9 29
Example 9-9: Vaccination Rates
Step 1: State the hypotheses and identify the claim.
H0: p1 – p2 = 0 (claim) and H1: p1 – p2  0

Step 2: Find the critical value.


Since α = 0.05, the critical values are –1.96
and 1.96.

Step 3: Compute the test value.

z
 pˆ1  pˆ 2    p1  p2   0.35  0.71   0 

1 1   1 1 
pq    0.5 0.5   
 n1 n2   34 24 
 2.7

Bluman Chapter 9 30
Example 9-9: Vaccination Rates
Step 4: Make the decision.
Reject the null hypothesis.

Step 5: Summarize the results.


There is enough evidence to reject the claim
that there is no difference in the proportions of
small and large nursing homes with a resident
vaccination rate of less than 80%.
Bluman Chapter 9 31
Chapter 9
Testing the Difference Between
Two Means, Two Proportions,
and Two Variances

Section 9-4
Example 9-10
Page #507

Bluman Chapter 9 32
Example 9-10: Texting While Driving
A survey of 1000 drivers this year showed that 29% of the
people send text messages while driving. Last year a
survey of 1000 drivers showed that 17% of those send
text messages while driving.

At α = 0.01, can it be concluded that there has been an


increase in the number of drivers who text while driving?

Bluman Chapter 9 33
Example 9-10: Texting While Driving
Step 1: State the hypotheses and identify the claim.
H0: p1 = p2 and H1: p1 > p2 (claim)

Step 2: Find the critical value.


Since α = 0.01, the critical value is 2.33.

Step 3: Compute the test value.

Bluman Chapter 9 34
Example 9-10: Texting While Driving
Step 4: Make the decision.
Reject the null hypothesis since 6.38 > 2.33.

Step 5: Summarize the results.


There is enough evidence to say that the
proportion of drivers who send text messages is
larger today than it was last year.

Bluman Chapter 9 35
Confidence Interval for the
Difference Between Proportions
Formula for the confidence interval for the difference
between proportions

pˆ1qˆ1 pˆ 2 qˆ2
 pˆ1  pˆ 2   z 2   p1  p2
n1 n2
pˆ1qˆ1 pˆ 2 qˆ2
  pˆ1  pˆ 2   z 2 
n1 n2

Bluman Chapter 9 36
Chapter 9
Testing the Difference Between
Two Means, Two Proportions,
and Two Variances

Section 9-4
Example 9-11
Page #508

Bluman Chapter 9 37
Example 9-11: Confidence Intervals
Find the 95% confidence interval for the difference of the
proportions for the data in Example 9–9.
X 1 12
pˆ1    0.35 and qˆ1  1  0.35  0.65
n1 34
X 2 17
pˆ 2    0.71 and qˆ2  1  0.71  0.29
n2 24

pˆ1qˆ1 pˆ 2 qˆ2
 pˆ1  pˆ 2   z 2   p1  p2
n1 n2
pˆ1qˆ1 pˆ 2 qˆ2
  pˆ1  pˆ 2   z 2 
n1 n2

Bluman Chapter 9 38
Example 9-11: Confidence Intervals
Find the 95% confidence interval for the difference of the
proportions for the data in Example 9–9.
 0.35 0.65   0.71 0.29   p
 0.35  0.71  1.96 1  p2
34 24

  0.35  0.71  1.96


 0.35 0.65   0.71 0.29 
34 24

0.36  0.242  p1  p2  0.36  0.242

0.602  p1  p2  0.118
Since 0 is not contained in the interval, the decision is
to reject the null hypothesis H0: p1 = p2.

Bluman Chapter 9 39

Вам также может понравиться