Chapter 10 Chi-Square Tests and the F-Distribution

Slides:



Advertisements
Similar presentations
Testing the Difference Between Means (Large Independent Samples)
Advertisements

The Analysis of Categorical Data and Goodness of Fit Tests
Slide 4- 1 Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Active Learning Lecture Slides For use with Classroom Response.
CHAPTER 23: Two Categorical Variables: The Chi-Square Test
Chapter 11 Inference for Distributions of Categorical Data
Chapter 10 Chi-Square Tests and the F- Distribution 1 Larson/Farber 4th ed.
© 2010 Pearson Prentice Hall. All rights reserved The Chi-Square Test of Independence.
CHAPTER 11 Inference for Distributions of Categorical Data
CHAPTER 11 Inference for Distributions of Categorical Data
Copyright (c) 2004 Brooks/Cole, a division of Thomson Learning, Inc. Chapter 14 Goodness-of-Fit Tests and Categorical Data Analysis.
Hypothesis Testing for Variance and Standard Deviation
Testing the Difference Between Means (Small Independent Samples)
Chi-Square and F Distributions Chapter 11 Understandable Statistics Ninth Edition By Brase and Brase Prepared by Yixun Shi Bloomsburg University of Pennsylvania.
Chi-Square Tests and the F-Distribution
Chi-Square and Analysis of Variance (ANOVA)
Hypothesis Testing with Two Samples
Chapter 13: Inference for Tables – Chi-Square Procedures
Hypothesis Testing with Two Samples
Copyright © 2013, 2010 and 2007 Pearson Education, Inc. Chapter Inference on Categorical Data 12.
Hypothesis Testing with One Sample Chapter 7. § 7.1 Introduction to Hypothesis Testing.
Section 10.3 Comparing Two Variances Larson/Farber 4th ed1.
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: Applications of Chi-Square. Count or Frequency Data Many problems for which the data is categorized and the results shown by way of counts.
Chapter 8 Hypothesis Testing with Two Samples 1. Chapter Outline 8.1 Testing the Difference Between Means (Large Independent Samples) 8.2 Testing the.
Hypothesis Testing with Two Samples
10.1: Multinomial Experiments Multinomial experiment A probability experiment consisting of a fixed number of trials in which there are more than two possible.
Copyright © 2004 Pearson Education, Inc.
Chapter Chi-Square Tests and the F-Distribution 1 of © 2012 Pearson Education, Inc. All rights reserved.
Comparing Two Variances
The Practice of Statistics, 5th Edition Starnes, Tabor, Yates, Moore Bedford Freeman Worth Publishers CHAPTER 11 Inference for Distributions of Categorical.
Chapter 11: Inference for Distributions of Categorical Data Section 11.1 Chi-Square Goodness-of-Fit Tests.
Chapter 10 Chi-Square Tests and the F- Distribution 1 Larson/Farber 4th ed.
Chapter 10 Chi-Square Tests and the F-Distribution
GOODNESS OF FIT Larson/Farber 4th ed 1 Section 10.1.
Section 10.2 Independence. Section 10.2 Objectives Use a chi-square distribution to test whether two variables are independent Use a contingency table.
Chapter Outline Goodness of Fit test Test of Independence.
1 Chapter 10. Section 10.1 and 10.2 Triola, Elementary Statistics, Eighth Edition. Copyright Addison Wesley Longman M ARIO F. T RIOLA E IGHTH E DITION.
Copyright (C) 2002 Houghton Mifflin Company. All rights reserved. 1 Understandable Statistics S eventh Edition By Brase and Brase Prepared by: Lynn Smith.
Copyright © Cengage Learning. All rights reserved. Chi-Square and F Distributions 10.
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.
Copyright © 2010, 2007, 2004 Pearson Education, Inc. All Rights Reserved Lecture Slides Elementary Statistics Eleventh Edition and the Triola.
Chapter 12 The Analysis of Categorical Data and Goodness of Fit Tests.
Section Copyright © 2014, 2012, 2010 Pearson Education, Inc. Lecture Slides Elementary Statistics Twelfth Edition and the Triola Statistics Series.
+ Section 11.1 Chi-Square Goodness-of-Fit Tests. + Introduction In the previous chapter, we discussed inference procedures for comparing the proportion.
The Practice of Statistics, 5th Edition Starnes, Tabor, Yates, Moore Bedford Freeman Worth Publishers CHAPTER 11 Inference for Distributions of Categorical.
11.1 Chi-Square Tests for Goodness of Fit Objectives SWBAT: STATE appropriate hypotheses and COMPUTE expected counts for a chi- square test for goodness.
Slide Slide 1 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley. Lecture Slides Elementary Statistics Tenth Edition and the.
Slide 1 Copyright © 2004 Pearson Education, Inc. Chapter 11 Multinomial Experiments and Contingency Tables 11-1 Overview 11-2 Multinomial Experiments:
Section 10.2 Objectives Use a contingency table to find expected frequencies Use a chi-square distribution to test whether two variables are independent.
Chapter Hypothesis Testing with One Sample 1 of © 2012 Pearson Education, Inc. All rights reserved.
Goodness-of-Fit and Contingency Tables Chapter 11.
Chapter 10 Chi-Square Tests and the F-Distribution.
Section 10.1 Goodness of Fit © 2012 Pearson Education, Inc. All rights reserved. 1 of 91.
Section 10-3 – Comparing Two Variances The F-Distribution 2)F-distributions are positively skewed. 3)The total area under each curve of an F-distribution.
Chapter 10 Chi-Square Tests and the F-Distribution
10 Chapter Chi-Square Tests and the F-Distribution Chapter 10
Chapter 7 Hypothesis Testing with One Sample.
10 Chapter Chi-Square Tests and the F-Distribution Chapter 10
Chapter 7 Hypothesis Testing with One Sample.
10 Chapter Chi-Square Tests and the F-Distribution Chapter 10
Chapter 8 Hypothesis Testing with Two Samples.
Chapter 10 Chi-Square Tests and the F-Distribution
Section 10-1 – Goodness of Fit
EXAMS Mon. Tues. Wed. Thur. Fri. 5/7 (Odd) 5/8 (Even) 5/9 (Odd)
Section 10-4 – Analysis of Variance
Elementary Statistics: Picturing The World
Elementary Statistics: Picturing The World
Elementary Statistics: Picturing The World
Presentation transcript:

