Professional Documents
Culture Documents
LT07 SPSS Kiem Dinh Gia Thuyet
LT07 SPSS Kiem Dinh Gia Thuyet
HYPOTHESIS TESTING
/haɪˈpɑː.θə.sɪs ˈtes.tɪŋ/
1
Sample vs. Population
3
Kiểm
4
định Chi-Square
Sample vs. Population
https://towardsdatascience.com/what-is-the-difference-between-population-and-
sample-e13d17746b16
Sample vs. Population
http://sphweb.bumc.bu.edu/otlt/MPH-
Modules/BS/BS704_BiostatisticsBasics/BS704_BiostatisticsBasics2.html
NHU CẦU KIỂM ĐỊNH
• Khi nghiên cứu, chúng ta thường chọn tập mẫu để khảo sát.
• Với kết quả thu thập được chúng ta tính toán các thông số của từng biến.
• Câu hỏi đặt ra là: Liệu kết quả thu được là do sự lựa chọn ngẫu nhiên hay có
mối liên hệ gì giữa các biến hay không?
• Ví dụ: Which holiday do you prefer?
Gender Beach Cruise
Men 209 280
Women 225 248
• Nếu Gender có ảnh hưởng đến lựa chọn loại hình du lịch, ta nói chúng phụ
thuộc nhau (dependent variables).
NHU CẦU KIỂM ĐỊNH
Gender Beach Cruise
Men 209 280
Women 225 248
p<0.05 thường
Bằng cách nào được dùng để kiểm
đó chúng ta tính định sự độc lập
được p=0.132
Is it likely you
would get
such different
results
surveying Men
each time?
Với giá trị p=0.132, ta nói chuyện
đó có thể xảy ra thường xuyên
GIÁ TRỊ p
• Việc chọn mẫu là ngẫu nhiên nên kết quả khảo sát cũng ngẫu nhiên.
• Chắc chắn phải có sai khác đôi chút giữa các lần khảo sát.
• Hầu hết mọi người cho rằng p<0.05 là đủ để kết luận các nhóm có câu trả
lời khác nhau (không phụ thuộc nhau - độc lập nhau).
GIÁ TRỊ p
• Ví dụ: Which pet do you prefer?
https://luminousmen.com/post/demystifying-hypothesis-testing
CHI-SQUARE TEST
Cat Dog
Men 207 282 489
Add up rows and columns:
Women 231 242 473
Cat Dog
489×438 489×524
Men 489
962 962
473×438 473×524
Women 473
962 962
438 524 962
Cat Dog
Men 222.64 266.36 489
Cat Dog
Chi-Square is 4.102
CHI-SQUARE TEST
Degree of Freedom = (rows − 1) × (columns − 1)
OR:
p value is 0.04283
In this case p < 0.05, so this result is thought of as being "significant" meaning
we think the variables are not independent.
https://www.mathsisfun.com/data/chi-square-calculator.html
BÀI TẬP
500 students in Grade 8 were asked, "Which do you like best - Pop music or
Rock music?"
The results were:
A. The result is significant and gender does affect the choice of color.
B. The result is significant and gender does not affect the choice of color.
C. The result is not significant and gender does affect the choice of color.
D. The result is not significant and gender does not affect the choice of color.
BÀI TẬP
A sample of people of different ages were asked whether or not they wear
glasses for reading, with the following results:
Does age group affect whether or not people wear glasses for reading?
KHÁI NIỆM ĐỘC LẬP
• Hai biến độc lập khi hoàn toàn không có liên quan với nhau.
• Hệ số tương quan (coefficient of correlation) = 0
• Nếu A và B độc lập thì:
• P(A & B) = P(A) x P(B)
https://sciencenotes.org/independent-and-dependent-variables-examples/
MỤC ĐÍCH CỦA CHI-SQUARE
• Khai thác khái niệm độc lập
• Kiểm định sự độc lập giữa hai biến
• Nếu hai biến không độc lập => có liên quan (association).
KIỂM ĐỊNH Ý NGHĨA THỐNG KÊ
• Triết lý phản biện của Popper
• Bước 1: Phát biểu giả thuyết vô hiệu (null hypothesis).
• Bước 2: Thu thập dữ liệu (D)
• Bước 3: Tính xác suất D xảy ra nếu giả thuyết vô hiệu đúng.
https://www.youtube.com/watch?v=misMgRRV3jQ
TYPE I AND TYPE II ERRORS
https://www.simplypsychology.org/type_I_and_type_II_errors.html
TYPE I AND TYPE II ERRORS
Correct inference
Type II error
Don't (true
(false negative)
reject negative)(probab
(probability = β)
Decision ility = 1−α)
about null
hypothesis (H0)
Type I error Correct inference
Reject (false positive) (true
(probability = α) positive)(probabil
ity = 1−β)
https://en.wikipedia.org/wiki/Type_I_and_type_II_errors
TYPE I AND TYPE II ERRORS
https://medium.com/@neeraj.kumar.iitg/statistical-performance-measures-
12bad66694b7
HỎI ĐÁP