AP Statistics 13.1 Test for Goodness of Fit Read page 728, paragraph 2, and explain the use of the chi-square ( 2 ) test for goodness of fit. Goodness of Fit Test A ________________ is used to help determine whether a population has a certain hypothesized ________________, expressed as proportions of population members falling into various outcome categories. Suppose that the hypothesized distribution has ____ outcome categories. To test the hypothesis first calculate the chi-square test statistic Then _____ has approximately a _____ distribution with ________ degrees of freedom. For a test of H o against the alternative hypothesis The P-value is ____________. Conditions: You may use this test with critical values form the chi-square distribution when all _____________________ are at least 1 and _______________ if the ______________ are less than _____. The Graying of America In recent years, the expression “the graying of America” has been used to refer to the belief that with better medicine and healthier lifestyles, people are living longer, and consequently a larger percentage of the population is of retirement age. We want to investigate whether this perception is accurate. The distribution of the U.S. population in 1980 is shown. We want to determine if the distribution of age groups in the United States in 1996 has changed significantly from the 1980 distribution. U.S. Population by age group, 1980 Age Group Population (in thousands) 0 to 24 93,777 25 to 44 62,716 45 to 64 44,503 65 and older 25,550 Total Percent 41.39 27.68 19.64 11.28 We will test the following hypothesis: The idea of this test is this: We compare the observed counts for a sample from the 1996 population with the counts that would be expected if the 1996 distribution were the same as the 1980 distribution, that is if H o were in fact true. The 1980 distribution is the population. The more the observed counts differ from the expected counts; the more evidence we have to reject H o and to conclude that the population distribution in 1996 is significantly different form that of 1980. A random sample of 500 U.S. residents in 1996 is selected and the age of each subject is recorded. Sample results for 500 randomly selected individuals in 1996 Age group Count 0 to 24 177 25 to 44 158 45 to 64 101 65 and older 64 Total Percent 35.4 31.6 20.2 12.8 Before proceeding with a significance test, its always a good idea to _____________________. The next step in the test is to calculate the expected counts for each age category. Expected Counts Age Group 0 to 24 25 to 44 45 to 64 65 and older 1980 Population in Percents Expected Counts (1996) In order to determine whether the distribution has changed since 1980, we need a way to measure how well the observed counts (O) from 1996 fit the expected counts (E) under H o . The procedure is to calculate the quantity ____________. Calculate the goodness of fit Age group Observed (O) O E Expected (E) 2 E 0 to 24 25 to 44 45 to 64 65 and older 2 = In Table E, for a P-value of 0.05 and degrees of freedom = 3, we find that the critical value is 7.81. Since our 2 = ______________ is _______________ than the critical value, we say that the probability of observing a result ________________ as the one we actually observed, by chance alone, is less that ________. Therefore ________________________________________ _____________________________________________________________________________. The Chi-Square Distributions The ____________________ are a family of distributions that take only _____________ and are __________________________. A specific chi-square distribution is specified by one parameter, called the _________________> The chi-square density curves have the following properties: 1. 2. 3. One of the most common applications of the chi-square goodness of fit test is in the field of genetics. Scientists want to investigate the genetic characteristics of offspring that result from mating (also called “crossing”) parents with known genetic makeups. They use rules about dominant and recessive genes to predict that ratio of offspring that will fall in each possible genetic category. Then, the scientists mate the parents and classify the resulting offspring. The chi-square goodness of fit test helps the scientists assess the validity of their hypothesized ratios. Red-Eyed Fruit Flies Biologists wish to mate fruit flies having genetic makeup RrCc, indicating that it has one dominant gene (R) and one recessive gene (r) for eye color, along with one dominant (C) and one recessive (c) gene for wing type. Each offspring will receive one gene for each of the two traits from both parents. The following table, often called a Punnet square, shows the possible combinations of genes received by the offspring. RC Rc rC rc RC Rc rC rc Any offspring receiving an R gene will have red eyes, and any offspring receiving a C gene will have straight wings. So based on this Punnet square, the biologists predict a ration of ______________, ______________, (x): ____________, _____________, (y) ______________, ______________, (z): _____________, ______________(w) offspring. In order to test their hypothesis about the distribution of offspring, the biologists mate the fruit flies. Of 200 offspring, 101 had red eyes and straight wings, 42 had red eyes and curly wings, 49 had white eyes and straight wings, and 10 had white eyes and curly wings. Do these data differ significantly from what the biologists have predicted?