# The Chi-Square Distribution

## Test of Independence

Tests of independence involve using a contingency table of observed (data) values.
The test statistic for a test of independence is similar to that of a goodness-of-fit test
where
1. O = observed values,
2. E = expected values,
3. i = the number of rows in the table, and
4. j = the number of columns in the table.
There are  terms of the form 
 . 
A test of independence determines whether two factors are independent. You first encountered the term independence in Probability Topics. As a review, consider the following example.

### References

Harris  Interactive. (n.d.). Retrieved from http://www.statisticbrain.com/favorite-flavor-of-ice-cream/
Statistics Brain. (2016, June 29). Youngest online entrepreneurs list. Retrieved from http://www.statisticbrain.com/youngest-online-entrepreneur-list

### Chapter Review

To assess whether two factors are independent, you can apply the test of independence that uses the chi-square distribution. The null hypothesis for this test states that the two factors are independent. The test compares observed values to expected values. The test is right-tailed. Each observation or cell category must have an expected value of at least five.

### Formula Review

2. The number of degrees of freedom is equal to (number of columns–1)(number of rows–1).
3. The test statistic is

  where
O = observed values,
E = expected values,
i = the number of rows in the
table, and
j = the number of columns in
the table.

4. If the null hypothesis is true, the expected number

.

Determine the appropriate test to be used  in the next three exercises.
Use the following information to answer the next seven exercises: Transit Railroads is interested in the relationship between travel distance and the ticket class purchased. A random sample of 200 passengers is taken.  shows the results. The railroad wants to know if a passenger’s choice in ticket class is independent of the distance the passenger must travel.
Use the following information to answer the next ten exercises. An article in the New England Journal of Medicine discussed a study on people who used a certain product in California and Hawaii. In one part of the report, the self-reported ethnicity and product-use levels per day were given. Of the people using the product at most 10 times per day, there were 9,886 African Americans, 2,745 Native Hawaiians, 12,831 Latinos, 8,378 Japanese Americans, and 7,650 whites. Of the people using the product 11 to 20 times per day, there were 6,514 African Americans, 3,062 Native Hawaiians, 4,932 Latinos, 10,680 Japanese Americans, and 9,877 whites. Of the people using the product 21 to 30 times per day, there were 1,671 African Americans, 1,419 Native Hawaiians, 1,406 Latinos, 4,715 Japanese Americans, and 6,062 whites. Of the people using the product at least 31 times per day, there were 759 African Americans, 788 Native Hawaiians, 800 Latinos, 2,305 Japanese Americans, and 3,970 whites.
State the decision and conclusion (in a complete sentence) for the following levels of α.

### Homework

For each problem, use a solution sheet to solve the hypothesis test problem. Go to 
Read the statement and decide whether it is true or false.