0% found this document useful (0 votes)
22 views68 pages

BBS11 PPT ch12

Basic business statistics notes ch12

Uploaded by

motvbox80
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views68 pages

BBS11 PPT ch12

Basic business statistics notes ch12

Uploaded by

motvbox80
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 68

Basic Business Statistics

11th Edition

Chapter 12

Chi-Square Tests and


Nonparametric Tests

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc. Chap 12-1


Learning Objectives

In this chapter, you learn:


 How and when to use the chi-square test for
contingency tables
 How to use the Marascuilo procedure for
determining pairwise differences when evaluating
more than two proportions
 How and when to use the McNemar test
 How to use the chi-square test for a variance or
standard deviation
 How and when to use nonparametric tests

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-2


Contingency Tables

Contingency Tables
 Useful in situations involving multiple population
proportions
 Used to classify sample observations according
to two or more characteristics
 Also called a cross-classification table .

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-3


Contingency Table Example

Left-Handed vs. Gender


Dominant Hand: Left vs. Right
Gender: Male vs. Female

 2 categories for each variable, so


called a 2 x 2 table

 Suppose we examine a sample of


300 children

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-4


Contingency Table Example
(continued)

Sample results organized in a contingency table:

Hand Preference
sample size = n = 300:
Gender Left Right
120 Females, 12
were left handed
Female 12 108 120
180 Males, 24 were
left handed Male 24 156 180

36 264 300

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-5


2 Test for the Difference
Between Two Proportions
H0: π1 = π2 (Proportion of females who are left
handed is equal to the proportion of
males who are left handed)
H1: π1 ≠ π2 (The two proportions are not the same –
hand preference is not independent
of gender)
 If H0 is true, then the proportion of left-handed females should be
the same as the proportion of left-handed males
 The two proportions above should be the same as the proportion of
left-handed people overall

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-6


The Chi-Square Test Statistic
The Chi-square test statistic is:
( fo  fe )2
2
χ STAT  
all cells
fe
 where:
fo = observed frequency in a particular cell
fe = expected frequency in a particular cell if H0 is true
2
χ STAT for the 2 x 2 case has 1 degree of freedom

(Assumed: each cell in the contingency table has expected


frequency of at least 5)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-7


Decision Rule
2
The χ STAT test statistic approximately follows a chi-
squared distribution with one degree of freedom

Decision Rule:
2 2
χ
If STAT  χ α , reject H 0,
otherwise, do not reject 
H0
0
Do not Reject H0 
reject H0
2α

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-8


Computing the
Average Proportion
The average X1  X 2 X
p 
proportion is: n1  n2 n

120 Females, 12 Here:


were left handed
12  24 36
180 Males, 24 were p  0.12
left handed
120  180 300

i.e., of all the children the proportion of left handers is 0.12,


that is, 12%

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-9


Finding Expected Frequencies

 To obtain the expected frequency for left handed


females, multiply the average proportion left handed (p)
by the total number of females
 To obtain the expected frequency for left handed males,
multiply the average proportion left handed (p) by the
total number of males
If the two proportions are equal, then
P(Left Handed | Female) = P(Left Handed | Male) = .12

i.e., we would expect (.12)(120) = 14.4 females to be left handed


(.12)(180) = 21.6 males to be left handed

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-10


Observed vs. Expected
Frequencies

Hand Preference

Gender Left Right

Observed = 12 Observed = 108


Female 120
Expected = 14.4 Expected = 105.6
Observed = 24 Observed = 156
Male 180
Expected = 21.6 Expected = 158.4
36 264 300

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-11


The Chi-Square Test Statistic
Hand Preference

Gender Left Right

Observed = 12 Observed = 108


Female 120
Expected = 14.4 Expected = 105.6
Observed = 24 Observed = 156
Male 180
Expected = 21.6 Expected = 158.4
36 264 300
The test statistic is:
(f o  f e ) 2
χ 2STAT  
all cells
fe
(12  14.4) 2 (108  105.6)2 (24  21.6) 2 (156  158.4)2
    0.7576
