br7ch09e - Web4students

Understandable Statistics
Seventh Edition
By Brase and Brase
Prepared by: Lynn Smith
Gloucester County College
Chapter Nine Part 5
(Section 9.7)
Hypothesis Testing
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
1
Independent Sampling
Distributions
There is no relationship whatsoever
between specific values of the two
distributions.
Example: comparison of the
incomes of individuals from two
groups.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
2
Testing the Differences of
Means for Large, Independent
Samples
• Let x1 and x2 have normal distributions
with means 1 and 2 and standard
deviations 1 and 2 respectively.
• Take independent random samples of size
n1 and n2 from each distribution.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
3
The n the variablex1  x 2
hasthefollowingcharacte ri
stics:
1. A normal distribution.
2. Mean   1   2
3. Standard deviation 
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .

2
1
n1


2
2
n2
4
If both n1 and n2 are 30 or
larger
The Central Limit Theorem can be
applied even if the original
distributions are not normal.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
5
When testing the difference of
means
The null hypothesis usually
indicates that there is no difference
between the means.
H0: 1– 2 = 0
or, equivalently
H0: 1= 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
6
Left-Tailed Test
H0: 1= 2
H1: 1< 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
7
Right-Tailed Test
H0: 1= 2
H1: 1 > 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
8
Two-Tailed Test
H0: 1= 2
H1: 1  2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
9
Use the Critical Values for the
Normal Distribution
 = 0.05
 = 0.01
Critical z for
Left-Tailed Test
 1.645
 2.33
Critical z for
Right-Tailed Test
1.645
2.33
Critical z for
Two-Tailed Test
 1.96
 2.58
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
10
To convert the sample x1  x 2 value
to a z value, use :
z
( x1  x 2 )  (  1   2 )

2
1
n1
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .


2
2
n2
11
A college professor wishes to
determine (at 0.05 level of
significance) if there is a
difference in the final exam
results between the two groups
of students. One group studies
Calculus in the traditional
classroom setting; the other is
taught via distance learning.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
12
Sample exam results:
x
88
Distance
Learning
85

3.3
4.1
n
31
30
Traditional
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
13
We wish to determine if the
observed difference in exam results
(88 versus 85) is significant.
H0: 1= 2
H1: 1  2
Using a two-tailed test, the critical z values
are  1.96 for  = 0.05.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
14
Compute the sample test
statistic
x1  x2  88  85  3
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
15
Convert the test statistic to a z
value
z
( x1  x 2 )  (  1   2 )
 12
n1

 22
n2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .

30

3
.
14
3.3 2 4.12

31
30
16
Since 3.14 > 1.96
We reject the null hypothesis - the
statement that there was no
difference between the two groups.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
17
We conclude that the exam
results for the distance learning
class are significantly different
from those for the traditional
group at 5% level of
significance.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
18
P Value Approach
• To find the P value for the sample statistic
of the difference in the means, use the
corresponding z value, z = 3.14.
• Since we are working with a two-tailed
test, add the area to the right of z = 3.14
to the area to the left of z = – 3.14.
• P value = 2(0.0008) = 0.0016
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
19
P value = 0.0016
We would reject H0
for any   0.0016.
We, therefore reject H0
for  = 0.05.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
20
Inferences about the
Differences of Two Means of
Small Independent Samples
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
21
Assumptions
• Independent random samples are drawn
from two populations with means 1 and
2.
• The parent populations have normal
distributions.
• The standard deviations for the
populations (1 and 2) are equal.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
22
Best Estimate of the Common
or Pooled Standard Deviation
for Two Populations
( n1  1) s  ( n2  1) s
s
n1  n2  2
2
1
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
2
2
23
When testing the difference of
means
The null hypothesis usually
indicates that there is no difference
between the means.
H0: 1– 2 = 0
or, equivalently
H0: 1= 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
24
Left-Tailed Test
H0: 1= 2
H1: 1< 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
25
Right-Tailed Test
H0: 1= 2
H1: 1 > 2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
26
Two-Tailed Test
H0: 1= 2
H1: 1  2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
27
To Test the Hypothesis Use the t
Statistic
x1  x 2
t
with d.f.  n1  n 2  2
1 1
s

n1 n2
where s  the pooled standard deviation
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
28
The Pooled Standard Deviation
( n1  1) s  ( n2  1) s
s
n1  n2  2
2
1
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
2
2
29
Test
H0: 1 = 2
Against H1: 1 > 2
Use a 1% Level of Significance.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
30
Sample Data
Population 1 Population 2
x
17.3
16.1
s
1.6
1.5
n
8
9
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
31
Degrees of Freedom
d.f. = n1 + n2 – 2 =
8 + 9 – 2 = 15
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
32
For a Right-Tailed Test at 1%
Level of Significance and d.f. = 15
Use the column headed by  = 0.010
The critical t value is
t = 2.602.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
33
Compute the Test Statistic x1  x2
x1  x2  17.3  16.1  1.2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
34
Pooled Standard Deviation
( n1  1) s  ( n2  1) s
s

