You are on page 1of 20

CHI SQUARE

TEST

Nina Farliana

Faculty of Economics, Universitas Negeri Semarang


CHI SQUARE TEST
• Chi square distribution is a hypothesis testing method
for differences of more than 2 proportions.

• Example: a company's marketing manager wants to


know whether the difference in the proportion of sales
of new products from his company in 3 different
marketing areas is caused by accidental factors or
because of other factors, so that the preference for
new products in the 3 marketing areas is different.
CHI SQUARE TEST

Purpose of chi square test


(Read: kai kuadrat):

1. goodness-of-fit test
2. contingency table test
goodness-of-fit test
• Functional alignment test aims:
• to find out whether the distribution of the results observed
in an experiment on a sample supports a distribution that
has been hypothesized in the population.
• To test whether the observed frequency is consistent with
the theoretical frequency? If it is consistent or there is no
significant difference, then the hypothesis is accepted
(accept Ho). Conversely, if there is no consistency, then
the hypothesis is rejected (accept Ha).
UJI TABEL KONTINGENSI
(uji independensi)

Contingency table test objectives:


• to find out whether the data are
cross-classified independently
(not tied to each other) or not.
HYPOTHESIS TESTING STEP

Test procedure:
1. H0 and Ha . statements
a. Functional alignment test
H0 : the population being studied meets / conforms to a specified
probability distribution pattern.
Ha : the studied population does not meet the specified distribution.
b. Contingency table test
H0 : the two variables being studied are independent of each other.
Ha: the two variables are not mutually independent or the two
variables are mutually dependent on each other / dependent
HYPOTHESIS TESTING STEP

2. Determination of the level of significance (level of significant) =


Usually used = 0.01 or = 0.05
3. Determination of H0 and Ha acceptance areas.
In this test, the chi squared probability distribution is presented in
tabular form, which can be determined by knowing:
- In the function alignment test: df = k – 1
where k = number of outcomes/observations
- In the contingency table: df = (r -1)(c-1)
Where r = number of rows in table
c = number of columns in table
HYPOTHESIS TESTING STEP

4. The limits of the rejection area / critical limits of the test


for example from the table for = 0.01; df = 3-1 = 2; obtained
chi square = 9.21
5. Decision rules:
Reject Ho and accept Ha if RU (test ratio) chi squared >
9.21.
If not, then accept H0
6. Calculation of test ratio
7. Decision making
CHI SQUARE TEST
 The chi square test is used to test two groups of data,
both independent and dependent variables are categori-
cal
 It is also said to be a proportion test for two or more
events, so that the data are discrete.
 The basis of the chi square test is to compare the differ-
ence in the observed frequency (O) with the expected
frequency (E).
 The difference is convincing if the value of the chi square
is equal to or greater than a specified value at a certain
significant level (from table 2).
CHI SQUARE TEST

Uji chi square dapat digunakan untuk menguji:

1. Uji χ2 untuk ada tidaknya hubungan antara


dua variabel (Independency test)
2. Uji χ2 untuk homogenitas antar- sub
kelompok (Homogenity test).
3. Uji χ2 untuk Bentuk Distribusi (Goodness of
Fit
CHI SQUARE TEST

Keterangan :
O = frekuensi hasil observasi
E = frekuensi yang diharapkan.
Nilai E = (Jumlah sebaris x Jumlah Sekolom) / Jumlah data
df = (b-1) (k-1)
SYARAT CHI SQUARE TEST

1. Sampel dipilih secara acak


2. Semua pengamatan dilakukan dengan independen
3. Setiap sel paling sedikit berisi frekuensi harapan
sebesar 1 (satu). Sel-sel dengan frekuensi
harapan kurang dari 5 tidak melebihi 20% dari
total sel
4. Besar sampel sebaiknya > 40 (Cochran, 1954)
EXAMPLE CASE
Suatu survey ingin mengetahui apakah ada hubungan
Asupan Lauk dengan kejadian Anemia pada penduduk
desa X. Kemudian diambil sampel sebanyak 120 orang
yang terdiri dari  50 orang asupan lauknya baik dan
70 orang asupan lauknya kurang. Setelah dilakukan
pengukuran kadar Hb ternyata dari 50 orang
yang asupan lauknya baik, ada 10 orang yang
dinyatakan anemia. Sedangkan dari 70 orang
yang asupan lauknya kurang ada 20 orang yang
anemia.

Ujilah apakah ada perbedaan proporsi anemia pada kedua


kelompok tersebut.
ANSWER: EXAMPLE CASE
1. HIPOTESIS :
Ho : P1 = P2 (Tidak ada perbedaan proporsi anemia pada
kedua kelompok tersebut)
Ha : P1 ≠ P2 (Ada perbedaan proporsi anemia pada kedua
kelompok tersebut)
2. PERHITUNGAN :
Untuk membantu dalam perhitungannya kita membuat tabel
silangnya seperti ini :
ANSWER: EXAMPLE CASE

 Menentukan nilai observasi (O) dan nilai ekspektasi (E) :


ANSWER: EXAMPLE CASE

 Masukkan ke rumus
ANSWER: EXAMPLE CASE
Perhitungan selesai, sekarang kita menentukan nilai tabel pada
taraf nyata/alfa = 0.05. Sebelumnya kita harus menentukan nilai
df-nya. Karena tabel kita 2x2, maka nilai df = (2-1)*(2-1)=1.

Dari tabell kai kudrat di atas pada df=1 dan alfa=0.05 diperoleh
nilai tabel = 3.841.
ANSWER: EXAMPLE CASE
KEPUTUSAN STATISTIK
Bila nilai hitung lebih kecil dari nilai tabel, maka Ho gagal ditolak,
sebaliknya bila nilai hitung lebih besar atau sama dengan nilai tabel,
maka Ho ditolak.

Dari perhitungan di atas menunjukan bahwa χ2 hitung <  χ2 tabel,


sehingga Ho gagal ditolak.

KESIMPULAN dan INTERPRETASI HASIL


Tidak ada perbedaan yang bermakna proporsi antara kedua
kelompok tersebut. Atau dengan kata lain tidak ada hubungan
antara asupan lauk dengan kejadian anemia.
Langkah-langkah Uji Chi Square dengan SPSS 
1. Input data pada “Data View”
2. Edit “Variable View”  edit menu “Value”
3. Klik menu “Analyze”  Descriptive Statistic
 Crosstabs
4. Klik menu “Statistic”  pada kolom
crosstabs statistic centang (V) “Chi Square”
 klik Continue
5. Klik Ok
Thanks for attention

You might also like