14.4 105.6 21.6 158.4
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-12
Decision Rule
2
The test statistic is χ STAT 0.7576 ; χ 02.05 with 1 d.f. 3.841

Decision Rule:
2
If χ STAT > 3.841, reject H0,
otherwise, do not reject H0

Here,
2 2
0.05 χ STAT = 0.7576< χ 0.05 = 3.841,
so we do not reject H0 and
0 conclude that there is not
Do not Reject H0  sufficient evidence that the two
reject H0
20.05 = 3.841 proportions are different at  =
0.05

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-13


2 Test for Differences Among
More Than Two Proportions
 Extend the 2 test to the case with more than
two independent populations:

H 0: π 1 = π 2 = … = π c
H1: Not all of the πj are equal (j = 1, 2, …, c)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-14


The Chi-Square Test Statistic
The Chi-square test statistic is:
( fo  fe )2
2
χ STAT  
all cells
fe
 Where:
fo = observed frequency in a particular cell of the 2 x c table
fe = expected frequency in a particular cell if H0 is true

χ 2STAT for the 2 x c case has (2 - 1)(c - 1) c - 1 degrees of freedom

(Assumed: each cell in the contingency table has expected


frequency of at least 1)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-15


Computing the
Overall Proportion
The overall X1  X 2    Xc X
p 
proportion is: n1  n2    nc n

 Expected cell frequencies for the c categories


are calculated as in the 2 x 2 case, and the
decision rule is the same:
2
χ
Where α is from the chi-
Decision Rule:
squared distribution with
If χ STAT
2
 χ α2 , reject H0, c – 1 degrees of freedom
otherwise, do not reject H0

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-16


The Marascuilo Procedure

 Used when the null hypothesis of equal


proportions is rejected
 Enables you to make comparisons between all
pairs
 Start with the observed differences, p j – pj’, for
all pairs (for j ≠ j’) . . .
 . . .then compare the absolute difference to a
calculated critical range

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-17


The Marascuilo Procedure
(continued)

 Critical Range for the Marascuilo Procedure:


p j (1  p j ) p j ' (1  p j ' )
Critical range  χ α2 
nj n j'

(Note: the critical range is different for each pairwise comparison)
 A particular pair of proportions is significantly
different if

| pj – pj’| > critical range for j and j’

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-18


Marascuilo Procedure Example
A University is thinking of switching to a trimester academic
calendar. A random sample of 100 administrators, 50 students,
and 50 faculty members were surveyed

Opinion Administrators Students Faculty


Favor 63 20 37
Oppose 37 30 13
Totals 100 50 50

Using a 1% level of significance, which groups have a


different attitude?
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-19
Chi-Square Test Results
H 0: π 1 = π 2 = π 3
H1: Not all of the πj are equal (j = 1, 2, 3)

Chi-Square Test: Administrators, Students, Faculty


Admin Students Faculty Total
Favor 63 20 37 120
60 30 30
Expected Oppose 37 30 13 80
Observed
40 20 20
Total 100 50 50 200

2
χ STAT  12.792  χ 02.01  9.2103 so reject H 0

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-20


Marascuilo Procedure: Solution
Excel Output:
compare
Marascuilo Procedure

Sample Sample Absolute Std. Error Critical


Group Proportion Size ComparisonDifference of Difference Range Results
1 0.63 100 1 to 2 0.23 0.084445249 0.2563 Means are not different
2 0.4 50 1 to 3 0.11 0.078606615 0.2386 Means are not different
3 0.74 50 2 to 3 0.34 0.092994624 0.2822 Means are different

Other Data
Level of significance 0.01 Chi-sq Critical Value 9.2103
d.f 2
Q Statistic 3.034854
At 1% level of significance, there is evidence of a difference
in attitude between students and faculty

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-21


2 Test of Independence

 Similar to the 2 test for equality of more than


two proportions, but extends the concept to
contingency tables with r rows and c columns

H0: The two categorical variables are independent


