Hypothesis Testing SUNU WIBIRAMA Basic Probability and Statistics Department of Electrical Engineering and Information Technology Faculty of Engineering, Universitas Gadjah Mada
CONTENTS 8.1 Introduc-on 8.2 Formula-ng Hypotheses 8.3 Types of errors for a Hypothesis Test 8.4 Rejec-on Regions
8.1 Introduc-on In this chapter we will study another method of inference- making: hypothesis tes-ng. Making a decision about a parameter value Consis>ng of two kinds: Correla>onal hypothesis tes>ng Compara>ve hypothesis tes>ng Problem Popula>on Sample Conclusion Hypothesis
8.2 Formula-ng Hypothesis 1. State the rela>onship between two or more variables 2. Declara>on sentence 3. Constructed systema>cally 4. The truth should be tested empirically 5. Use sta-s-cal tes-ng to derive decision (z- distribu>on, t- distribu>on, chi- square, F, etc)
Important Steps! 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Important Steps (1) 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Null hypothesis (H 0 ) H 0 states that: Two or more variables are not related each other No difference between two or more variable Examples: There is no rela>onship between rain fall and electricity connec>on Monthly income is not related with preference of buying gadget There is no difference of GPA between ac>vists and non ac>vists
Alterna-ve hypothesis (H a or H 1 ) H a states that: Two or more variables are closely related there is difference between the 1 st variable and the 2 nd variable Examples: Rain fall and electricity connec>on are closely related Monthly income and preference of buying gadget are closely related There is significance difference of GPA between ac>vists and non ac>vists
Important Steps (2) 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Significant Level Define the limit of confidence level for your H 0 Noted by alpha (α) symbol α = 1%, α = 5%, α = 10%, etc
Important Steps (3) 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Sta-s-cal Tes-ng Big Sample (n 30 Z = Statistik sampling distribution! Parameter population! sampling distribution Small Sample (n < 30) t = Statistik sampling distribution! Parameter population! sampling distribution
Implementa-on (see previous lectures) Tes>ng with only one mean: Z h = x! µ! x! x =! n Standard deviation of sampling distribution or Standard Error Comparing means of two sampling distribu>on x Z h = 1! x 2! 1 2 2 n 1 +! 2 n 2
One- tail tests Right Tail H 0 : μ = μ 0 H a : μ > μ 0 Reject H 0 : Z h α t h α,n-1 Accept H 0 : Z h α t h α,n-1 Leb Tail H 0 : μ = μ 0 H a : μ < μ 0 Reject H 0 : Z h α t h α,n-1 Accept H 0 : Z h α t h α,n-1
Two Tail Tests H 0 : μ = μ 0 H a : μ μ 0 Reject H 0 : Z h α Z h α t h α,n-1 t h α,n-1 Accept H 0 : - α Z h α - α Z h α
Important Steps (4) 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Decision Making Conclusion Accept H 0 Reject H 0 Hypothesis H 0 true H 0 false Correct Decision Probability 1- α Error Type II Probability β Error Type I Probability α Correct Decision Probability 1- β Probability of error type I occurred significant level Example: α = 5% à probability that we make error type I : 5% (95% our decision tend to be correct)
Important Steps (5) 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Final Decision Should be stated clearly Answering the problem Examples: It was true that no rela>onship between rain fall and electricity connec>on Monthly income is proven not related with preference of buying gadget
LET SEE THE EXAMPLE
Contoh 1 Surat kabar X menyatakan bahwa mahasiswa JTETI UGM rata- rata sebulan mengeluarkan pengeluaran sebulan Rp.400.000,-. Seorang dosen mensinyalir bahwa pengeluaran rata- rata mahasiswa JTETI UGM tersebut terlalu besar.untuk itu ia mengambil sampel 25 mahasiswa untuk mengujinya. a. Dari hasil sampel, ternyata diperoleh rata- rata Rp. 390.000,- dengan standard deviasi Rp.25.000,-. Jika pengujian menggunakan taraf signifikansi 5%, benarkah pernyataan surat kabar X tersebut? b. Jika dosen tersebut mengambil sampel sebanyak 100
Important Steps! 1. Define Null Hypothesis (H 0 ) and Alterna>ve Hypothesis (H a ) 2. Define significant level (α) 3. Define sta>s>cal method / tes>ng criteria (using Z- Distribu>on, t- Distribu>on, Chi- Square, F, etc.) 4. Decision making: Accept or reject hypothesis 5. Declare the final conclusion
Contoh 2 Sebuah perusahaan listrik mendapat keluhan konsumen yang meragukan besarnya tegangan listrik perumahan tepat 220 V. Guna menanggapi keluhan tersebut, perusahaan tersebut melakukan peneli>an terhadap 100 rumah. Ternyata tegangan rata- rata sebesar 215 V dengan penyimpangan standard sebesar 5 V. Dengan menggunakan taraf nyata 10%, apakah keraguan konsumen terhadap isi besaran tegangan itu benar?