Chapter 10 Chi-Square Tests and the F-Distribution

Chapter Outline 10.1 Goodness of Fit 10.2 Independence 10.3 Comparing Two Variances 10.4 Analysis of Variance

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

Multinomial Experiments A probability experiment consisting of a fixed number of trials in which there are more than two possible outcomes for each independent trial. A binomial experiment had only two possible outcomes. The probability for each outcome is fixed and each outcome is classified into categories.

Multinomial Experiments Example: A radio station claims that the distribution of music preferences for listeners in the broadcast region is as shown below. Distribution of music Preferences Classical 4% Oldies 2% Country 36% Pop 18% Gospel 11% Rock 29% Each outcome is classified into categories. The probability for each possible outcome is fixed.

Chi-Square Goodness-of-Fit Test Used to test whether a frequency distribution fits an expected distribution. The null hypothesis states that the frequency distribution fits the specified distribution. The alternative hypothesis states that the frequency distribution does not fit the specified distribution.

Chi-Square Goodness-of-Fit Test Example: To test the radio station’s claim, the executive can perform a chi-square goodness-of-fit test using the following hypotheses. H0: The distribution of music preferences in the broadcast region is 4% classical, 36% country, 11% gospel, 2% oldies, 18% pop, and 29% rock. (claim) Ha: The distribution of music preferences differs from the claimed or expected distribution.

Chi-Square Goodness-of-Fit Test To calculate the test statistic for the chi-square goodness-of-fit test, the observed frequencies and the expected frequencies are used. The observed frequency O of a category is the frequency for the category observed in the sample data.

Chi-Square Goodness-of-Fit Test The expected frequency E of a category is the calculated frequency for the category. Expected frequencies are obtained assuming the specified (or hypothesized) distribution. The expected frequency for the ith category is Ei = npi where n is the number of trials (the sample size) and pi is the assumed probability of the ith category.

