0% found this document useful (0 votes)
8 views4 pages

11 Chi Square

Uploaded by

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

11 Chi Square

Uploaded by

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

MMW GEC 004 Mathematics in the Modern World 01-19-2025 04:12:20 AM

UNIVERSITY OF CALOOCAN CITY


South: Biglang Awa St. cor Cattleya St, 12th Avenue East, Caloocan City
North: Congressional Road, Bagumbong, Caloocan City
College of Liberal Arts & Sciences

CHI-SQUARE Distribution

Certain statistical tests need normality of distribution before such tests can be used. The Z test and T test, as well as F test are
just some of these tests. Such tests are known as parametric tests. However, there are some statistical tests which do not require this
basic assumption of normality of distribution before they could be used. These are classified as nonparametric tests. Chi-square is a
nonparametric test for data presented in frequencies, or data which can be transformed to frequencies.
1. Tests for Goodness-of-Fit
Chi-square test can be utilized to know whether the set of observed frequencies on one variable will be the same as expected
frequencies on the same variable. This is known as the test for goodness-of-fit. The Chi-square goodness-of-fit test can also be used
to test the normality of data. To illustrate this, a one-peso coin is tossed 200 times to test whether this coin is fair or loaded and the
result of the experimentation was recorded below.

No. of Occurrence of Head No. of Occurrence of Tail Total


Observe frequencies 109 91 200
Expected frequencies 100 100 200
Since there are only two possible outcomes for the experiment on tossing a coin, e.i., heads and tail, the probability of getting a
head and the probability of getting a tail are equal for the coin to be fair. Thus, the expected frequency for the head is 200 (1/2 or
simply 100, and the expected frequency for the tail will also be 200 (1/2) or 100. We must compare the observed frequencies to
know if the coin is really fair. To perform this, the chi-square formula will be used, i. e.

( OF−EF )2
X2 = ∑
EF
where :
OF = observed frequencies
EF = expected frequencies

We have the usual procedure to test a hypothesis. Below are the steps:
1. H0: p = ½
2. Ha: p ≠ ½
3. α = 0.05
4. Test Statistics
2 ( OF−EF )2
X =∑
EF
df =n-1= 2-1=1
Where n represents the number of categories.
C.V. = 3.84 from X2 Distribution
5. Computation:
OF EF (OF - EF) (OF - EF)2 (OF - EF)2/EF
Head 109 100 9 81 0.81
Tail 91 100 –9 81 0.81
Total 200 200 X2 = 1.62
6. Decision: Accept Ho and reject H1, since /1.62/ is less than /3.84/. Thus, the coin is fair at the 0.05 level of significance.
Another example worth mentioning for testing goodness-of-fit is testing whether a die is loaded or fair, that the chances of
a boy and a girl among 50 deliveries are fair.
Testing for goodness-of-fit is one of the many applications of the chi-square. Another application is the test of independence.
The hypothesis is to be tested here is whether the two variables are independent of each other. Contingency tables in this case may be
made upon of any number of rows (r) and any number of columns (c). examples of these may be placed on the following contingency
tables with their corresponding degrees of freedom, like:
1 x c = one row with several columns df = c - 1
2 x 2 = two rows and two columns df = (2 - 1) (2 - 1)
Edited 2nd sem 2024-25
Perry Boy Rolan
Mr. PORFERIO I. ROLAN
(Asst. Instructor)
Page 1 of 4
MMW GEC 004 Mathematics in the Modern World 01-19-2025 04:12:20 AM
r x c = r rows and c columns df = (r - 1) (c - 1)

2. Computation of Expected Frequencies


To show how expected frequencies are obtained, let us consider the contingency table provided for below.
OBSERVED FREQUENCY EXPECTED FREQUENCY
XQ XR XS
A B C X X
T T T
YQ YR YS
D E F Y Y
T T T
ZQ ZR ZS
G H I Z Z
T T T
Q R S T Q R S T

An example of a 3 x 3 contingency table is illustrated in the figure above. Letters A, B, C, D, E, F, G, H and I represent the
observed frequencies in each cell, while letters X, Y, and Z are the total observed frequencies per row, letters Q, R and S are the total
observed frequencies per column and T is the total number of observed frequencies. To obtain the expected frequency per cell, for
instance, the expected frequency for A, we multiply X by Q and divide the product by T. The computation of the expected frequencies
for the other cells are summarized on the other r x c contingency tables for expected frequency.

Let us use these to the following example.


EXAMPLE 1
The following results were obtained in a survey conducted with college students on the prohibited drug issue.

OPINION
SEX
Agree Disagree
Male 28 122
Female 20 140
Do the responses of two groups differ using the 0.05 level?
Solution:
1. H0: The responses of the two groups do not differ.
2. Ha: The responses of the groups differ.
3. α = 0.05
4. Test Statistics:

X2 =∑
( OF−EF 2 )
EF
df = (2 - 1)(2 - 1) = 1
C.V. = 3.84
5. Computation:
Opinion
Agree Disagree Total
Sex
Male 28 122 150
Female 20 140 160
Total 48 262 310
Expected frequencies for:

(150)( 48) (150)(262)


28: = 23.23 122: = 126.77
310 310
(160)( 48) (160)(262)
20: = 24.77 140: = 135.23
310 310
Therefore,
Edited 2nd sem 2024-25
Perry Boy Rolan
Mr. PORFERIO I. ROLAN
(Asst. Instructor)
Page 2 of 4
MMW GEC 004 Mathematics in the Modern World 01-19-2025 04:12:20 AM

OF EF (OF - EF) (OF - EF)2 (OF - EF)2/EF


28 23.23 4.77 22.7529 0.9795
122 126.77 - 4.77 22.7529 0.1795
20 24.77 - 4.77 22.7529 0.9186
140 135.23 4.77 22.7529 0.1683
X2 = 2.2459

6. Decision: Accept H0 and reject Ha since /2.2459/ is less than 3.84. Therefore, the responses of the two groups
differ at the 0.05 level.

Exercises
NAME: SCORE:
COURSE/YR. & SEC: DATE:
STUDENT No. TIME: DAY:

A study was made to know if hypertension is independent of the drinking habits of 200 male respondents in a certain locality,
as shown from the table below

Nondrinker Moderate drinker Heavy drinker


Hypertension 20 42 54
No Hypertension 49 20 15

Does hypertension is independent of drinking habits using 0.05 level of significance?


Solution:
1. H0:
2. Ha:
3. α = 0.05
4. Test Statistics:

X2 =∑
( OF−EF 2 )
EF
df = (r - 1)(c - 1) =
C.V. = 5.99
5. Computation:

Nondrinker Moderate drinker Heavy drinker Total


Hypertension 20 42 54
No Hypertension 49 20 15
Total

Expected frequencies for. Therefore,

OF EF (OF - EF) (OF - EF)2 (OF - EF)2/EF


20
42
54
49
20
15
X2 = ___________

6. Decision:

Edited 2nd sem 2024-25


Perry Boy Rolan
Mr. PORFERIO I. ROLAN
(Asst. Instructor)
Page 3 of 4
MMW GEC 004 Mathematics in the Modern World 01-19-2025 04:12:20 AM

Edited 2nd sem 2024-25


Perry Boy Rolan
Mr. PORFERIO I. ROLAN
(Asst. Instructor)
Page 4 of 4

You might also like