n1  n2  2
2
1
2
2
(8  1)1.6  (9  1)1.5
 1.55
892
2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
2
35
Convert the Test Statistic x1  x 2
to a t Value
x1  x2  17.3  16.1  1.2
x1  x 2
1 .2
t

 1.593
1 1
1 1
s

1.55 
n1 n2
8 9
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
36
Critical t Value = 2.602
2.602
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
37
Test Statistic  1.593
1.593 2.602
Do not reject H0.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
38
P Value Approach
To test
H0: 1 = 2
Against H1: 1 > 2
t value = 1.593, d.f. = 15
• For a right-tailed test, use the column
headed by .
• For d.f. = 15, t = 1.593 falls between t =
1.517 and t = 1.753.
• We conclude that 0.050 < P < 0.075.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
39
Conclusion: 0.050 < P < 0.075
We reject H0 only for   P.
We could not reject H0 for  = 0.01.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
40
Tests for Differences of
Proportions
• We will draw independent random
samples of size n1 and n2 from two
binomial distributions.
• For large values of n1 and n2,, the
distribution of sample differences in
proportions of successes will be
approximately normally distributed.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
41
Symbols Used
r1 and r2 = number of successes from the
first and second samples
p1 and p2 = probability of success on each
trial from the first and second binomial
distributions
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
42
For large values of n1 and n2:
The distribution of sample differences
r1 r2
pˆ 1  pˆ 2   is approximately normal with
n1 n2
mean    p1  p2
and standard deviation   
p1 q1
n1
p2 q2

n2
where q1  1  p1 and q 2  1  p2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
43
The Null Hypothesis
p1 = p2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
44
The proportions p1 and p2
are unknown and must be
estimated
Best (pooled)estimate  " p hat" 
r1  r2
pˆ 
n1  n2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
45
Critical Values for Tests
Involving a Difference of Two
Proportions (Large Samples)
 = 0.05
 = 0.01
Critical z for
Left-Tailed Test
 1.645
 2.33
Critical z for
Right-Tailed Test
1.645
2.33
Critical z for
Two-Tailed Test
 1.96
 2.58
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
46
“Large” Samples
All of the following are larger than
five:
n1 pˆ , n1qˆ , n2 pˆ , n2 qˆ
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
47
Sample Test Statistic
z
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
pˆ 1  pˆ 2
pˆ qˆ pˆ qˆ

n1 n2
48
A college is attempting to
determine whether a reminder
phone call encourages students
to participate in early
registration. A group of 1200
students was divided into two
groups. One received a
reminder phone call; the other
did not.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
49
The data:
Reminder
No Reminder
n
600
600
Registered
early
475
452
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
50
Use a 5% level of significance
to test the claim that the
reminder phone calls increased
participation in early
registration.
• Let p1 = proportion from the first group
(reminder) who registered early.
• Let p2 = proportion from the second
group (no reminder) who registered
early.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
51
The null hypothesis is that
there is no difference in
proportions.
H0: p1 = p2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
52
The alternate hypothesis is that
the reminders improve
participation rate.
H1: p1 > p2
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
53
H1: p1 > p2
• Use a right-tailed test.
• For 5% level of significance, the critical z
value = 1.645.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
54
For the Reminder group,
r1 = 475, n1 = 600.
r1 475
pˆ 1  
 0.792
n1 600
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
55
For the No Reminder group,
r1 = 452, n1 = 600.
r2 452
pˆ 2  
 0.753
n2 600
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
56
The Sample Statistic
pˆ 1  pˆ 2  0.792  0.753  0.039
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
57
The pooled estimates of
proportion
r1  r2 475  452
pˆ 

 0.7725
n1  n2 600  600
qˆ  1  pˆ  0.2275
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
58
Convert the test statistic to a z
value:
z

pˆ 1  pˆ 2
pˆ qˆ pˆ qˆ

n1 n2
0.039
 1.61
.7725 (.2275) .7725 (.2275)

600
600
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
59
Critical z Value = 1.645
1.645
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
60
Test statistic = z = 1.61
1.61 1.645
Do not reject the null hypothesis.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
61
Conclusion
At 5% level of significance, we cannot
reject the claim that the proportions (of
students who register early) are equal.
We conclude that the reminder phone
calls do not make a significant difference
in the number of students who
participate in early registration.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
62
P Value Approach
• For a right-tailed test, the value of P is
the area in the right tail of the
distribution, larger than z = 1.61.
• From Table 5a, we find the P value.
• P = 1.000 – 0.9463= 0.0537
• We would reject H0 only for   0.0537.
• We cannot reject H0 for  = 0.05.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved .
63