Presentation on theme: "Chi- square goodness of fit. Is your die fair—1 more time. Roll your die 120 times. Write down the number of each roll. Example: 25 20 35 20 19 20 14."— Presentation transcript:
Is your die fair—1 more time. Roll your die 120 times. Write down the number of each roll. Example: 25 20 35 20 19 20 14 20 16 20 11 20 Observed Expected
Dice ---Requirements What are the requirements for the Chi- square test? EASI E—eighty percent of the expected cells are greater than 5. (not observed cells— expected cells!) A and S—representative sample. I—Independence.
Run test!! Note—Chi-square test is not normal. Must figure out the chi-square sum and degrees of freedom. Chi-square sum: (O-E)^2/E and then add them all up. Look up on formula sheets. On calculator X^2 cdf(x^2, 10^99, df)---also use formula sheets. Sum is 1.25 + 11.25 +.05 + 1.8 +.8 + 4.05 = 19.2
Run test!! X^2cdf(19.2, 10^99,5) =.0018 Reject Ho @ alpha.01. There is evidence to suggest my die is not balanced.
What about Ho and Ha? There are no symbols for the chi-square. However, it is always one-sided, even though the word “different” is used. Ho: The dice will roll as you would expect. (there is an implied = here) Ha: the die is different than you would expect.
Demographics. Rancho is approximately 52% Hispanic, 27% Asian, 16% white and 5% other. Does Mr. Pines’ AP stats classes reflect this diversity? Run the appropriate test, verify your requirements, and write a conclusion.
Baseball Bats There have been some major bat changes for the 2011 season. Aluminum baseball bats have been regulated so that they meet certain safety standards. After 5 games this season, coach Pines has noticed significant reductions in power numbers such as 2B’s, 3B’s, and HR’s…..Of course he would like to test his hypothesis.
Baseball Bats Run a Chi-Squared two-way table test to see if there is an association between the power numbers and types of bats. Also run a 2-Prop. Z Test between the types of bats used. If these are done correctly, Z 2 = X 2
Hypotheses Ho: There is no association between type of bats and extra base hits Ha: There is an association between type of bats and extra base hits
Assumptions/Conditions E---All expected counts > 5 S----We have a random sample of 23 schools hitting stats for the first 5 games of the 2010 and 2011 baseball seasons I----We can assume that all stats are independent of other teams stats
Observed and Expected Counts 2010(BESR Bats)2011(BBCOR Bats) Singles672 (695.26)703 (679.74) Extra Base Hits313 (289.74)260 (283.26)
X 2 = 5.35 P-value =.0207 This p-value is low enough to reject at the 5% level. There is evidence to suggest that there may be an association between the types of bats and extra base hits
Gasoline A large distributor of gasoline claims that 60% of all cars stopping at their service stations choose regular unleaded gas and that premium and supreme are each selected 20% of the time. To investigate this claim, researchers collected data from a random sample of drivers who put gas in their vehicles at the stations in a large city. Here are the results:
Gasoline Selected RegularPremiumSupreme 2615188 Carry out a significance test of the distributor’s claim. Use a 5% significance level
Referrals vs Days of week MondayTuesdayWednesdayThursdayFriday 1259415 Are referrals related to the day of the week? The table shows the number of students referred for disciplinary reasons to the principals office, broken down by day of the week.
Testing M&M’s The Mars company has always claimed that the color distribution of their M&M’s follow a certain proportion as follows: BrownRedYellowGreenOrangeBlue 13% 14%16%20%24% Check the M&M’s that were given to you and run a Chi- Square GOF test to see if their claim is accurate. Do not eat your M&M’s until you have your observed and expected counts completed!
Hypotheses Ho: My bag of M&M’s follow the same color distribution as the Mars company claim. Ha: My bag of M&M’s follows a different color distribution as the Mars company claim.
Assumptions/Conditions ___% of expected counts >5 My bag of M&M’s can be considered an independent random sample of M&M’s