(i.e., there is no relationship between them)
H1: The two categorical variables are dependent
(i.e., there is a relationship between them)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-22


2 Test of Independence
(continued)

The Chi-square test statistic is:


( fo  fe )2
2
χ STAT  
all cells
fe
 where:
fo = observed frequency in a particular cell of the r x c table
fe = expected frequency in a particular cell if H0 is true

χ 2STAT for the r x c case has (r - 1)(c - 1) degrees of freedom

(Assumed: each cell in the contingency table has expected


frequency of at least 1)
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-23
Expected Cell Frequencies

 Expected cell frequencies:

row total column total


fe 
n

Where:
row total = sum of all frequencies in the row
column total = sum of all frequencies in the column
n = overall sample size

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-24


Decision Rule

 The decision rule is

If χ 2  χ 2 , reject H ,
0
STAT α

otherwise, do not reject H0

2
Where χ α is from the chi-squared distribution
with (r – 1)(c – 1) degrees of freedom

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-25


Example
 The meal plan selected by 200 students is shown below:

Number of meals per week


Class 20/week 10/week none Total
Standing
Fresh. 24 32 14 70
Soph. 22 26 12 60
Junior 10 14 6 30
Senior 14 16 10 40
Total 70 88 42 200

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-26


Example
(continued)

 The hypothesis to be tested is:

H0: Meal plan and class standing are independent


(i.e., there is no relationship between them)
H1: Meal plan and class standing are dependent
(i.e., there is a relationship between them)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-27


Example:
Expected Cell Frequencies
(continued)
Observed:
Number of meals
per week
Expected cell
Class 20/wk 10/wk none
Standing Total frequencies if H0 is true:
Fresh. 24 32 14 70 Number of meals
Soph. 22 26 12 60 per week
Junior 10 14 6 30 Class 20/wk 10/wk none
Senior 14 16 10 40 Standing Total
Total 70 88 42 200 Fresh. 24.5 30.8 14.7 70
Example for one cell: Soph. 21.0 26.4 12.6 60
row total column total Junior 10.5 13.2 6.3 30
fe 
n Senior 14.0 17.6 8.4 40
30 70 Total 70 88 42 200
 10.5
200
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-28
Example: The Test Statistic
(continued)

 The test statistic value is:

( f o  f e )2
2
χ STAT  
all cells
fe
( 24  24.5 ) 2 ( 32  30.8 ) 2 ( 10  8.4 ) 2
    0.709
24.5 30.8 8.4

χ 0.2 05 = 12.592 from the chi-squared distribution


with (4 – 1)(3 – 1) = 6 degrees of freedom

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-29


Example:
Decision and Interpretation
(continued)

2
The test statistic is χ STAT 0.709 ; χ 02.05 with 6 d.f. 12.592

Decision Rule:
2
If χ STAT > 12.592, reject H0,
otherwise, do not reject H0

0.05 Here,
2
χ STAT = 0.709 < χ 0.2 05 = 12.592,
so do not reject H0
0
Do not Reject H0  Conclusion: there is not
reject H0 sufficient evidence that meal
20.05=12.592 plan and class standing are
related at  = 0.05
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-30
McNemar Test (Related Samples)

 Used to determine if there is a difference


between proportions of two related samples

 Uses a test statistic the follows the normal


distribution

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-31


McNemar Test (Related Samples)
(continued)

 Consider a 2 X 2 contingency table:

Condition 2

Condition 1 Yes No Totals

Yes A B A+B

No C D C+D

Totals A+C B+D n


Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-32
McNemar Test (Related Samples)
(continued)

 The sample proportions of interest are


A B
p1  proportion of respondents who answer yes to condition 1
n

A C
p2  proportion of respondents who answer yes to condition 2
n

 Test H0: π1 = π2
(the two population proportions are equal)
H1: π1 ≠ π2
(the two population proportions are not equal)
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-33
McNemar Test (Related Samples)
(continued)

 The test statistic for the McNemar test:

B C
Z STAT 
BC

where the test statistic Z is approximately


normally distributed

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-34


