J&B
Chapter 8
Sections 2.1, 4.3, 5.3
= P(Type I error)
= P(Reject H0 | H0 true)
= P(Type II error)
= P(Retain H0 | H0 false)
Power is the probability of NOT
making a Type II error.
zobs
=9
n = 25
71.5 75
=
1.94
9 25
p-value = P( Z - 1.94)
= 0.0262
Reject H0 at the 5% level.
We concluded that there was evidence that
the new additive reduced the average
drying time of the paint.
What would have happened if we had
obtained the same x of 71.5, but from a
different sample size?
Would it affect the conclusions?
e.g.
For n = 5:
zobs
71.5 75
=
0.870
9 5
e.g.
zobs
x 75
=
9 10000
75 - 1.645 * 0.09
75 - 0.148
74.85
Practical significance vs
Statistical significance
If a result is statistically significant, we
are saying that we are reasonably
confident that the actual population mean
is different from the hypothesized value.
That difference may or may not be of
interest or importance to us.
We need to decide what difference is
meaningful in terms of our experiment.
For the example:
We need to think in terms of what
difference in average drying time is
marketable.
For example, we might decide to market
the paint only if the decrease in average
drying time is more than 2 minutes. 12
Rule
Practical sig
(diff =2)
We want:
zobs
73 75
9 n
Statistical sig
= p-val 5%
1.645
73 75
1.645
9 n
2 n
1.645
9
9
n 1.645
= 7.4025
2
n ( 7.4025 )
54.80
Hence n 55 (as n is integer)
15
16
General result
If we are able to apply a z-test ( is known
and X is normal or approx normal) for testing
H0: = 0
versus H1: < 0
at the 5% level, we will reject H0 if:
x 0
1.645
where:
x 0 is the minimum difference
required for action;
zcrit comes from the tolerance (how
often we are prepared to be wrong when
there is no difference);
needs to be known (or estimated from
past work).
17
Solution
So, once we have decided on what values
for these are to be used, we solve the
equation to obtain the minimum sample
size that will achieve this.
Solve for n:
x 0
1.645
n z
x 0
18
In designing an experiment
We should plan what sample size would be
required to achieve significance, before
setting up the experiment.
Requirements:
1. An idea of what practical significance is
desired - i.e. the minimum difference
x 0 that would be meaningful.
2. An idea of the likely value of chance
variation (from previous experiments,
the literature, etc).
3. Use of the appropriate formula to
determine the minimum sample size
required to achieve significance.
Warning: We may observe sample
statistics that are entirely different from
what we are hoping/expecting to observe. 20
Power of a test
For any test of significance, there are two possible
correct outcomes, and two incorrect outcomes.
Recall from Topic 6:
H0 true
H0 false
H0 retained
Type II
ERROR
H0 rejected
Type I
ERROR
21
= 9 and n = 25
23
25
reject H0 if X 72.039
not reject H0 if X > 72.039
= P X 72.039 = 70
X 72.039 70
= P
= 70
n
9
25
2.039
= PZ
1.8
P ( Z 1.133)
0.8708
26
27
Reject H0
87%
5%
28
Reject H0
87%
5%
the true mean is greater than 70 (but still less than 75)?
29
Other values of :
When = 71:
= 71
= P
<
n
9
25
P ( Z < 0.577 )
0.7190
= 73
= P
<
n
9
25
P ( Z < 0.534 )
0.2946
When = 65:
Power = P ( X < 72.039 | = 65 )
X 72.039 65
= 65
= P
<
n
9
25
P ( Z < 3.911)
1.0000
(close enough)
When = 74.9:
Power = P ( X < 72.039 | = 74.9 )
X 72.039 74.9
= P
<
= 74.9
n
9
25
P ( Z < 1.589 )
0.0559
31
- 75 Power
65
-10 1.000
70
-5 0.871
71
-4 0.719
73
-2 0.295
74.9
-0.1 0.056
32
Using Minitab:
MTB > Stat > Power and Sample Size
> 1-Sample Z..
33
Power curve
Plot of Power versus difference = x 0
35
36
Sample Target
Size
Power Actual Power
3
0.10
0.103843
14
0.20
0.208002
26
0.30
0.304417
40
0.40
0.405399
55
0.50
0.501273
73
0.60
0.600180
96
0.70
0.702800
126
0.80
0.802222
174
0.90
0.900859
220
0.95
0.950655
320
0.99
0.990107
37
To get the graph, cut and paste these values for Size
and Actual Power into columns in the worksheet, then
do Graph > Scatterplot > With Connect Line
38
Different Example:
z-test power curve for different
[Note: this chart was NOT created in Minitab]
1.00
0.90
0.80
Power (1 - )
0.70
H0: = 120
Ha: > 120
0.60
0.50
0.40
0.30
0.20
= 0.10
= 0.05
0.10
= 0.01
0.00
118
119
120
121
122
123
124
125
126
127
128
True Value of
H0: = 120
Ha: > 120
= 10
Power (1 - )
0.70
0.60
0.50
0.40
0.30
n = 45
0.20
n = 90
0.10
n = 180
n = 360
0.00
118
119
120
121
122
123
124
125
126
127
128
True Value of
41
X
+1.96
n
OR
X 500
+1.96
4 25
X 500 + 1.96
4
25
X 501.568
42
X 498.432 499
= P
<
= 499
n
4
25
X 501.568 499
= 499
+P
>
n
4 25
Reject H0
Reject H0
43
Using Minitab
Specify a two tailed
alternative under
Options
( 0.05)
0.3 0.7
1.645
There is no cc of
1/2n here, as we
are trying to find n
... and the cc
would overlycomplicate matters
0.3 0.7
n 1.645
15.07767
0.05
n 15.07767 2
227.306
48
(1 )
We know that P approx ~ N ,
0.3 0.7
2
P %. N 0.3,
~ N 0.3, ( 0.03034885 )
228
0.25 0.75
2
P %. N 0.25,
~ N 0.25, ( 0.028677 )
228
49
Power = area to
the left of the blue
line at P = 0.25
50
0.23 0.77
2
P ~ N 0.23,
~
N
0.23,
0.02787031
(
)
228
CLT check:
51
= P
p
0.25 0.23
= 0.23
0.23 0.77
(1 )
228
n
= P ( Z 0.718 )
0.7642
Comparison p
0.25
0.23
Sample
Size
228
228
Power
0.501121
0.764392
53
54