Example: Finding Observed and Expected Frequencies A marketing executive randomly selects 500 radio music listeners from the broadcast region and asks each whether he or she prefers classical, country, gospel, oldies, pop, or rock music. The results are shown at the right. Find the observed frequencies and the expected frequencies for each type of music. Survey results (n = 500) Classical 8 Country 210 Gospel 72 Oldies 10 Pop 75 Rock 125

Solution: Finding Observed and Expected Frequencies Observed frequency: The number of radio music listeners naming a particular type of music Survey results (n = 500) Classical 8 Country 210 Gospel 72 Oldies 10 Pop 75 Rock 125 observed frequency

Solution: Finding Observed and Expected Frequencies Distribution of music Preferences Classical 4% Oldies 2% Country 36% Pop 18% Gospel 11% Rock 29% Type of music % of listeners Observed frequency Expected frequency Classical 4% 8 Country 36% 210 Gospel 11% 72 Oldies 2% 10 Pop 18% 75 Rock 29% 125 500(0.04) = 20 500(0.36) = 180 500(0.11) = 55 500(0.02) = 10 500(0.18) = 90 500(0.29) = 145 n = 500 Expected Frequency: Ei = npi

Chi-Square Goodness-of-Fit Test For the chi-square goodness-of-fit test to be used, the following must be true. The observed frequencies must be obtained by using a random sample. Each expected frequency must be greater than or equal to 5.

Chi-Square Goodness-of-Fit Test Chapter 10 Chi-Square Goodness-of-Fit Test If these conditions are satisfied, then the sampling distribution for the goodness-of-fit test is approximated by a chi-square distribution with k – 1 degrees of freedom, where k is the number of categories. The test statistic for the chi-square goodness-of-fit test is where O represents the observed frequency of each category and E represents the expected frequency of each category. The test is always a right-tailed test.

Chi-Square Goodness-of-Fit Test Chapter 10 Chi-Square Goodness-of-Fit Test In Words In Symbols Identify the claim. State the null and alternative hypotheses. Specify the level of significance. Identify the degrees of freedom. Determine the critical value. State H0 and Ha. Identify . d.f. = k – 1 Use Table 6 in Appendix B.

Chi-Square Goodness-of-Fit Test Chapter 10 Chi-Square Goodness-of-Fit Test In Words In Symbols Determine the rejection region. Calculate the test statistic. Make a decision to reject or fail to reject the null hypothesis. Interpret the decision in the context of the original claim. If χ2 is in the rejection region, reject H0. Otherwise, fail to reject H0.

Example: Performing a Goodness of Fit Test Use the music preference data to perform a chi-square goodness-of-fit test to test whether the distributions are different. Use α = 0.01. Distribution of music preferences Classical 4% Country 36% Gospel 11% Oldies 2% Pop 18% Rock 29% Survey results (n = 500) Classical 8 Country 210 Gospel 72 Oldies 10 Pop 75 Rock 125

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region music preference is 4% classical, 36% country, 11% gospel, 2% oldies, 18% pop, and 29% rock music preference differs from the claimed or expected distribution 0.01 6 – 1 = 5 Test Statistic: Decision: Conclusion: 0.01 χ2 15.086

Solution: Performing a Goodness of Fit Test Chapter 10 Solution: Performing a Goodness of Fit Test Type of music Observed frequency Expected frequency Classical 8 20 Country 210 180 Gospel 72 55 Oldies 10 Pop 75 90 Rock 125 145

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region music preference is 4% classical, 36% country, 11% gospel, 2% oldies, 18% pop, and 29% rock music preference differs from the claimed or expected distribution 0.01 6 – 1 = 5 Test Statistic: Decision: χ2 = 22.713 Reject H0 0.01 χ2 15.086 There is enough evidence to conclude that the distribution of music preferences differs from the claimed distribution. 22.713

Example: Performing a Goodness of Fit Test The manufacturer of M&M’s candies claims that the number of different-colored candies in bags of dark chocolate M&M’s is uniformly distributed. To test this claim, you randomly select a bag that contains 500 dark chocolate M&M’s. The results are shown in the table on the next slide. Using α = 0.10, perform a chi-square goodness-of-fit test to test the claimed or expected distribution. What can you conclude? (Adapted from Mars Incorporated)

