12
Illustration of Chi- Square tests A wonderful journey to the ABC Fruitcake Factory.

Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Embed Size (px)

Citation preview

Page 1: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Illustration of Chi-Square tests

A wonderful journey to the ABC Fruitcake Factory.

Page 2: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Goodness of FitAre the proportions of the ingredients the same throughout the sample?

Do the proportions of ingredients conform to a predetermined “recipe”?

Page 3: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Properties of Goodness of Fit• Expected “cell” counts should be at least

five• For a sample of k distinct observations the

Degrees of Freedom are (k-1).• Tests to determine if the proportions of

possible observations are equivalent or equal to a predetermined demographic split of the population.

Page 4: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Example

ABC Fruitcake prefers that the proportion of red widgets, green widgets, and crunchy widgets should be .25, .45, and .3 respectively. In a sample of fruitcake, we observe the following frequency of widgets:

Widget type Frequency

Red 236

Green 443

Crunchy 321

Is ABC Fruitcake achieving the correct proportion of ingredients in their fruitcakes?

Page 5: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Test Of Independence

Does the proportion of a certain ingredient influence the proportion of another?

Page 6: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Properties of Independence

• Fixed overall N ( a single large sample of sufficient size such that the expected count of the “cells” is at least 5).

• Sample is assumed to be randomly selected.

• Tests to determine if a given Row factor is dependent on a given column factor.

• For an i X j table the degrees of freedom are (i-1)(j-1).

• Columns can be combined if the expected counts in any cell is less than 5

Page 7: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

ExampleABC Fruitcake is interested in the the relationship of the

level of crunchy widgets and the proportion of green widgets.

Crunchy level

Green Widgets

Red widgets

Marginal Totals

Low 56 39 95

High 70 44 114

Marginal totals

126 83 209

Management would like to know if the level of crunchy widgets is associated with the proportion of green widgets in the fruitcake.

Page 8: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Test of Homogeneity

Marginal totals fixed

Do the proportions of ingredients vary between different brands?

Page 9: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Properties of Homogeneity

• Marginal totals fixed (The rows of the table often denote the separate samples under question).

• Tests to determine if the populations of the different samples have the same characteristics.

• Samples are assumed to be independent and randomly selected.

• For an i X j table the degrees of freedom are

(i-1)(j-1)

• Columns can be combined if the expected counts in any cells are less than 5.

Page 10: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

ExampleFruitcakes come in two varieties, one which has a low level of crunchy widgets and one which has a high level of crunchy widgets. ABC Fruitcakes management would like to know if the proportions of red and green widgets are the same between the different types of fruitcake.

Crunchy level

Green Widgets

Red widgets

Marginal Totals

Low 56 39 95

High 70 44 114

Marginal totals

126 83 209

Page 11: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

So what is the difference using Minitab?

•The tests are both performed using the same Minitab Commands, the difference falls in the hypotheses.

•The interpretation of the results also changes.

Page 12: Illustration of Chi-Square tests A wonderful journey to the ABC Fruitcake Factory

Sources:

• The Fruitcake Lady. January 16, 2006. IndexHere January 18, 2007. <http://indexhere.blogspot.com/2006/01/fruitcake-lady.html>

• Data Analysis 2 course Hot sheet. Rochester Institute of Technology. January 18, 2007.

<http://www.rit.edu/~smam320/Index.html>