McNemar Test
Example

 Suppose you survey 300 homeowners and ask


them if they are interested in refinancing their
home. In an effort to generate business, a
mortgage company improved their loan terms
and reduced closing costs. The same
homeowners were again surveyed. Determine
if change in loan terms was effective in
generating business for the mortgage
company. The data are summarized as
follows:

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-35


McNemar Test
Example

Survey response after change


Survey response Yes No Totals
before change

Yes 118 2 120


No 22 158 180
Totals 140 160 300

Test the hypothesis (at the 0.05 level of significance):


H0: π1 ≥ π2: The change in loan terms was ineffective
H1: π1 < π2: The change in loan terms increased business

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-36


McNemar Test
Example

Survey Survey response after


The critical value (0.05
response change significance) is Z0.05 = -1.645
before Yes No Totals
change The test statistic is:
B C 2  22
Z STAT    4.08
Yes 118 2 120 B C 2  22
No 22 158 180
Totals 140 160 300
Since ZSTAT = -4.08 < -1.645, you reject H0 and conclude that the
change in loan terms significantly increase business for the
mortgage company.

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-37


Chi-Square Test for a Variance or
Standard Deviation
 A χ2 test statistic is used to test whether or not the
population variance or standard deviation is equal
to a specified value:

2 (n - 1)S 2
χ STAT 
σ2

Where n = sample size


S2 = sample variance
2
χ STAT σ2 = hypothesized population variance
follows a chi-square distribution with n – 1
d.f.
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-38
Wilcoxon Rank-Sum Test for
Differences in 2 Medians

 Test two independent population medians


 Populations need not be normally distributed
 Distribution free procedure
 Used when only rank data are available
 Must use normal approximation if either of the
sample sizes is larger than 10

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-39


Wilcoxon Rank-Sum Test:
Small Samples
 Can use when both n1 , n2 ≤ 10
 Assign ranks to the combined n1 + n2 sample
observations
 If unequal sample sizes, let n1 refer to smaller-sized
sample
 Smallest value rank = 1, largest value rank = n1 + n2

Assign average rank for ties
 Sum the ranks for each sample: T1 and T2
 Obtain test statistic, T1 (from smaller sample)
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-40
Checking the Rankings

 The sum of the rankings must satisfy the


formula below
 Can use this to verify the sums T1 and T2

n(n  1)
T1  T2 
2

where n = n1 + n2

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-41


Wilcoxon Rank-Sum Test:
Hypothesis and Decision Rule
M1 = median of population 1; M2 = median of population 2
Test statistic = T1 (Sum of ranks from smaller sample)

Two-Tail Test Left-Tail Test Right-Tail Test


H0: M1 = M2 H0: M1  M2 H0: M1  M2
H1: M1  M2 H1: M1  M2 H1: M1  M2

Reject Do Not Reject Reject Do Not Reject Do Not Reject Reject


Reject
T1L T1U T1L T1U
Reject H0 if T1 ≤ T1L Reject H0 if T1 ≤ T1L Reject H0 if T1 ≥ T1U
or if T1 ≥ T1U
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-42
Wilcoxon Rank-Sum Test:
Small Sample Example

Sample data are collected on the capacity rates


(% of capacity) for two factories.
Are the median operating rates for two factories
the same?
 For factory A, the rates are 71, 82, 77, 94, 88
 For factory B, the rates are 85, 82, 92, 97
Test for equality of the population medians
at the 0.05 significance level

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-43


Wilcoxon Rank-Sum Test:
Small Sample Example
(continued)
Ranked Capacity Rank
Capacity Factory A Factory B Factory A Factory B
values: 71 1
77 2
Tie in 3rd and 82 3.5
4th places 82 3.5
85 5
88 6
92 7
94 8
97 9
Rank Sums: 20.5 24.5
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-44
Wilcoxon Rank-Sum Test:
Small Sample Example
(continued)

Factory B has the smaller sample size, so


the test statistic is the sum of the
Factory B ranks:
T1 = 24.5

The sample sizes are:


n1 = 4 (factory B)
n2 = 5 (factory A)
The level of significance is  = .05
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-45
Wilcoxon Rank-Sum Test:
Small Sample Example
(continued)
 n1
 Lower and
n2 One- Two-
Upper 4 5
Critical Tailed Tailed
Values for 4
T1 from .05 .10 12, 28 19, 36
Appendix
.025 .05 11, 29 17, 38
table E.8: 5
.01 .02 10, 30 16, 39
.005 .01 --, -- 15, 40
6

T1L = 11 and T1U = 29


Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-46
Wilcoxon Rank-Sum Test:
Small Sample Solution
(continued)

  = .05 Test Statistic (Sum of


 n1 = 4 , n2 = 5 ranks from smaller sample):
Two-Tail Test T1 = 24.5
H0: M1 = M2
H1: M1  M2
Decision:
Reject Do Not Reject
Do not reject at  = 0.05
Reject
T1L=11 T1U=29 Conclusion:
There is not enough evidence to
Reject H0 if T1 ≤ T1L=11 prove that the medians are not
or if T1 ≥ T1U=29 equal.
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-47
Wilcoxon Rank-Sum Test
(Large Sample)
 For large samples, the test statistic T 1 is
approximately normal with mean μT and 1

standard deviation σ T : 1

n1 (n  1) n1 n2 (n  1)
μT1  σ T1 
2 12

Must use the normal approximation if either n1
or n2 > 10
 Assign n1 to be the smaller of the two sample sizes
 Can use the normal approximation for small samples
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-48
Wilcoxon Rank-Sum Test
(Large Sample)
(continued)

 The Z test statistic is


n 1 (n  1)
T1  μ T T1 
Z STAT  1
 2
σT n 1 n 2 (n  1)
1

12
 Where ZSTAT approximately follows a
standardized normal distribution

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-49


Wilcoxon Rank-Sum Test:
Normal Approximation Example

Use the setting of the prior example:


The sample sizes were:
n1 = 4 (factory B)

n2 = 5 (factory A)

The level of significance was α = .05

The test statistic was T1 = 24.5

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-50


Wilcoxon Rank-Sum Test:
Normal Approximation Example
(continued)
n1(n  1) 4(9  1)
μT1   20
2 2

n1 n 2 ( n  1 ) 4 ( 5 )( 9  1 )
σT   4.082
1 12 12

 The test statistic is


T1  μ T
24.5  20
Z STAT  1
 1.10
σT 4.0882
1

 Z = 1.10 is not greater than the critical Z value of 1.96


(for α = .05) so we do not reject H0 – there is not
sufficient evidence that the medians are not equal
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-51
Wilcoxon Signed Ranks Test
 A nonparametric test for two related populations
 Steps:
1. For each of n sample items, compute the difference,
Di, between two measurements
2. Ignore + and – signs and find the absolute values, |Di|
3. Omit zero differences, so sample size is n’
4. Assign ranks Ri from 1 to n’ (give average rank to
ties)
5. Reassign + and – signs to the ranks Ri
6. Compute the Wilcoxon test statistic W as the sum of
the positive ranks
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-52
Wilcoxon Signed Ranks
Test Statistic
 The Wilcoxon signed ranks test statistic is the
sum of the positive ranks:
n'
W  R ( )
i
i1

 For small samples (n’ < 20), use Table E.9 for
the critical value of W

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-53


Wilcoxon Signed Ranks
Test Statistic
 For samples of n’ > 20, W is approximately
normally distributed with

n' (n'1)
μW 
4

