Comparing Counts.  A test of whether the distribution of counts in one categorical variable matches the distribution predicted by a model is called a.

Slides:



Advertisements
Similar presentations
Copyright © 2010 Pearson Education, Inc. Slide
Advertisements

Statistical Methods Lecture 26
Chapter 26 Comparing Counts
Chi-Squared Hypothesis Testing Using One-Way and Two-Way Frequency Tables of Categorical Variables.
1 Copyright © 2005 Brooks/Cole, a division of Thomson Learning, Inc. Analysis of Categorical Data Goodness-of-Fit Tests.
© 2010 Pearson Prentice Hall. All rights reserved Least Squares Regression Models.
© 2010 Pearson Prentice Hall. All rights reserved The Chi-Square Test of Independence.
1-1 Copyright © 2015, 2010, 2007 Pearson Education, Inc. Chapter 25, Slide 1 Chapter 25 Comparing Counts.
Chapter 26: Comparing Counts
CHI-SQUARE TEST OF INDEPENDENCE
Chapter 11 Chi-Square Procedures 11.1 Chi-Square Goodness of Fit.
Chapter 26: Comparing Counts. To analyze categorical data, we construct two-way tables and examine the counts of percents of the explanatory and response.
Inferences About Process Quality
Chi-square Goodness of Fit Test
Chapter 13 Chi-Square Tests. The chi-square test for Goodness of Fit allows us to determine whether a specified population distribution seems valid. The.
Chi-Square Distributions
Copyright © 2012 Pearson Education. All rights reserved Copyright © 2012 Pearson Education. All rights reserved. Chapter 15 Inference for Counts:
 Involves testing a hypothesis.  There is no single parameter to estimate.  Considers all categories to give an overall idea of whether the observed.
Copyright © 2010, 2007, 2004 Pearson Education, Inc. Chapter 26 Comparing Counts.
Chapter 26: Comparing Counts AP Statistics. Comparing Counts In this chapter, we will be performing hypothesis tests on categorical data In previous chapters,
Copyright © 2010 Pearson Education, Inc. Warm Up- Good Morning! If all the values of a data set are the same, all of the following must equal zero except.
Copyright © 2013, 2010 and 2007 Pearson Education, Inc. Chapter Inference on Categorical Data 12.
Section 10.1 Goodness of Fit. Section 10.1 Objectives Use the chi-square distribution to test whether a frequency distribution fits a claimed distribution.
Chapter 11 Chi-Square Procedures 11.3 Chi-Square Test for Independence; Homogeneity of Proportions.
Chi-square Test of Independence Steps in Testing Chi-square Test of Independence Hypotheses.
CHAPTER 26: COMPARING COUNTS OF CATEGORICAL DATA To test claims and make inferences about counts for categorical variables Objective:
Chapter 26: Comparing counts of categorical data
Chapter 11: Inference for Distributions of Categorical Data Section 11.1 Chi-Square Goodness-of-Fit Tests.
Chi-Square Procedures Chi-Square Test for Goodness of Fit, Independence of Variables, and Homogeneity of Proportions.
1-1 Copyright © 2015, 2010, 2007 Pearson Education, Inc. Chapter 25, Slide 1 Chapter 26 Comparing Counts.
United Stats Of AMERICA. Unit 7 chapters Jordo, Rob III, Kins and Toph.
Chi-Square Distributions. Recap Analyze data and test hypothesis Type of test depends on: Data available Question we need to answer What do we use to.
Testing Hypothesis That Data Fit a Given Probability Distribution Problem: We have a sample of size n. Determine if the data fits a probability distribution.
Slide 26-1 Copyright © 2004 Pearson Education, Inc.
FPP 28 Chi-square test. More types of inference for nominal variables Nominal data is categorical with more than two categories Compare observed frequencies.
Fitting probability models to frequency data. Review - proportions Data: discrete nominal variable with two states (“success” and “failure”) You can do.
AP Statistics Section 14.. The main objective of Chapter 14 is to test claims about qualitative data consisting of frequency counts for different categories.
Copyright © 2010 Pearson Education, Inc. Slide
Inference for Distributions of Categorical Variables (C26 BVD)
© Copyright McGraw-Hill CHAPTER 11 Other Chi-Square Tests.
Chapter 13 Inference for Counts: Chi-Square Tests © 2011 Pearson Education, Inc. 1 Business Statistics: A First Course.
Chapter Outline Goodness of Fit test Test of Independence.
Copyright © 2010 Pearson Education, Inc. Warm Up- Good Morning! If all the values of a data set are the same, all of the following must equal zero except.
11.2 Tests Using Contingency Tables When data can be tabulated in table form in terms of frequencies, several types of hypotheses can be tested by using.
Section 12.2: Tests for Homogeneity and Independence in a Two-Way Table.
Copyright © 2013, 2009, and 2007, Pearson Education, Inc. Chapter 11 Analyzing the Association Between Categorical Variables Section 11.2 Testing Categorical.
Statistics 300: Elementary Statistics Section 11-2.
Chapter 13- Inference For Tables: Chi-square Procedures Section Test for goodness of fit Section Inference for Two-Way tables Presented By:
Chi-Square Goodness of Fit Test. In general, the chi-square test statistic is of the form If the computed test statistic is large, then the observed and.
Comparing Counts Chapter 26. Goodness-of-Fit A test of whether the distribution of counts in one categorical variable matches the distribution predicted.
Chapter 11 Chi-Square Procedures 11.1 Chi-Square Goodness of Fit.
+ Section 11.1 Chi-Square Goodness-of-Fit Tests. + Introduction In the previous chapter, we discussed inference procedures for comparing the proportion.
Statistics 26 Comparing Counts. Goodness-of-Fit A test of whether the distribution of counts in one categorical variable matches the distribution predicted.
Chapter 11: Categorical Data n Chi-square goodness of fit test allows us to examine a single distribution of a categorical variable in a population. n.
Comparing Observed Distributions A test comparing the distribution of counts for two or more groups on the same categorical variable is called a chi-square.
Chi Square Test of Homogeneity. Are the different types of M&M’s distributed the same across the different colors? PlainPeanutPeanut Butter Crispy Brown7447.
Goodness-of-Fit A test of whether the distribution of counts in one categorical variable matches the distribution predicted by a model is called a goodness-of-fit.
Copyright © 2009 Pearson Education, Inc. Chapter 26 Comparing Counts.
Comparing Counts Chi Square Tests Independence.
CHAPTER 26 Comparing Counts.
Chapter 25 Comparing Counts.
Overview and Chi-Square
15.1 Goodness-of-Fit Tests
When You See (This), You Think (That)
Paired Samples and Blocks
Analyzing the Association Between Categorical Variables
Chapter 26 Comparing Counts.
Chapter 26 Comparing Counts Copyright © 2009 Pearson Education, Inc.
Chapter 26 Comparing Counts.
Presentation transcript:

Comparing Counts

 A test of whether the distribution of counts in one categorical variable matches the distribution predicted by a model is called a goodness-of-fit test.  Example: A company printed baseball cards. It claimed that 30% of its cards were rookies; 60% veterans and 10% All-Stars. We want to know if their claim is true. Suppose a randomly-selected package of cards has 50 rookies, 45 veterans, and 5 All-Stars. Is this consistent with their claim?

 Counted Data Condition: Check that the data are counts for the categories of a categorical variable.  Independence Assumption: The counts in the cells should be independent of each other. ◦ Randomization Condition:  Sample Size Assumption: We must have enough data for the methods to work. ◦ Expected Cell Frequency Condition: We should expect to see at least 5 individuals in each cell.  This is similar to the condition that np and nq be at least 10 when we tested proportions.

 Since we want to examine how well the observed data reflect what would be expected, it is natural to look at the differences between the observed and expected counts (Obs – Exp).  These differences are actually residuals, so we know that adding all of the differences will result in a sum of 0. That’s not very helpful.  We’ll handle the residuals as we did in regression, by squaring them.  To get an idea of the relative sizes of the differences, we will divide these squared quantities by the expected values.

 The test statistic, called the chi-square (or chi-squared) statistic, is found by adding up the sum of the squares of the deviations between the observed and expected counts divided by the expected counts:

 The chi-square models are actually a family of distributions indexed by degrees of freedom (much like the t-distribution).  The number of degrees of freedom for a goodness-of-fit test is n – 1, where n is the number of categories.

 The chi-square statistic is used only for testing hypotheses, not for constructing confidence intervals.  If the observed counts don’t match the expected, the statistic will be large—it can’t be “too small.”  So the chi-square test is always one-sided. ◦ If the calculated value is large enough, we’ll reject the null hypothesis. ◦ There’s no direction to the rejection of the null model—all we know is that it doesn’t fit.

1.Find the expected values: ◦ Every model gives a hypothesized proportion for each cell. ◦ The expected value is the product of the total number of observations times this proportion. 2.Compute the residuals: Observed – Expected. 3.Square the residuals. 4.Compute the components. Now find the components for each cell.

5.Find the sum of the components (that’s the chi-square statistic). 6.Find the degrees of freedom. It’s equal to the number of cells minus one. 7.Test the hypothesis.  Use your chi-square statistic to find the P- value.  Large chi-square values mean lots of deviation from the hypothesized model, so they give small P-values.

 Page  Problem # 3, 5, 7, 9, 11.