Escolar Documentos
Profissional Documentos
Cultura Documentos
This expression is derived from the formula for the expected value of a
binomial random variable.
Example
If the expected frequencies and the observed frequencies are
quite different, we would conclude that the null hypothesis is
false, and we would reject it.
12-8
Goodness of fit test for
multinomial population
Goodness of fit
1) The multinomial distribution can be thought of as a generalization
of the binomial distribution to more than two (say, k) categories.
2) Hypothesis to be tested:
H0: p1 = p10, p2 = p20, ... , pk = pk0
H1: at least one inequality i.e. pi pi0
2
k
Oi Ei
2
~ k21
obs
i 1 Ei
Oi : Observed frequency
Ei npi : Expected frequency
LO 12.1
The ei (Expected Frequencies)
We first compute the expected counts based
on the survey of 250 restaurant patrons.
LO 12.1
Computing the Deviations
In the first category e1 = 37.5 and o1 = 46, so we get
(o1 e1) = ___.
LO 12.1
Standardizing the Deviations
LO 12.1
The Chi-Square Test
LO 12.1
The Critical Value (at = .05)
LO 12.1
The Restaurant Example
LO 12.1
The Restaurant Example
Observed Expected ( oi - ei )2
Response Percentage This Year Out of 250 ________
Category Last year ( oi ) ( ei ) ( oi - ei ) ei
Excellent 15% 46 37.5 8.5 1.927
Good 30% 83 75.0 8.0 0.853
Fair 45% 105 112.5 -7.5 0.500
Poor 10% 16 25.0 -9.0 3.240
TOTAL 100% 250 250 0.0 6.520
LO 12.1
Chi-Square Test of Independence
The Chi-Square (2) Test of Independence is used
to determine whether two factors or traits
(qualitative characteristics) are related to one
another
Introductory Case
Does the brand of compression garment
purchased depend on the customers age?
Brand Name
Age Group Under Armor Nike Adidas
Under 35 years 174 132 90
35 years and older 54 72 78
LO 12.2
Introductory Case: Notation
We use the notation oij to denote the observed
frequency in row i of column j.
LO 12.2
Introductory Case:
The Chi-Square Statistic
We apply the chi-square test statistic in a similar
manner as in the goodness-of-fit test. The
formula is as follows:
(oij eij ) 2
2
df ,
i j eij
LO 12.2
Introductory Case:
Computing Expected Frequencies
Brand Name Row
Age Group Under Armor Nike Adidas Totals
Under 35 years 174 132 90 396
35 years and up 54 72 78 204
Column Totals 228 204 168 600
LO 12.2
Introductory Case: Squared Deviations
We square each deviation and divide by the
respective expected frequency. These values
are shown in the following table.
Brand Name
Age Group Under Armor Nike Adidas
Under 35 years 3.68 0.05 3.93
35 years and up 7.14 0.10 7.63
LO 12.2
Introductory Case:
Summarizing the Example
Competing Hypotheses:
H0: brand choice does not depend on customers age
HA: brand choice depends on customers age
2
df ,
i j eij
where df = (r 1)(c 1) = (2 - 1)(3 - 1) = 2.
LO 12.2
Introductory Case:
Summarizing the Example
We reject H0 because the value of the test
statistic is larger than the critical value:
22.53 > 5.991. Therefore, age and brand name
are not independent of one another.
LO 12.2
Theoretical Background
Two characters, R and C, are independent if: P(RC) =
P(R)P(C)
Hypotheses :
H0: pij = pi.p.j for all i,j combinations
pij is estimated by p i 0 p 0 j
The Test Statistic
obs
2
(Oij Eij ) 2 / Eij
i j
(Oij npi 0 p0 j ) / np i 0 p 0 j
2
i j
fi0 f0 j
where Eij np i 0 p 0 j
n
Critical Region
Reject H0 if and only if