Example: Performing a Goodness of Fit Test Solution: The claim is that the distribution is uniform, so the expected frequencies of the colors are equal. To find each expected frequency, divide the sample size by the number of colors. E = 500/6 ≈ 83.3 Color Frequency Brown 80 Yellow 95 Red 88 Blue 83 Orange 76 Green 78 n = 500

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region Distribution of different-colored candies in bags of dark chocolate M&Ms is uniform Distribution of different-colored candies in bags of dark chocolate M&Ms is not uniform 0.10 6 – 1 = 5 Test Statistic: Decision: Conclusion: 0.10 χ2 9.236

Solution: Performing a Goodness of Fit Test Chapter 10 Color Observed frequency Expected frequency Brown 80 83.3 Yellow 95 Red 88 Blue 83 Orange 76 Green 78

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region Distribution of different-colored candies in bags of dark chocolate M&Ms is uniform Distribution of different-colored candies in bags of dark chocolate M&Ms is not uniform 0.01 6 – 1 = 5 Test Statistic: Decision: χ2 = 3.016 Fail to Reject H0 0.10 χ2 9.236 There is not enough evidence to dispute the claim that the distribution is uniform. 3.016

Section 10.1 Summary Used the chi-square distribution to test whether a frequency distribution fits a claimed distribution

Section 10.2 Independence

Section 10.2 Objectives Use a contingency table to find expected frequencies Use a chi-square distribution to test whether two variables are independent

Contingency Tables r  c contingency table Shows the observed frequencies for two variables. The observed frequencies are arranged in r rows and c columns. The intersection of a row and a column is called a cell.

Contingency Tables Example: The contingency table shows the results of a random sample of 550 company CEOs classified by age and size of company.(Adapted from Grant Thornton LLP, The Segal Company) Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Small / Midsize 42 69 108 60 21 Large 5 18 85 120 22

Finding the Expected Frequency Assuming the two variables are independent, you can use the contingency table to find the expected frequency for each cell. The expected frequency for a cell Er,c in a contingency table is Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Small / Midsize 42 69 108 60 21 Large 5 18 85 120 22

Example: Finding Expected Frequencies Find the expected frequency for each cell in the contingency table. Assume that the variables, age and company size, are independent. Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Total Small / Midsize 42 69 108 60 21 300 Large 5 18 85 120 22 250 47 87 193 180 43 550 marginal totals

Solution: Finding Expected Frequencies Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Total Small / Midsize 42 69 108 60 21 300 Large 5 18 85 120 22 250 47 87 193 180 43 550

Solution: Finding Expected Frequencies Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Total Small / Midsize 42 69 108 60 21 300 Large 5 18 85 120 22 250 47 87 193 180 43 550

Solution: Finding Expected Frequencies Chapter 10 Solution: Finding Expected Frequencies Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Total Small / Midsize 42 69 108 60 21 300 Large 5 18 85 120 22 250 47 87 193 180 43 550

Chi-Square Independence Test Used to test the independence of two variables. Can determine whether the occurrence of one variable affects the probability of the occurrence of the other variable.

Chi-Square Independence Test For the chi-square independence test to be used, the following must be true. The observed frequencies must be obtained by using a random sample. Each expected frequency must be greater than or equal to 5.

Chi-Square Independence Test If these conditions are satisfied, then the sampling distribution for the chi-square independence test is approximated by a chi-square distribution with (r – 1)(c – 1) degrees of freedom, where r and c are the number of rows and columns, respectively, of a contingency table. The test statistic for the chi-square independence test is where O represents the observed frequencies and E represents the expected frequencies. The test is always a right-tailed test.

Chi-Square Independence Test Chapter 10 Chi-Square Independence Test In Words In Symbols Identify the claim. State the null and alternative hypotheses. Specify the level of significance. Identify the degrees of freedom. Determine the critical value. State H0 and Ha. Identify . d.f. = (r – 1)(c – 1) Use Table 6 in Appendix B.

Chi-Square Independence Test Chapter 10 Chi-Square Independence Test In Words In Symbols Determine the rejection region. Calculate the test statistic. Make a decision to reject or fail to reject the null hypothesis. Interpret the decision in the context of the original claim. If χ2 is in the rejection region, reject H0. Otherwise, fail to reject H0.

