Analisis Chi-Square (x 2 ) Chi square ("χ 2 " dari huruf Yunani "Chi "Kai") to determine if data good or not. Expl... to determine possible outcomes for genetic crosses. How will we know if our fruit fly data is good? Black x F1: all wild wild Jika F1 X F1 menghasilkan F2 dengan Rasio : 9:3:3:1? 5610: 9 1896:3 1881:3 622: 1
The chi-square distribution can be used to see whether or not an observed counts agree with an expected counts. (Ringkas: data sesuai harapan/teori atau tidak) O = observed count (Observasi) E = Expected count (harapan) 2 ( O E ) 2 E For testing significance of patterns in qualitative data based on counts that represent the number of items that fall in each category measures the agreement between actual counts and expected counts assuming the null hypothesis
Rumus dasar dari uji Kai Kuadrat adalah : 2 ( O E ) 2 E Keterangan : O = frekuensi hasil observasi E = frekuensi yang diharapkan. Nilai E = (Jumlah sebaris x Jumlah Sekolom) / Jumlah data Derajat bebas: df = (b-1) (k-1) Uji Kai Kuadrat dapat digunakan untuk menguji : 1. Uji χ 2 : ada tidaknya hubungan antara dua variabel (Independency test). 2. Uji χ 2 : homogenitas antar- sub kelompok (Homogenity test). 3. Uji χ 2 : untuk Bentuk Distribusi (Goodness of Fit)
Tahapan Uji Hipotesis 1. Nyatakan Hipotesis null (Ho = Specifies a distribution of proportions) there is no substantial statistical deviation between observed and expected data. Research (H1= Specifies that the distribution will be different than that indicated in the null hypothesis 2. Select an alpha level and determine the critical value ( pada tabel distribusi chi-square) 3. Hitung test statistik: 4. Make a decision (Kesimpulan). 2 ( O E ) 2 E
Calculating the test statistic Observed frequencies (Observasi) the number of individuals from the sample who are classified in a particular category f o Expected frequencies (Harapan) the number of individuals from the sample who are expected to be classified in a particular category f e
Hitungan Contoh Sederhana: Pelemparan mata uang : What percentage of people will predict heads? tails? Heads Percentages 50% Tails 50% Proportions.5.5 Expected frequency = f e = pn n = 50 (sample size) f e =.5 x 50 = 25 Expected Heads Tails Proportions.5.5 Frequencies 25 25
Calculating the test statistic Heads Tails Observed 35 15 Expected 25 25 x 2 = (f o - f e ) 2 f e Steps 1. find the difference between f o and f e for each category 2. square the difference 3. divide the squared difference by f e 4. sum the values from all categories
Observed (f o ) Expected (f e ) Heads Tails 35 15 25 25 f o - f e 10-10 (f o - f e ) 2 100 100 (f o - f e ) 2/ f e 4 4 Membuat Kesimpulan: Critical value = 3.84 (with df = 1 and =.05) Observed chi square = 8.0 8.0 > 3.84 We reject the null hypothesis Goodness of fit Hitungan: x 2 = (f o - f e ) 2 = 4 + 4 = 8 f e Conclude that category frequencies are different People were more likely to predict heads than tails
Contoh Soal : Hasil observasi suatu data percobaan HITUNGAN TEST STATISTIK 2 statistic formula Observed Frequency Expected Frequency H 40 50 T 60 50 -------------------------------------------------------- Jumlah 100 100 2 2 O E ( ) E 2 2 ( 40 50) ( 60 50) 50 50 2 2 ( 10 10 100 100 ) ( ) 50 50 50 50 2 2 4
Data Observed Expected Die Frequency Frequency -------------------------------------------------------- 1 4 10 2 6 10 3 17 10 4 16 10 5 8 10 6 9 10 =============================== Jumlah 60 60 2 2 O E ( ) E 2 2 ( 4 10 6 10 ) ( ) 10 10 ( 17 10) ( 16 10) 10 10 2 2 ( 8 10) ( 9 10) 10 50 14. 2 2 HITUNGAN TEST STATISTIK statistic formula 2 2
Tabel: Critical values for chi square distribution Critical value (df = 1, =.05) = 3.84 Catatan: Setiap mahasiswa harus punya tabel lengkap. Chi-square
(3.1).Chi-Square (tes independensi) : menguji apakah ada hubungan antara baris dengan kolom pada sebuah tabel kontingensi. Data yang digunakan adalah data kualitatif. (O E) 2 X 2 = Σ Di mana E O = skor yang diobservasi E = skor yang diharapkan (expected) Contoh : Terdapat 20 siswa perempuan dan 10 siswa laki-laki yang fasih berbahasa Inggris, serta 10 siswa perempuan dan 30 siswa laki-laki yang tidak fasih berbahasa Inggris. Apakah ada hubungan antara jenis kelamin dengan kefasihan berbahasa Inggris? Ho = tidak ada hubungan antara baris dengan kolom H1 = ada hubungan antara baris dengan kolom a Fasih c Tidak fasih Σ P b d L Σ O E (O-E) (O-E) 2 (O-E) 2 /E a 20 (a+b)(a+c)/n b 10 (a+b)(b+d)/n c 10 (c+d)(a+c)/n d 30 (c+d)(b+d)/n df = (kolom 1)(baris 1) Jika X 2 hitung < X 2 tabel, maka Ho diterima Jika X 2 hitung > X 2 tabel, maka Ho ditolak
contoh soal peternakan
CHI-SQUARE DISTRIBUTION TABLE Accept Hypothesis Reject Hypothesis Probability (p) Degrees of Freedom 0.95 0.90 0.80 0.70 0.50 0.30 0.20 0.10 0.05 0.01 0.001 1 0.004 0.02 0.06 0.15 0.46 1.07 1.64 2.71 3.84 6.64 10.83 2 0.10 0.21 0.45 0.71 1.39 2.41 3.22 4.60 5.99 9.21 13.82 3 0.35 0.58 1.01 1.42 2.37 3.66 4.64 6.25 7.82 11.34 16.27 4 0.71 1.06 1.65 2.20 3.36 4.88 5.99 7.78 9.49 13.38 18.47 5 1.14 1.61 2.34 3.00 4.35 6.06 7.29 9.24 11.07 15.09 20.52 6 1.63 2.20 3.07 3.83 5.35 7.23 8.56 10.64 12.59 16.81 22.46 7 2.17 2.83 3.82 4.67 6.35 8.38 9.80 12.02 14.07 18.48 24.32 8 2.73 3.49 4.59 5.53 7.34 9.52 11.03 13.36 15.51 20.09 26.12 9 3.32 4.17 5.38 6.39 8.34 10.66 12.24 14.68 16.92 21.67 27.88 10 3.94 4.86 6.18 7.27 9.34 11.78 13.44 15.99 18.31 23.21 29.59