You are on page 1of 8

Hypotheses Tests for association

Test of association tests whether or not any two categorical


variables are related to each other based on sample observations for
instance:
We may wish to test whether students’ choice of a degree program
has anything to do with gender
The two variables are ‘gender’ and ‘choice of degree program’
 So we ask ourselves, “Are there differences in choice of degree
program between male and female students?”
The test will be able to tell you if choice of a degree program and
gender are correlated but will not tell you directly what programs
are most favored by men or by women for that matter

Tests for association


If the variables are related, we say that they are associated
and therefore not independent
Hypothesis testing is involved, you should follow the basic
steps of hypothesis testing
The tests are based on the Chi-squared tests model
(classified under nonparametric statistical tests?)
We seek to establish the Chi-squared test and critical
statistics based on the sample evidence
Tests for association
Contingency table:
Degree program
Gender Economics Psychology
Female 117 63
Male 24 56
Please take note that the two categorical variables under study are:
Gender (either Male or Female) and Degree choice (Economics or
Psychology)
Is there an association between gender and the choice of degree
program? Use a 5% level of significance to test for this.

Tests for association


H0: variables are not associated (independent)
H1: variables are associated (not independent)
 The experimental data are presented in the form of a table called a
contingency table
 A contingency table gives the frequency for two or more variables
simultaneously
It has rows and columns of observations for instance:
A survey of first year university students sought to establish any
association between choice of degree program and gender.
Assuming only two degree programs were on offer, the following
results were obtained:
Tests for association-Suggested solution

Tests for association-Suggested solution


Tests for association-Suggested solution
How do we compute expected frequencies (Ei)?
Let us present the sample evidence with row and column totals:
Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260
Column, row and overall totals are as shown in the table

Tests for association-Suggested solution


Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260
Tests for association-Suggested solution
How do we compute expected frequencies (Ei)?
Let us present the sample evidence with row and column totals:
Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260
Column, row and overall totals are as shown in the table

Tests for association-Suggested solution


Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260
Tests for association-Suggested solution
Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260

Tests for association-Suggested solution


Degree program TOTALS
Gender Economics Psychology
Female 117 63 180
Male 24 56 80
TOTALS 141 119 260
Tests for association-Suggested solution
Now we can present the table with both observed
frequencies and their expected frequencies as follows: what
was observed is not exactly as what was expected-there are
deviations!
Oi Ei
117 97.6154
63
24 43.3846
56
260 260

Tests for association-Suggested solution

Oi Ei

117 97.6154 375.7627 3.8494


63 375.7627 4.5611
24 43.3846 375.7627 8.6612
56 375.7627 10.2624

260 260 27.3341


Tests for association-Suggested solution

Tests for association-Practice question


A national motor vehicle distributor wishes to find out if the size of
the car bought is related to the age of the buyer. From the sales
transactions over the past two years, a random sample of buyers were
classified by size of car bought and buyer’s age. Assist this firm by
performing a statistical test using α=0.01.
Car size
Buyer’s age
Small Medium Large
Under 30 years
10 22 34
30 to 45
24 42 48
Over 45
45 35 40

You might also like