Example: Performing a χ2 Independence Test Using the age/company size contingency table, can you conclude that the CEOs ages are related to company size? Use α = 0.01. Expected frequencies are shown in parentheses. Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Total Small / Midsize 42 (25.64) 69 (47.45) 108 (105.27) 60 (98.18) 21 (23.45) 300 Large 5 (21.36) 18 (39.55) 85 (87.73) 120 (81.82) 22 (19.55) 250 47 87 193 180 43 550

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region CEOs’ ages are independent of company size CEOs’ ages are dependent on company size 0.01 (2 – 1)(5 – 1) = 4 Test Statistic: Decision: 0.01 χ2 13.277

Solution: Performing a Goodness of Fit Test Chapter 10 Solution: Performing a Goodness of Fit Test

Solution: Performing a Goodness of Fit Test H0: Ha: α = d.f. = Rejection Region CEOs’ ages are independent of company size CEOs’ ages are dependent on company size 0.01 (2 – 1)(5 – 1) = 4 Test Statistic: Decision: χ2 = 77.9 Reject H0 0.01 χ2 13.277 There is enough evidence to conclude CEOs’ ages are dependent on company size. 77.9

Age Company size 39 and under 40 - 49 50 - 59 60 - 69 70 and over Small / Midsize 42 69 108 60 21 Large 5 18 85 120 22

Section 10.2 Summary Used a contingency table to find expected frequencies Used a chi-square distribution to test whether two variables are independent

Comparing Two Variances Section 10.3 Comparing Two Variances

Section 10.3 Objectives Interpret the F-distribution and use an F-table to find critical values Perform a two-sample F-test to compare two variances

F-Distribution Let represent the sample variances of two different populations. If both populations are normal and the population variances are equal, then the sampling distribution of is called an F-distribution.

Properties of the F-Distribution The F-distribution is a family of curves each of which is determined by two types of degrees of freedom: The degrees of freedom corresponding to the variance in the numerator, denoted d.f.N The degrees of freedom corresponding to the variance in the denominator, denoted d.f.D F-distributions are positively skewed. The total area under each curve of an F-distribution is equal to 1.

Properties of the F-Distribution Chapter 10 Properties of the F-Distribution F-values are always greater than or equal to 0. For all F-distributions, the mean value of F is approximately equal to 1. d.f.N = 1 and d.f.D = 8 F 1 2 3 4 d.f.N = 8 and d.f.D = 26 d.f.N = 16 and d.f.D = 7 d.f.N = 3 and d.f.D = 11

Critical Values for the F-Distribution Chapter 10 Critical Values for the F-Distribution Specify the level of significance . Determine the degrees of freedom for the numerator, d.f.N. Determine the degrees of freedom for the denominator, d.f.D. Use Table 7 in Appendix B to find the critical value. If the hypothesis test is one-tailed, use the  F-table. two-tailed, use the ½ F-table.

Example: Finding Critical F-Values Find the critical F-value for a right-tailed test when α = 0.05, d.f.N = 6 and d.f.D = 29. Solution: The critical value is F0 = 2.43.

Example: Finding Critical F-Values Find the critical F-value for a two-tailed test when α = 0.05, d.f.N = 4 and d.f.D = 8. Solution: When performing a two-tailed hypothesis test using the F-distribution, you need only to find the right-tailed critical value. You must remember to use the ½α table.

Solution: Finding Critical F-Values ½α = 0.025, d.f.N = 4 and d.f.D = 8 The critical value is F0 = 5.05.

Two-Sample F-Test for Variances To use the two-sample F-test for comparing two population variances, the following must be true. The samples must be randomly selected. The samples must be independent. Each population must have a normal distribution.

Two-Sample F-Test for Variances Test Statistic where represent the sample variances with The degrees of freedom for the numerator is d.f.N = n1 – 1 where n1 is the size of the sample having variance The degrees of freedom for the denominator is d.f.D = n2 – 1, and n2 is the size of the sample having variance

