note16 - STAT5044: Regression and Anova Inyoung Kim 1 / 37...

Info iconThis preview shows pages 1–10. Sign up to view the full content.

View Full Document Right Arrow Icon
STAT5044: Regression and Anova Inyoung Kim 1 / 37
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Outline 1 Test of goodness- of- fit 2 Test of independence 3 Test of homogeneity 2 / 37
Background image of page 2
Test of goodness-of-fit: Test whether the data come from a multinomial (or binomial) distribution Test of independence: Test whether two categoricl variables, measured from a randpm sample, are independence of each other. Test of homogeneity: Test whether two random samples of categorical data have the same distribution. 3 / 37
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Introduction To test whether a coin is biased, we flip a coin 100 times and observe the number of heads. Denoting π = Pr ( Head ) , we can write H 0 : π = 0 . 5 vs H a : π 6 = 0 . 5. Test statistic Z = ˆ π - π q π ( 1 - π ) n N ( 0 , 1 ) under H 0 asymotitically. Decision Rule: reject H 0 if | Z | > Z α / 2 4 / 37
Background image of page 4
Introduction Consider the distribution of Z 2 which has an approximately a chi-square dist with 1 df. Rewrite Z 2 in the following form: Z 2 = ( n ˆ π - n π ) 2 n π ( 1 - π ) = ( n ˆ π - n π ) 2 n π + ( n ˆ π - n π ) 2 n ( 1 - π ) and by letting π 2 = 1 - π , ˆ π 2 = 1 - ˆ π and recognizing ( n ˆ π - n π ) 2 = ( n ˆ π 2 - n π 2 ) , Z 2 = ( n ˆ π - n π ) 2 n π + ( n ˆ π 2 - n π 2 ) 2 n π 2 χ 2 1 5 / 37
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Introduction More generally, we can think of an experiment having k ( 2 ) mutually exclusive and exhaustive outcomes A 1 ,..., A k which form a partitaion of the sample space S For i = 1 ,..., k , let π i = Pr ( A i ) . If we repreat the experiment n times and denote the number of observed outcome A i by Y i . Then it can be shown that Z 2 = k i = 1 ( Y i - n π i ) 2 n π i χ 2 k - 1 6 / 37
Background image of page 6
Introduction Example Suppose we observed 49 heads and 51 tails in 100 tossings. Under H 0 : π = 0 . 5, the expected numbers of head and tail are n π = 100 × 0 . 5 = 50. The observed statistic is χ 2 obs = ( 49 - 50 ) 2 50 + ( 51 - 50 ) 2 50 = 2 50 = 0 . 25 If we observed 40 heads and 60 tails instead, then the observed statistic is χ 2 obs = ( 40 - 50 ) 2 50 + ( 60 - 50 ) 2 50 = 200 50 = 4 Siince χ 2 has an approximate chi-square distribution with 1 df, the critical value for an α = 0 . 05 test is χ 2 1 ( 0 . 05 ) = 3 . 84 The first result would accept H 0 while the second one would reject H 0 at 5% level. 7 / 37
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Remark The minimum sample size n for the χ 2 test is n π i 5 for all i = 1 ,..., k This is to ensure that the chi-square approximation work. In practice this recommendation is not met quite often, and statisticians tend to combine two or more catgories for analysis. 8 / 37
Background image of page 8
Goodness of fit test Example Does the sex of successive children in a family behave like independent Bernoulli trials? If that is the case, then the number of boys in a family of a given size has a binomial distribution with a fixed “success” probability π . The following table summarizes the data on the number of boys in
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 10
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/02/2012 for the course STAT 5044` taught by Professor Staff during the Fall '11 term at Virginia Tech.

Page1 / 37

note16 - STAT5044: Regression and Anova Inyoung Kim 1 / 37...

This preview shows document pages 1 - 10. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online