n' (n'1)(2n'1)
σW 
24

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-54


Wilcoxon Signed Ranks Test
 The large sample Wilcoxon signed ranks Z
test statistic is

n' (n'1)
W
Z STAT  4
n' (n'1)(2n'1)
24
 To test for no median difference in the paired
values:
H0: MD = 0
H1: MD ≠ 0
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-55
Kruskal-Wallis Rank Test
 Tests the equality of more than 2 population
medians
 Use when the normality assumption for one-
way ANOVA is violated
 Assumptions:
 The samples are random and independent
 Variables have a continuous distribution
 The data can be ranked
 Populations have the same variability
 Populations have the same shape

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-56


Kruskal-Wallis Test Procedure

 Obtain rankings for each value


 In event of tie, each of the tied values gets the
average rank
 Sum the rankings for data from each of the c

groups
 Compute the H test statistic

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-57


Kruskal-Wallis Test Procedure
(continued)

 The Kruskal-Wallis H-test statistic:


(with c – 1 degrees of freedom)

 12 c T2 
H   j
  3(n  1)
 n(n  1) j1 n j 
where:
n = sum of sample sizes in all groups
c = Number of groups
Tj = Sum of ranks in the jth group
nj = Number of values in the jth group (j = 1, 2, … , c)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-58


Kruskal-Wallis Test Procedure
(continued)

 Complete the test by comparing the


calculated H value to a critical 2 value from
the chi-square distribution with c – 1
degrees of freedom

 Decision rule
  Reject H0 if test statistic H > 2α
 Otherwise do not reject H0
0 
Do not Reject H0
reject H0
2α

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-59


Kruskal-Wallis Example

 Do different departments have different class


sizes?
Class size Class size Class size
(Math, M) (English, E) (Biology, B)
23 55 30
45 60 40
54 72 18
78 45 34
66 70 44

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-60


Kruskal-Wallis Example
(continued)
 Do different departments have different class
sizes?
Class size Class size Class size
Ranking Ranking Ranking
(Math, M) (English, E) (Biology, B)
23 2 55 10 30 3
41 6 60 11 40 5
54 9 72 14 18 1
78 15 45 8 34 4
66 12 70 13 44 7
 = 44  = 56  = 20

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-61


Kruskal-Wallis Example
(continued)

H 0 : Median M Median E Median B


H1 : Not all population Medians are equal

 The H statistic is
 c T2 
12

j 
H   3(n  1)
 n(n  1) nj 
 j 1 
 12  45.52 55.52 19 2 
       3(15  1) 7.12

 15(15  1)  5 5 5 


Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-62


Kruskal-Wallis Example
(continued)
 Compare H = 7.12 to the critical value from the
chi-square distribution for 3 – 1 = 2 degrees of
freedom and  = 0.05:
χ 02.05 5.991

2
Since H = 7.12 >0.05 5.991
χ
,
reject H0
There is sufficient evidence to reject that
the population medians are all equal
Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-63
Friedman Rank Test

 Use the Friedman rank test to determine


whether c groups (i.e., treatment levels) have
been selected from populations having equal
medians

H0: M.1 = M.2 = . . . = M.c

H1: Not all M.j are equal (j = 1, 2, …, c)

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-64


Friedman Rank Test
(continued)

 Friedman rank test for differences among c


medians:
c
12
FR  
rc(c  1) j1
R 2
.j  3r(c  1)

whereR.j2 = the square of the total ranks for group j

r = the number of blocks

c = the number of groups

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-65


Friedman Rank Test
(continued)

 The Friedman rank test statistic is approximated


by a chi-square distribution with c – 1 d.f.

2
Reject H0 if FR  χ α

Otherwise do not reject H0

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-66


Chapter Summary
 Developed and applied the 2 test for the difference
between two proportions
 Developed and applied the 2 test for differences in
more than two proportions
 Applied the Marascuilo procedure for comparing all
pairs of proportions after rejecting a 2 test
 Examined the 2 test for independence
 Applied the McNemar test for proportions from two
related samples
 Presented the 2 test for a variance or a standard
deviation

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-67


Chapter Summary
(continued)

 Used the Wilcoxon rank sum test for two


population medians
 Presented the Wilcoxon signed ranks test for
comparing paired samples
 Applied the Kruskal-Wallis H-test for multiple
population medians
 Applied the Friedman rank test for comparing
multiple population medians in a randomized
block design

Basic Business Statistics, 11e © 2009 Prentice-Hall, Inc.. Chap 12-68

You might also like