Two-Sample F-Test for Variances Chapter 10 Two-Sample F-Test for Variances In Words In Symbols Identify the claim. State the null and alternative hypotheses. Specify the level of significance. Identify the degrees of freedom. Determine the critical value. State H0 and Ha. Identify . d.f.N = n1 – 1 d.f.D = n2 – 1 Use Table 7 in Appendix B.

Two-Sample F-Test for Variances Chapter 10 Two-Sample F-Test for Variances In Words In Symbols Determine the rejection region. Calculate the test statistic. Make a decision to reject or fail to reject the null hypothesis. Interpret the decision in the context of the original claim. If F is in the rejection region, reject H0. Otherwise, fail to reject H0.

Example: Performing a Two-Sample F-Test A restaurant manager is designing a system that is intended to decrease the variance of the time customers wait before their meals are served. Under the old system, a random sample of 10 customers had a variance of 400. Under the new system, a random sample of 21 customers had a variance of 256. At α = 0.10, is there enough evidence to convince the manager to switch to the new system? Assume both populations are normally distributed.

Solution: Performing a Two-Sample F-Test Because 400 > 256, H0: Ha: α = d.f.N= d.f.D= Rejection Region: σ12 ≤ σ22 σ12 > σ22 Test Statistic: Decision: 0.10 9 20 Fail to Reject H0 There is not enough evidence to convince the manager to switch to the new system. F 1.96 0.10 1.96 1.56

Example: Performing a Two-Sample F-Test You want to purchase stock in a company and are deciding between two different stocks. Because a stock’s risk can be associated with the standard deviation of its daily closing prices, you randomly select samples of the daily closing prices for each stock to obtain the results. At α = 0.05, can you conclude that one of the two stocks is a riskier investment? Assume the stock closing prices are normally distributed. Stock A Stock B n2 = 30 n1 = 31 s2 = 3.5 s1 = 5.7

Solution: Performing a Two-Sample F-Test Because 5.72 > 3.52, H0: Ha: ½α = d.f.N= d.f.D= Rejection Region: σ12 = σ22 σ12 ≠ σ22 Test Statistic: Decision: 0. 025 30 29 Reject H0 There is enough evidence to support the claim that one of the two stocks is a riskier investment. F 2.09 0.025 2.09 2.65

Section 10.3 Summary Interpreted the F-distribution and used an F-table to find critical values Performed a two-sample F-test to compare two variances

Section 10.4 Analysis of Variance

Section 10.4 Objectives Use one-way analysis of variance to test claims involving three or more means Introduce two-way analysis of variance

One-Way ANOVA One-way analysis of variance Chapter 10 One-Way ANOVA One-way analysis of variance A hypothesis-testing technique that is used to compare means from three or more populations. Analysis of variance is usually abbreviated ANOVA. Hypotheses: H0: μ1 = μ2 = μ3 =…= μk (all population means are equal) Ha: At least one of the means is different from the others.

One-Way ANOVA In a one-way ANOVA test, the following must be true. Each sample must be randomly selected from a normal, or approximately normal, population. The samples must be independent of each other. Each population must have the same variance.

One-Way ANOVA The variance between samples MSB measures the differences related to the treatment given to each sample and is sometimes called the mean square between. The variance within samples MSW measures the differences related to entries within the same sample. This variance, sometimes called the mean square within, is usually due to sampling error.

One-Way Analysis of Variance Test If the conditions for a one-way analysis of variance are satisfied, then the sampling distribution for the test is approximated by the F-distribution. The test statistic is The degrees of freedom for the F-test are d.f.N = k – 1 and d.f.D = N – k where k is the number of samples and N is the sum of the sample sizes.

Test Statistic for a One-Way ANOVA Chapter 10 Test Statistic for a One-Way ANOVA In Words In Symbols Find the mean and variance of each sample. Find the mean of all entries in all samples (the grand mean). Find the sum of squares between the samples. Find the sum of squares within the samples.

Test Statistic for a One-Way ANOVA Chapter 10 Test Statistic for a One-Way ANOVA In Words In Symbols Find the variance between the samples. Find the variance within the samples Find the test statistic.

Performing a One-Way ANOVA Test Chapter 10 Performing a One-Way ANOVA Test In Words In Symbols Identify the claim. State the null and alternative hypotheses. Specify the level of significance. Identify the degrees of freedom. Determine the critical value. State H0 and Ha. Identify . d.f.N = k – 1 d.f.D = N – k Use Table 7 in Appendix B.

