190 likes | 488 Views
Chi-Square Test and Goodness-of-Fit Testing. Ming-Tsung Hsu. Outline. Goal of Hypothesis Test Terms & Notation Chi-Square Test Goodness-of-Fit Testing Example. Goal of Hypothesis Test. To examine statistical evidence, and to determine whether it supports or contradicts a claim
E N D
Chi-Square Test and Goodness-of-Fit Testing Ming-Tsung Hsu OPLab@im.ntu.edu.tw
Outline • Goal of Hypothesis Test • Terms & Notation • Chi-Square Test • Goodness-of-Fit Testing • Example OPLab@im.ntu.edu.tw
Goal of Hypothesis Test • To examine statistical evidence, and to determine whether it supports or contradicts a claim • The life of lamps is more than 10,000 hours • The data are from normal distribution • To reduce the directly-relevant data to a “level of suspicion” based purely on the data OPLab@im.ntu.edu.tw
Terms & Notation • Null Hypothesis (H0) vs. Alternative hypothesis (H1 or HA) • Type I Error vs. Type II Error • Parametric Test vs. Non-Parametric Test • Significance level (α) and Critical Region • “Reject H0” vs. “Do not reject H0“ • Central Limit Theorem • Sampling distribution of the sample mean • Test Statistic vs. Table Value • P-value OPLab@im.ntu.edu.tw
Null Hypothesis vs. Alternative hypothesis OPLab@im.ntu.edu.tw
Type I Error vs. Type II Error • Type I error • H0 is true but reject H0 • Pr(reject H0 | H0) = α • Type II error • H1 is true but do not reject H0 • Pr(do not reject H0 | H1) = β OPLab@im.ntu.edu.tw
Parametric Test vs. Non-Parametric Test • Parametric Test • Parameters of population • Mean test, variance test, etc. • Non-Parametric Test • Make no assumptions about the frequency distributions of the variables being assessed • Independent test, distribution test, etc. OPLab@im.ntu.edu.tw
Significance level (α) and Critical Region OPLab@im.ntu.edu.tw
Central Limit Theorem OPLab@im.ntu.edu.tw
Test Statistic vs. Table Value OPLab@im.ntu.edu.tw
P-value OPLab@im.ntu.edu.tw
Chi-Square Test • Non-Parametric Test • T. S. ~χ2(ν) • Goodness-of-Fit Test • Also known as “Pearson's chi-square test” • Independent Test • Homogeneity Test OPLab@im.ntu.edu.tw
Goodness-of-Fit Testing • Used to test if a sample of data came from a population with a specific distribution Oi:Observations of ith group Ei:Expected frequency of ith group k:Number of groups m: Number of estimated parameters K-1-m: Degree of freedom OPLab@im.ntu.edu.tw
Example OPLab@im.ntu.edu.tw
Parameter Estimation - λ OPLab@im.ntu.edu.tw
Observations and Expected Frequencies ?! OPLab@im.ntu.edu.tw
Test Statistic and P-value OPLab@im.ntu.edu.tw
Observations and Expected Frequencies - Paper 18 OPLab@im.ntu.edu.tw
Re-Grouping # of groups = 1+3.322*log(n) OPLab@im.ntu.edu.tw