© 2002 Thomson / South-Western Slide 11-1 Chapter 11 Analysis of Variance and Chi-Square...
-
Upload
ximena-padgham -
Category
Documents
-
view
212 -
download
0
Transcript of © 2002 Thomson / South-Western Slide 11-1 Chapter 11 Analysis of Variance and Chi-Square...
© 2002 Thomson / South-Western Slide 11-1
Chapter 11
Analysis of Variance and Chi-Square
Applications
© 2002 Thomson / South-Western Slide 11-2
Learning ObjectivesLearning Objectives
• Understand the differences between various experimental designs and when to use them.
• Compute and interpret the results of a one-way ANOVA.
• Compute and interpret the results of a random block design.
© 2002 Thomson / South-Western Slide 11-3
Learning Objectives, continued
• Compute and interpret the results of a two-way ANOVA.
• Understand and interpret interaction.• Understand the chi-square goodness-
of-fit test and how to use it.• Analyze data by using the chi-square
test of independence.
© 2002 Thomson / South-Western Slide 11-4
Introduction to Design of Experiments
Introduction to Design of Experiments
• An Experimental Design is a plan and a structure to test hypotheses in which the business analyst controls or manipulates one or more variables. It contains independent and dependent variables.
• Factors is another name for the independent variables of an experimental design.
© 2002 Thomson / South-Western Slide 11-5
Design of Experiments, continued
• Treatment variable is the independent variable that the experimenter either controls or modifies.
• Classification variable is the independent variable that was present prior to the experiment, and is not a result of the experimenter’s manipulations or control.
© 2002 Thomson / South-Western Slide 11-6
Design of Experiments, continued
• Levels or Classifications are the subcategories of the independent variable used by the business analyst in the experimental design.
• The Dependent Variable is the response to the different levels of the independent variables.
© 2002 Thomson / South-Western Slide 11-7
Three Types of Experimental Designs
Three Types of Experimental Designs
• Completely Randomized Design• Randomized Block Design• Factorial Experiments
© 2002 Thomson / South-Western Slide 11-8
Completely Randomized DesignCompletely Randomized Design
Machine Operator
1 2 3
.
.
.
.
.
.
.
.
.
Valve OpeningMeasurements
© 2002 Thomson / South-Western Slide 11-9
Example: Number of Foreign Freighters Docking in each Port per Day
Example: Number of Foreign Freighters Docking in each Port per Day
Long Beach
5
7
4
2
Houston
2
3
5
4
6
New York
8
4
6
7
9
8
New Orleans
3
5
3
4
2
© 2002 Thomson / South-Western Slide 11-10
Analysis of Variance (ANOVA): Assumptions
Analysis of Variance (ANOVA): Assumptions
• Observations are drawn from normally distributed populations.
• Observations represent random samples from the populations.
• Variances of the populations are equal.
© 2002 Thomson / South-Western Slide 11-11
One-Way ANOVA: Procedural OverviewOne-Way ANOVA:
Procedural Overview
H
H
ok
a
:
:1 2 3
At least one of the means is different from the others
FMSC
MSE
If F > , reject H .
If F , do not reject H .
c o
c o
FF
© 2002 Thomson / South-Western Slide 11-12
Partitioning Total Sum of Squares of VariationPartitioning Total Sum of Squares of Variation
SST(Total Sum of Squares)
SSC(Treatment Sum of Squares)
SSE(Error Sum of Squares)
© 2002 Thomson / South-Western Slide 11-13
One-Way ANOVA: Sums of Squares Definitions
One-Way ANOVA: Sums of Squares Definitions
j 2 2C 2
j=1 i=1 1 1 1
Total sum of squares = error sum of squares + between sum of squares
SST = SSC + SSE
n
ji
:
particular member of a treatment level
= a treatme
XjC C
j j i
n
ijj jj
where
i
j
X Xn X XX
j
j
ij
nt level
= number of treatment levels
number of observations in a given treatment level
X= grand mean
= mean of a treatment group or level
individual value
n
XX
C
© 2002 Thomson / South-Western Slide 11-14
One-Way ANOVA: Computational Formulas
One-Way ANOVA: Computational Formulas
SSC j C
SSE ij j
nN C
SST ij
nN
MSCSSC
MSESSE
FMSC
MSE
jj
C
C
ij
C
E
ij
C
T
C
E
n X X df
X X df
X X df
df
df
j
j
2
1
2
11
2
11
1
1
where
X
: i = a particular member of a treatment level
j = a treatment level
C = number of treatment levels
= number of observations in a given treatment level
X = grand mean
column mean
= individual value
j
j
ij
n
X
© 2002 Thomson / South-Western Slide 11-15
Freighter One-Way ANOVA:Preliminary Calculations
Freighter One-Way ANOVA:Preliminary Calculations
Long Beach
5742
T1 = 18
n1= 4
Houston
23546
T2 = 20
n2 = 5
New York
846798
T3 = 42
n3 = 6
New Orleans
35342
T4 = 17
n4 = 5
T = 97N = 20
© 2002 Thomson / South-Western Slide 11-16
Freighter One-Way ANOVA: Sum of Squares CalculationsFreighter One-Way ANOVA: Sum of Squares Calculations
1 2 3 4
1 2 3 4
1 2 3 4
: 18 20 42 42 97
: 4 5 6 5 20
: 4.5 4.0 7.0 3.4 4.85
j
j
j
T
N
X
T T T T T
n n n n n
X X X X X
© 2002 Thomson / South-Western Slide 11-17
SSC j
SSE ij j
n
jj
C
ij
C
n X X
X Xj
2
1
2 2 2 2
2
11
2 2 2 2
2 2 2 2
4 5 6 55 485 0 485 7 485 4 48542 35
5 45 45 45 454 0 4 0 34 34
44
[ (4. . ) (4. . ) (4. . ) (3. . ).
( . ) (7 . ) (4 . ) (2 . )(2 . ) (3 . ) (4 . ) (2 . ).
20
5 485 485 485 485 4858655
2
11
2 2 2 2 2
SST ij
n
X Xij
C j
( . ) (7 . ) (4 . ) (4 . ) (2 . ).
Freighter One-Way ANOVA: Sum of Squares Calculations, continued
Freighter One-Way ANOVA: Sum of Squares Calculations, continued
© 2002 Thomson / South-Western Slide 11-18
Freighter One-Way ANOVA: Mean Square and F Calculations
Freighter One-Way ANOVA: Mean Square and F Calculations
C
E
T
C
E
dfdfdf
df
df
C
N C
N
MSCSSC
MSESSE
FMSC
MSE
1 4 1 3
20 4 16
1 20 1 19
42 35
31412
44 20
162 76
1412
2 76512
..
..
.
..
© 2002 Thomson / South-Western Slide 11-19
Freighter Example: Analysis of VarianceFreighter Example:
Analysis of Variance
Source of Variancedf SS MS F
Between Factor 3 42.35 14.12 5.12Error 16 44.20 2.76Total 19 86.55
© 2002 Thomson / South-Western Slide 11-20
A Portion of the F Table for = 0.05A Portion of the F Table for = 0.05
1 2 3 4 5 6 7 8 91 161.45 199.50 215.71 224.58 230.16 233.99 236.77 238.88 240.54
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15 4.54 3.68 3.29 3.06 2.90 2.79 2.71 2.64 2.5916 4.49 3.63 3.24 3.01 2.85 2.74 2.66 2.59 2.5417 4.45 3.59 3.20 2.96 2.81 2.70 2.61 2.55 2.49
. , ,05 3 16F
DenominatorDegrees of Freedom
Numerator Degrees of Freedom
© 2002 Thomson / South-Western Slide 11-21
Freighter One-Way ANOVA: Procedural Summary
Freighter One-Way ANOVA: Procedural Summary
If
If
F > reject H .
F do reject H .
c o
c o
FF
3 24
3 24
. ,
. ,
Rejection Region
Critical Value. , , .05 9 11 3 24F
Non rejectionRegion
1
2
3
16
others thefromdifferent is
means theof oneleast At :H
:H
a
4321o
ocSince F = 5.12 > 3.24, reject H .F
© 2002 Thomson / South-Western Slide 11-22
Excel Output for the Freighter Example
Excel Output for the Freighter Example
Anova: Single Factor
SUMMARYGroups Count Sum Average Variance
Long Beach 4 18 4.5 4.3333Houston 5 20 4 2.5New York 6 42 7 3.2New Orleans 5 17 3.4 1.3
ANOVASource of Variation SS df MS F P-value F critBetween Groups 42.35 3 14.117 5.1101 0.0114 3.2389Within Groups 44.2 16 2.7625
Total 86.55 19
© 2002 Thomson / South-Western Slide 11-23
Multiple Comparison TestsMultiple Comparison Tests
• An analysis of variance (ANOVA) test is an overall test of differences among groups.
• Multiple Comparison techniques are used to identify which pairs of means are significantly different given that the ANOVA test reveals overall significance.
© 2002 Thomson / South-Western Slide 11-24
Randomized Block Design
• An experimental design in which there is one independent variable, and a second variable known as a blocking variable, that is used to control for confounding or concomitant variables.
• Confounding or concomitant variable are not being controlled by the business analyst but can have an effect on the outcome of the treatment being studied.
© 2002 Thomson / South-Western Slide 11-25
Randomized Block Design, continued
• Blocking variable is a variable that the business analyst wants to control but is not the treatment variable of interest.
• Repeated measures design is a randomized block design in which each block level is an individual item or person, and that person or item is measured across all treatments.
© 2002 Thomson / South-Western Slide 11-26
Partitioning the Total Sum of Squares in the Randomized Block Design
Partitioning the Total Sum of Squares in the Randomized Block Design
SST(total sum of squares)
SSC(treatment
sum of squares)
SSE(error sum of squares)
SSR(sum of squares
blocks)
SSE’(sum of squares
error)
© 2002 Thomson / South-Western Slide 11-27
A Randomized Block DesignA Randomized Block Design
Individualobservations
.
.
.
.
.
.
.
.
.
.
.
.
Single Independent Variable
BlockingVariable
.
.
.
.
.
© 2002 Thomson / South-Western Slide 11-28
Randomized Block Design Treatment Effects: Procedural Overview
Randomized Block Design Treatment Effects: Procedural Overview
others thefromdifferent is means theof oneleast At :H
:H
a
321o
k
FMSC
MSE
If F > , reject H .
If F , do not reject H .
c o
c o
FF
© 2002 Thomson / South-Western Slide 11-29
Randomized Block Design: Computational Formulas
Randomized Block Design: Computational Formulas
SSC n j C
SSR C i n
SSE ij i i C n N n C
SST ij N
MSCSSC
C
MSRSSR
n
MSESSE
N n CMSC
MSEMSR
MSE
X X df
X X df
X X X X df
X X df
F
F
j
C
C
i
n
R
i
n
j
n
E
i
n
j
n
E
treatments
blocks
2
1
2
12
11
2
11
1
1
1 1 1
1
1
1
1
( )
( )
( )
( )where: i = block group (row)
j = a treatment level (column)
C = number of treatment levels (columns)
n = number of observations in each treatment level (number of blocks - rows)
individual observation
treatment (column) mean
block (row) mean
X = grand mean
N = total number of observations
ij
j
i
X
X
X
SSC sum of squares columns (treatment)
SSR = sum of squares rows (blocking)
SSE = sum of squares error
SST = sum of squares total
© 2002 Thomson / South-Western Slide 11-30
Tread-Wear Example: Randomized Block Design
Tread-Wear Example: Randomized Block Design
Supplier
1
2
3
4
Slow Medium FastBlock Means ( )
3.7 4.5 3.1 3.77
3.4 3.9 2.8 3.37
3.5 4.1 3.0 3.53
3.2 3.5 2.6 3.10
5
Treatment Means( )
3.9 4.8 3.4 4.03
3.54 4.16 2.98 3.56
Speed
jX
iX
X
C = 3
n = 5
N = 15
© 2002 Thomson / South-Western Slide 11-31
SSC n j
SSR C i
X X
X X
j
C
i
n
2
1
2 2 2
2
1
2 2 2 2 2
5
3
54 356 16 356 98 3563484
77 356 37 356 53 356 10 356 03 3561549
( )
(3. . ) (4. . ) (2. . ).
( )
(3. . ) (3. . ) (3. . ) (3. . ) (4. . ).
[
[ ]
Tread-wear Randomized Block Design: Sum of Squares Calculations (Part 1)
Tread-wear Randomized Block Design: Sum of Squares Calculations (Part 1)
© 2002 Thomson / South-Western Slide 11-32
Tread-wear Randomized Block Design: Sum of Squares Calculations (Part 2)
Tread-wear Randomized Block Design: Sum of Squares Calculations (Part 2)
SSE ij j i
SST ij
X X X X
X X
i
n
j
C
i
n
j
C
2
11
2 2
2 2
2
11
2 2 2
7 354 377 356 4 354 337 3566 2 98 310 356 4 2 98 4 03 356
0143
7 356 4 356 6 3
( )
(3. . . . ) (3. . . . )(2. . . . ) (3. . . . ).
( )
(3. . ) (3. . ) (2.
. ) (3. . ).
56 4 3565176
2
© 2002 Thomson / South-Western Slide 11-33
Tread-wear Randomized Block Design: Mean Square Calculations
Tread-wear Randomized Block Design: Mean Square Calculations
MSCSSC
C
MSRSSR
n
MSESSE
N n C
FMSC
MSE
1
3 484
21742
1
1549
40 387
1
0143
80 018
1742
0 01896 78
..
..
..
.
..
© 2002 Thomson / South-Western Slide 11-34
Analysis of Variance for the Tread-Wear Example
Analysis of Variance for the Tread-Wear Example
Source of VarianceSS df MS F
Treatment 3.484 2 1.74296.78
Block 1.549 4 0.387
Error 0.143 8 0.018
Total 5.176 14
© 2002 Thomson / South-Western Slide 11-35
Tread-wear Randomized Block Design Treatment Effects: Procedural SummaryTread-wear Randomized Block Design
Treatment Effects: Procedural Summary
H
H
o
a
:
:1 2 3
At least one of the means is different from the others
FMSC
MSE
1742
0 01896 78
.
..
F = 96.78 > = 8.65, reject H ..01,2,8 oF
© 2002 Thomson / South-Western Slide 11-36
Excel Output for Tread-Wear Randomized Block Design
Excel Output for Tread-Wear Randomized Block Design
Anova: Two-Factor Without Replication
SUMMARY Count Sum Average Variance 1 3 11.3 3.7666667 0.4933333 2 3 10.1 3.3666667 0.3033333 3 3 10.6 3.5333333 0.3033333 4 3 9.3 3.1 0.21
5 3 12.1 4.0333333 0.5033333
Slow 5 17.7 3.54 0.073Medium 5 20.8 4.16 0.258Fast 5 14.9 2.98 0.092
ANOVASource of Variation SS df MS F P-value F critRows 1.5493333 4 0.3873333 21.719626 0.0002357 7.0060651Columns 3.484 2 1.742 97.682243 2.395E-06 8.6490672Error 0.1426667 8 0.0178333
Total 5.176 14
© 2002 Thomson / South-Western Slide 11-37
Two-Way Factorial Design
• An experimental design in which two ot more independent variables are studied simultaneously and every level of treatment is studied under the conditions of every level of all other treatments.
• Also called a factorial experiment.
© 2002 Thomson / South-Western Slide 11-38
Two-Way Factorial DesignTwo-Way Factorial Design
Cells
.
.
.
.
.
.
.
.
.
.
.
.
Column Treatment
RowTreatment
.
.
.
.
.
© 2002 Thomson / South-Western Slide 11-39
Two-Way ANOVA: HypothesesTwo-Way ANOVA: Hypotheses
Row Effects: H : Row Means are all equal.
H : At least one row mean is different from the others.
Columns Effects: H : Column Means are all equal.
H : At least one column mean is different from the others.
Interaction Effects: H : The interaction effects are zero.
H : There is an interaction effect.
o
a
o
a
o
a
© 2002 Thomson / South-Western Slide 11-40
Formulas for Computing a Two-Way ANOVA
Formulas for Computing a Two-Way ANOVA
SSR nC i R
SSC nR j C
SSI n ij i j R C
SSE ijk ij RC n
SST ijk N
MSRSSR
R
MSR
MSE
MSC
X X df
X X df
X X X X df
X X df
X X df
F
i
R
R
j
C
C
j
C
i
R
I
k
n
j
C
i
R
E
a
n
r
R
c
C
T
R
2
1
2
1
2
11
2
111
2
111
1
1
1 1
1
1
1
( )
( )
( )
( )
( )
SSC
C
MSC
MSE
MSISSI
R C
MSI
MSE
MSESSE
RC n
where
C
I
F
F
1
1 1
1
:
n = number of observations per cell
C = number of column treatments
R = number of row treatments
i = row treatment level
j = column treatment level
k = cell member
= individual observation
= cell mean
= row mean
= column mean
X = grand mean
ijk
ij
i
j
XXXX
© 2002 Thomson / South-Western Slide 11-41
A 2 3 Factorial Design with Interaction
A 2 3 Factorial Design with Interaction
CellMeans
C1 C2 C3
Row effects
R1
R2
Column
© 2002 Thomson / South-Western Slide 11-42
A 2 3 Factorial Design with Some Interaction
A 2 3 Factorial Design with Some Interaction
CellMeans
C1 C2 C3
Row effects
R1
R2
Column
© 2002 Thomson / South-Western Slide 11-43
A 2 3 Factorial Design with No Interaction
A 2 3 Factorial Design with No Interaction
CellMeans
C1 C2 C3
Row effects
R1
R2
Column
© 2002 Thomson / South-Western Slide 11-44
CEO Dividend 2 3 Factorial Design: Data and Measurements
CEO Dividend 2 3 Factorial Design: Data and Measurements
N = 24n = 4
X=2.7083
1.75 2.75 3.625
Location Where CompanyStock is Traded
How Stockholders are Informed of
DividendsNYSE AMEX OTC
Annual/Quarterly Reports
2121
2332
4343
2.5
Presentations to Analysts
2312
3324
4434
2.9167
Xj
Xi
X11=1.5
X23=3.75X22=3.0X21=2.0
X13=3.5X12=2.5
© 2002 Thomson / South-Western Slide 11-45
CEO Dividend 2 3 Factorial Design: Calculations (Part 1)
CEO Dividend 2 3 Factorial Design: Calculations (Part 1)
SSR X X
SSC X X
SSI X X X X
nC i
nR j
n ij i j
i
R
j
C
j
C
i
R
2
1
2 2
2
1
2 2 2
2
11
2
4 3 2 5 2 7083 2 9167 2 7083
4 2 175 2 7083 2 75 2 7083 3 625 2 7083
4 15 2 5 175 2 7083
10418
14 0833
( )
.
( )
.
( )
( )( )[( . . ) ( . . ) ]
( )( )[( . . ) ( . . ) ( . . ) ]
[( . . . . ) ( . . . . )
( . . . . ) ( . . . . )
( . . . . ) ( . . . . ) ]
.
2 5 2 5 2 75 2 7083
35 2 5 3 625 2 7083 2 0 2 9167 175 2 7083
3 0 2 9167 2 75 2 7083 3 75 2 9167 3 625 2 7083
2
2 2
2 2
00833
© 2002 Thomson / South-Western Slide 11-46
CEO Dividend 2 3 Factorial Design: Calculations (Part 2)
CEO Dividend 2 3 Factorial Design: Calculations (Part 2)
SSE X X
SST X X
ijk ij
ijk
k
n
j
C
i
R
a
n
r
R
c
C
2
111
2 2 2 2
2
111
2 2 2 2
2 15 1 15 3 375 4 3757 7500
2 2 7083 1 2 7083 3 2 7083 4 2 708322 9583
( )
( . ) ( . ) ( . ) ( . ).
( )
( . ) ( . ) ( . ) ( . ).
© 2002 Thomson / South-Western Slide 11-47
CEO Dividend 2 3 Factorial Design: Calculations (Part 3)
CEO Dividend 2 3 Factorial Design: Calculations (Part 3)
MSRSSR
R
MSR
MSE
MSCSSC
C
MSC
MSE
MSISSI
R C
MSI
MSE
MSESSE
RC n
R
C
I
F
F
F
1
10418
110418
10418
0 43062 42
1
14 0833
27 0417
7 0417
0 430616 35
1 1
0 0833
20 0417
0 0417
0 4306010
1
7 7500
180 4306
..
.
..
..
.
..
..
.
..
..
© 2002 Thomson / South-Western Slide 11-48
CEO Dividend: Analysis of Variance CEO Dividend: Analysis of Variance
Source of VarianceSS df MS F
Row 1.0418 1 1.0418 2.42
Column 14.0833 2 7.0417 16.35*
Interaction 0.0833 2 0.0417 0.10
Error 7.7500 18 0.4306
Total 22.9583 23
*Denotes significance at = .01.
© 2002 Thomson / South-Western Slide 11-49
CEO Dividend Excel Output (Part 1)
CEO Dividend Excel Output (Part 1)
Anova: Two-Factor With Replication
SUMMARY NYSE ASE OTC TotalReports
Count 4 4 4 12Sum 6 10 14 30Average 1.5 2.5 3.5 2.5Variance 0.3333 0.3333 0.3333 1
PresentationCount 4 4 4 12Sum 8 12 15 35Average 2 3 3.75 2.9167Variance 0.6667 0.6667 0.25 0.9924
TotalCount 8 8 8Sum 14 22 29Average 1.75 2.75 3.625Variance 0.5 0.5 0.2679
© 2002 Thomson / South-Western Slide 11-50
CEO Dividend Excel Output (Part 2)CEO Dividend Excel Output (Part 2)
ANOVASource of Variation SS df MS F P-value F critSample 1.0417 1 1.0417 2.4194 0.1373 4.4139Columns 14.083 2 7.0417 16.355 9E-05 3.5546Interaction 0.0833 2 0.0417 0.0968 0.9082 3.5546Within 7.75 18 0.4306
Total 22.958 23
© 2002 Thomson / South-Western Slide 11-51
2 Goodness-of-Fit Test2 Goodness-of-Fit Test
The2 goodness-of-fit test compares expected (theoretical) frequencies of categories from a population distribution to the observed (actual) frequencies from a distribution to determine whether there is a difference between what was expected and what was observed.
© 2002 Thomson / South-Western Slide 11-52
2 Goodness-of-Fit Test2 Goodness-of-Fit Test
data sample thefrom estimated parameters ofnumber =
categories ofnumber
valuesexpected offrequency
valuesobserved offrequency :
- 1 - = df
2
2
c
k
where
ck
eo
ff
fff
e
o
e
© 2002 Thomson / South-Western Slide 11-53
Month GallonsJanuary 1,553
February 1,585March 1,649April 1,590May 1,497June 1,443July 1,410
August 1,450September 1,495
October 1,564November 1,602December 1,609
18,447
Milk Sales Data for Demonstration Problem 11.4
Milk Sales Data for Demonstration Problem 11.4
© 2002 Thomson / South-Western Slide 11-54
Demonstration Problem 11.4: Hypotheses and Decision Rules
Demonstration Problem 11.4: Hypotheses and Decision Rules
ddistributeuniformly not are
salesmilk for figuresmilk monthly The :H
ddistributeuniformly are
salesmilk for figuresmilk monthly The :H
a
o
.
.. ,
01
1
12 1 0
11
24 72501 11
2
df k cIf reject H .
If do not reject H .
Cal
2o
Cal
2o
24 725
24 725
. ,
. ,
© 2002 Thomson / South-Western Slide 11-55
Demonstration Problem 11.4: Calculations
Demonstration Problem 11.4: Calculations
Month fo fe (fo - fe)2/fe
January 1,553 1,537.25 0.16February 1,585 1,537.25 1.48March 1,649 1,537.25 8.12April 1,590 1,537.25 1.81May 1,497 1,537.25 1.05June 1,443 1,537.25 5.78July 1,410 1,537.25 10.53August 1,450 1,537.25 4.95September 1,495 1,537.25 1.16October 1,564 1,537.25 0.47November 1,602 1,537.25 2.73December 1,609 1,537.25 3.35
18,447 18,447.00 41.59
Observed Chi-square= 41.59
© 2002 Thomson / South-Western Slide 11-56
Demonstration Problem 11.4: Conclusion
Demonstration Problem 11.4: Conclusion
0.01
df = 11
24.725
Non Rejectionregion
2o41.59 24.725, reject H .
Cal
© 2002 Thomson / South-Western Slide 11-57
Defects Example: Using a 2 Goodness-of-Fit Test to Test a Population Proportion
Defects Example: Using a 2 Goodness-of-Fit Test to Test a Population Proportion
a
H : = .08
H : .08
o P
P
.
.. ,
05
1
2 1 0
1
384105 1
2
df k c
If reject H .
If do not reject H .
Cal
2o
Cal
2o
3841
3841
. ,
. ,
© 2002 Thomson / South-Western Slide 11-58
Defects Example: CalculationsDefects Example: Calculations
2
2
33 16 167 18416 184
18.06 + 1.57
1963
o ef ff e
=
2 2
.
.
fo fe
Defects 33 16Nondefects 167 184
200 200n =
200 .08
16
1
200 .92
184
e
e
e
e
Defects n P
Nondefects n P
ff
ff
© 2002 Thomson / South-Western Slide 11-59
Defects Example: Conclusion
Defects Example: Conclusion
0.05
df = 1
3.841
Non Rejectionregion
2o19.63 3.841, reject H .
Cal
© 2002 Thomson / South-Western Slide 11-60
Contingency Analysis:2 Test of IndependenceContingency Analysis:
2 Test of Independence
A statistical test used to analyze the frequencies of two variables with multiple categories to determine whether the two variables are independent.
Qualitative VariablesNominal Data
© 2002 Thomson / South-Western Slide 11-61
Investment Example2 Test of Independence
Investment Example2 Test of Independence
• In which region of the country do you reside?A. NortheastB. MidwestC. SouthD. West
• Which type of financial investment are you most likely to make today?E. StocksF. BondsG. Treasury bills
© 2002 Thomson / South-Western Slide 11-62
Investment Example2 Test of Independence
Type of financialInvestment
E F GA O13 nA
Geographic B nB
Region C nC
D nD
nE nF nG N
Contingency Table
© 2002 Thomson / South-Western Slide 11-63
Investment Example2 Test of Independence
Investment Example2 Test of Independence
Type of Financial Investment
E F GA e12 nA
Geographic B nB
Region C nC
D nD
nE nF nG N
Contingency Table
If A and F are independent,
P A F P A P F
P AN
P FN
P A FN N
A F
A F
n n
n n
AF
A F
A F
en n
n n
N P A F
NN N
N
© 2002 Thomson / South-Western Slide 11-64
2 Test of Independence: Formulas2 Test of Independence: Formulas
ij
i j
en nN
where
: i = the row
j = the colum n
the total of row i
the total of column j
N = the total of all fr equencies
i
j
nn
2
2
o e
where
f ff e
: df = (r - 1)(c - 1) r = the numbe r of rowsc = the numbe r of columns
ExpectedFrequencies
Calculated
(Observed )