Performing a One-Way ANOVA Test Chapter 10 Performing a One-Way ANOVA Test In Words In Symbols Determine the rejection region. Calculate the test statistic. Make a decision to reject or fail to reject the null hypothesis. Interpret the decision in the context of the original claim. If F is in the rejection region, reject H0. Otherwise, fail to reject H0.

Chapter 10 ANOVA Summary Table A table is a convenient way to summarize the results in a one-way ANOVA test. d.f.D SSW Within d.f.N SSB Between F Mean squares Degrees of freedom Sum of squares Variation

Example: Performing a One-Way ANOVA A medical researcher wants to determine whether there is a difference in the mean length of time it takes three types of pain relievers to provide relief from headache pain. Several headache sufferers are randomly selected and given one of the three medications. Each headache sufferer records the time (in minutes) it takes the medication to begin working. The results are shown on the next slide. At α = 0.01, can you conclude that the mean times are different? Assume that each population of relief times is normally distributed and that the population variances are equal.

Example: Performing a One-Way ANOVA Medication 1 Medication 2 Medication 3 12 16 14 15 17 21 20 19 Solution: k = 3 (3 samples) N = n1 + n2 + n3 = 4 + 5 + 4 = 13 (sum of sample sizes)

Solution: Performing a One-Way ANOVA H0: Ha: α = d.f.N= d.f.D= Rejection Region: μ1 = μ2 = μ3 At least one mean is different Test Statistic: Decision: 0. 01 3 – 1 = 2 13 – 3 = 10 F 7.56 0.01

Solution: Performing a One-Way ANOVA To find the test statistic, the following must be calculated.

Solution: Performing a One-Way ANOVA To find the test statistic, the following must be calculated.

Solution: Performing a One-Way ANOVA H0: Ha: α = d.f.N= d.f.D= Rejection Region: μ1 = μ2 = μ3 At least one mean is different Test Statistic: Decision: 0. 01 3 – 1 = 2 13 – 3 = 10 Fail to Reject H0 There is not enough evidence at the 1% level of significance to conclude that there is a difference in the mean length of time it takes the three pain relievers to provide relief from headache pain. F 7.56 0.01 1.50

Example: Using the TI-83/84 to Perform a One-Way ANOVA Three airline companies offer flights between Corydon and Lincolnville. Several randomly selected flight times (in minutes) between the towns for each airline are shown on the next slide. Assume that the populations of flight times are normally distributed, the samples are independent, and the population variances are equal. At α = 0.01, can you conclude that there is a difference in the means of the flight times? Use a TI-83/84.

Example: Using the TI-83/84 to Perform a One-Way ANOVA Airline 1 Airline 2 Airline 3 122 119 120 135 133 158 126 143 155 131 149 125 114 147 116 124 164 134 108 151 142 140 113 136 141

Solution: Using the TI-83/84 to Perform a One-Way ANOVA Ha: Store data into lists L1, L2, and L3 μ1 = μ2 = μ3 At least one mean is different Decision: P-value < α Reject H0 There is enough evidence to support the claim. You can conclude that there is a difference in the means of the flight times.

Two-Way ANOVA Two-way analysis of variance A hypothesis-testing technique that is used to test the effect of two independent variables, or factors, on one dependent variable.

Two-Way ANOVA Example: Suppose a medical researcher wants to test the effect of gender and type of medication on the mean length of time it takes pain relievers to provide relief. Gender Male Female Type of medication I Males taking type I Females taking type I Males taking type II Females taking type II Males taking type III Females taking type III II III

Two-Way ANOVA Hypotheses Main effect The effect of one independent variable on the dependent variable. Interaction effect The effect of both independent variables on the dependent variable.

Two-Way ANOVA Hypotheses Hypotheses for main effects: H0: Gender has no effect on the mean length of time it takes a pain reliever to provide relief. Ha: Gender has an effect on the mean length of time it takes a pain reliever to provide relief. H0: Type of medication has no effect on the mean length of time it takes a pain reliever to provide relief. Ha: Type of medication has an effect on the mean length of time it takes a pain reliever to provide relief.

