Experimental Design and ANOVA Guide
Experimental Design and ANOVA Guide
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 1
or duplicated, or posted to a publicly accessible website, in whole or in part.
An Introduction to Experimental Design
and Analysis of Variance
Statistical studies can be classified as being either
experimental or observational.
In an experimental study, one or more factors are
controlled so that data can be obtained about how the
factors influence the variables of interest.
In an observational study, no attempt is made to control
the factors.
Cause-and-effect relationships are easier to establish in
experimental studies than in observational studies.
Analysis of variance (ANOVA) can be used to analyze
the data obtained from experimental or observational
studies.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 2
or duplicated, or posted to a publicly accessible website, in whole or in part.
An Introduction to Experimental Design
and Analysis of Variance
In this chapter three types of experimental designs are
introduced.
a completely randomized design (完全隨機設計)
a randomized block design (隨機集區設計)
a factorial experiment (因子實驗)
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 3
or duplicated, or posted to a publicly accessible website, in whole or in part.
An Introduction to Experimental Design
and Analysis of Variance
A factor is a variable that the experimenter has selected
for investigation.
A treatment is a level of a factor.
Experimental units are the objects of interest in the
experiment.
A completely randomized design is an experimental
design in which the treatments are randomly assigned
to the experimental units.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 4
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance: A Conceptual Overview
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 5
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance: A Conceptual Overview
H0: µ1 = µ2 = µ3 = . . . = µk
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 6
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance: A Conceptual Overview
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 7
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance: A Conceptual Overview
x2 µ x1 x3
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 8
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance: A Conceptual Overview
x3 µ3 x1 µ1 µ2 x2
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 9
or duplicated, or posted to a publicly accessible website, in whole or in part.
Analysis of Variance and
the Completely Randomized Design
Between-Treatments Estimate of Population Variance
Within-Treatments Estimate of Population Variance
Comparing the Variance Estimates: The F Test
ANOVA Table
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 10
or duplicated, or posted to a publicly accessible website, in whole or in part.
Between-Treatments Estimate
of Population Variance σ 2
The estimate of σ 2 based on the variation of the
sample means is called the mean square due to
treatments (處理間均方) and is denoted by MSTR.
k
∑ j j
n (
j =1
x − x ) 2
MSTR =
k−1
Numerator is called
Denominator is the
the sum of squares due
degrees of freedom
to treatments (SSTR, 處
associated with SSTR
理間平方和)
File: Chemitech
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 11
or duplicated, or posted to a publicly accessible website, in whole or in part.
Within-Treatments Estimate
of Population Variance σ 2
The estimate of σ 2 based on the variation of the
sample observations within each sample is called the
mean square error (誤差均方) and is denoted by MSE.
∑ j j
( n
j =1
− 1) s 2
MSE =
nT − k
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 13
or duplicated, or posted to a publicly accessible website, in whole or in part.
Comparing the Variance Estimates: The F Test
Sampling Distribution
of MSTR/MSE
Reject H0
Do Not Reject H0 α
MSTR/MSE
Fα
Critical Value
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 14
or duplicated, or posted to a publicly accessible website, in whole or in part.
ANOVA Table
for a Completely Randomized Design
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 16
or duplicated, or posted to a publicly accessible website, in whole or in part.
ANOVA Table
for a Completely Randomized Design
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 17
or duplicated, or posted to a publicly accessible website, in whole or in part.
Test for the Equality of k Population Means
Hypotheses
H0: µ1 = µ2 = µ3 = . . . = µk
Ha: Not all population means are equal
Test Statistic
F = MSTR/MSE
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 18
or duplicated, or posted to a publicly accessible website, in whole or in part.
Test for the Equality of k Population Means
Rejection Rule
p-value Approach: Reject H0 if p-value < α
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 19
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Example: AutoShine, Inc.
AutoShine, Inc. is considering marketing a long-
lasting car wax. Three different waxes (Type 1, Type 2,
and Type 3) have been developed.
In order to test the durability of these waxes, 5 new
cars were waxed with Type 1, 5 with Type 2, and 5
with Type 3. Each car was then repeatedly run
through an automatic carwash until the wax coating
showed signs of deterioration.
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 20
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Example: AutoShine, Inc.
The number of times each car went through the
carwash before its wax deteriorated is shown on the
next slide. AutoShine, Inc. must decide which wax
to market. Are the three waxes equally effective?
Factor :
Treatments :
Experimental units :
Response variable :
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 21
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 23
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Hypotheses
H0: µ1 = µ2 = µ3
Ha: Not all the means are equal
where:
µ1 = mean number of washes using Type 1 wax
µ2 = mean number of washes using Type 2 wax
µ3 = mean number of washes using Type 3 wax
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 24
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Mean Square Between Treatments
Because the sample sizes are all equal:
x = ( x1 + x2 + x3 ) /3 = (29 + 30.4 + 30)/3 = 29.8
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 25
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Rejection Rule
p-Value Approach: Reject H0 if p-value < .05
Critical Value Approach: Reject H0 if F > 3.89
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 26
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
Test Statistic
F = MSTR/MSE = 2.60/2.77 = .939
Conclusion
The p-value is greater than .10, where F = 2.81.
(Excel provides a p-value of .42.)
Therefore, we cannot reject H0.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 27
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
A Completely Randomized Design
ANOVA Table
Total 38.4 14
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 28
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
Example: Reed Manufacturing
Janet Reed would like to know if there is any
significant difference in the mean number of hours
worked per week for the department managers at her
three manufacturing plants (in Buffalo, Pittsburgh,
and Detroit).
An F test will be conducted using α = .05.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 29
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
Example: Reed Manufacturing
A simple random sample of five managers from
each of the three plants was taken and the number of
hours worked by each manager in the previous week
is shown on the next slide.
Factor :
Treatments :
Experimental units :
Response variable :
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 30
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 32
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
p -Value and Critical Value Approaches
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 34
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
p -Value and Critical Value Approaches
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 35
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
ANOVA Table
Total 798 14
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 36
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
p –Value Approach
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 37
or duplicated, or posted to a publicly accessible website, in whole or in part.
Testing for the Equality of k Population Means:
An Observational Study
Critical Value Approach
4. Determine the critical value and rejection rule.
Based on an F distribution with 2 numerator
d.f. and 12 denominator d.f., F.05 = 3.89.
Reject H0 if F > 3.89
5. Determine whether to reject H0.
Because F = 9.55 > 3.89, we reject H0.
We have sufficient evidence to conclude that the
mean number of hours worked per week by
department managers is not the same at all 3 plant.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 38
or duplicated, or posted to a publicly accessible website, in whole or in part.
Case Problem: Wentworth Medical Center
1. 三個地區65歲以上長者的憂鬱程度是否有異?
2. 三個地區65歲以上患有慢性病長者的憂鬱程度是否有
異?
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 39
or duplicated, or posted to a publicly accessible website, in whole or in part.
Multiple Comparison Procedures
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 40
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Hypotheses
H 0 : µi = µ j
H a : µi ≠ µ j
Test Statistic
xi − x j
t=
MSE( 1 + 1 )
ni nj
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 41
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Rejection Rule
p-value Approach:
Reject H0 if p-value < α
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 42
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure_ _
Based on the Test Statistic xi - xj
Hypotheses
H 0 : µi = µ j
H a : µi ≠ µ j
Test Statistic xi − x j
Rejection Rule
Reject H0 if xi − x j ≥ LSD
where
=LSD tα /2 MSE( 1 + 1 )
ni nj
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 43
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Based on the Test Statistic xi - xj
Example: Reed Manufacturing
Recall that Janet Reed wants to know if there is any
significant difference in the mean number of hours
worked per week for the department managers at her
three manufacturing plants.
Analysis of variance has provided statistical
evidence to reject the null hypothesis of equal
population means. Fisher’s least significant difference
(LSD) procedure can be used to determine where the
differences occur.
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 44
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Based on the Test Statistic xi - xj
=LSD tα /2 MSE( 1 + 1 )
ni nj
= =
LSD 2.179 25.667( 1 + 1 ) 6.98
5 5
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 45
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Based on the Test Statistic xi - xj
LSD for Plants 1 and 2
Hypotheses (A) H 0 : µ1 = µ 2
H a : µ1 ≠ µ 2
Rejection Rule
Reject H0 if x1 − x2 ≥ 6.98
Test Statistic
x1 − x2 = |55 − 68| = 13
Conclusion
The mean number of hours worked at Plant 1 is
not equal to the mean number worked at Plant 2.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 46
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Based on the Test Statistic xi - xj
LSD for Plants 1 and 3
Hypotheses (B) H 0 : µ1 = µ 3
H a : µ1 ≠ µ 3
Rejection Rule
Reject H0 if x1 − x3 ≥ 6.98
Test Statistic
x1 − x3 = |55 − 57| = 2
Conclusion
There is no significant difference between the mean
number of hours worked at Plant 1 and the mean
number of hours worked at Plant 3.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 47
or duplicated, or posted to a publicly accessible website, in whole or in part.
Fisher’s LSD Procedure
Based on the Test Statistic xi - xj
LSD for Plants 2 and 3
Hypotheses (C) H 0 : µ2 = µ3
H a : µ2 ≠ µ3
Rejection Rule
Reject H0 if x2 − x3 ≥ 6.98
Test Statistic
x2 − x3 = |68 − 57| = 11
Conclusion
The mean number of hours worked at Plant 2 is
not equal to the mean number worked at Plant 3.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 48
or duplicated, or posted to a publicly accessible website, in whole or in part.
Type I Error Rates
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 49
or duplicated, or posted to a publicly accessible website, in whole or in part.
Exercise: Ethical Value
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 50
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 52
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
ANOVA Procedure
For a randomized block design the sum of squares
total (SST) is partitioned into three groups: sum of
squares due to treatments, sum of squares due to
blocks, and sum of squares due to error.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 53
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
ANOVA Table
Total SST nT - 1
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 54
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 55
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
Factor :
Treatments :
Blocks :
Response variable :
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 56
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 58
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
ANOVA Table
Total 62.00 14
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 60
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
Rejection Rule
p-Value Approach: Reject H0 if p-value < .05
Critical Value Approach: Reject H0 if F > 4.46
For α = .05, F.05 = 4.46
(2 d.f. numerator and 8 d.f. denominator)
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 61
or duplicated, or posted to a publicly accessible website, in whole or in part.
Randomized Block Design
Test Statistic
F = MSTR/MSE = 2.6/.68 = 3.82
Conclusion
The p-value is greater than .05 (where F = 4.46)
and less than .10 (where F = 3.11). (Excel provides
a p-value of .07). Therefore, we cannot reject H0.
There is insufficient evidence to conclude that
the miles per gallon ratings differ for the three
gasoline blends.
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 62
or duplicated, or posted to a publicly accessible website, in whole or in part.
Exercise: SAT
File: SATScores
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 63
or duplicated, or posted to a publicly accessible website, in whole or in part.
Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 64
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
ANOVA Procedure
The ANOVA procedure for the two-factor factorial
experiment is similar to the completely randomized
experiment and the randomized block experiment.
We again partition the sum of squares total (SST) into
its sources.
SST = SSA + SSB + SSAB + SSE
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 65
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
Total SST nT - 1
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 66
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 67
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 68
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 69
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 70
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
Factors
Factor A: Industry Type (2 levels)
Factor B: Location (3 levels)
Replications
Each experimental condition is repeated 3 times
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 71
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
ANOVA Table
Total 3.42 17
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 72
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 73
or duplicated, or posted to a publicly accessible website, in whole or in part.
Two-Factor Factorial Experiment
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 74
or duplicated, or posted to a publicly accessible website, in whole or in part.
Exercise: Amusement park
File: CH13_Ex
© 2014 Cengage Learning. All Rights Reserved. May not be scanned, copied
Slide 75
or duplicated, or posted to a publicly accessible website, in whole or in part.