Two-Way ANOVA Hypotheses Hypotheses for interaction effects: H0: There is no interaction effect between gender and type of medication on the mean length of time it takes a pain reliever to provide relief. Ha: There is an interaction effect between gender and type of medication on the mean length of time it takes a pain reliever to provide relief.

Two-Way ANOVA A two-way ANOVA test calculates an F-test statistic for each hypothesis. It is possible to reject none, one, two, or all of the null hypotheses. Can use a technology tool such as MINITAB to perform a two-way ANOVA test.

Chapter 10 Section 10.4 Summary Used one-way analysis of variance to test claims involving three or more means Introduced two-way analysis of variance

Elementary Statistics: Chapter 10: Chi-Square Tests and the F-Distribution Elementary Statistics: Picturing the World Fifth Edition by Larson and Farber © 2012 Pearson Education, Inc.

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the expected frequency for the Vanilla category. 33.75 22.5 8.1 111.11 Chocolate Vanilla Strawberry Other 62 30 21 12 © 2012 Pearson Education, Inc.

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the expected frequency for the Vanilla category. 33.75 22.5 8.1 111.11 Chocolate Vanilla Strawberry Other 62 30 21 12 © 2012 Pearson Education, Inc.

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the critical value for α = 0.05. 9.488 7.815 2.353 1.645 Chocolate Vanilla Strawberry Other 62 30 21 12 © 2012 Pearson Education, Inc.

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the critical value for α = 0.05. 9.488 7.815 2.353 1.645 Chocolate Vanilla Strawberry Other 62 30 21 12

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the value of the test statistic. 0.949 0.919 37.125 0.010 Chocolate Vanilla Strawberry Other 62 30 21 12 © 2012 Pearson Education, Inc.

The distribution of favorite ice cream flavor is shown in the graph The distribution of favorite ice cream flavor is shown in the graph. The results from a random sample of college students is shown below. Find the value of the test statistic. Chocolate Vanilla Strawberry Other 62 30 21 12

Calculate the expected frequency for the highlighted cell E2,3. 20.62 18.33 16.92 15.38 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 © 2012 Pearson Education, Inc.

Calculate the expected frequency for the highlighted cell E2,3. 20.62 18.33 16.92 15.38 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 OR © 2012 Pearson Education, Inc.

Find the critical value for α = 0.05. 5.991 12.592 2.920 1.645 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 © 2012 Pearson Education, Inc.

Find the critical value for α = 0.05. 5.991 12.592 2.920 1.645 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 © 2012 Pearson Education, Inc.

Find the value of the test statistic. 16.437 15.798 0.751 0.018 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 © 2012 Pearson Education, Inc.

Find the value of the test statistic. 16.437 15.798 0.751 0.018 Favorite Pastime Gender Reading Television Music Male 12 32 19 Female 10 20 17 © 2012 Pearson Education, Inc.

Find the critical F-value for the following situation: Claim: α = 0.10 n1 = 9; n2 = 8 2.75 3.73 3.39 3.50 © 2012 Pearson Education, Inc.

Find the critical F-value for the following situation: Claim: α = 0.10 n1 = 9; n2 = 8 2.75 3.73 3.39 3.50 d.f.N = n1 – 1 d.f.D = n2 – 1 d.f.N = 9 – 1=8 d.f.D = 8 – 1=7

Find the value of the test statistic. Claim: α = 0.10 n1 = 9; n2 = 8 1.64 1.13 0.78 1.28 © 2012 Pearson Education, Inc.

Find the value of the test statistic. Claim: α = 0.10 n1 = 9; n2 = 8 1.64 1.13 0.78 1.28

True or False. The appropriate hypotheses would be H0: Ha: A professor wants to test if the mean score on an exam is the same in all three of his elementary statistics classes. True or False. The appropriate hypotheses would be H0: Ha: True False © 2012 Pearson Education, Inc.

True or False. The appropriate hypotheses would be H0: Ha: A professor wants to test if the mean score on an exam is the same in all three of his elementary statistics classes. True or False. The appropriate hypotheses would be H0: Ha: True False © 2012 Pearson Education, Inc.