# Elementary Statistics: Picturing The World, 6e Elementary Statistics: Picturing The World Sixth Edition Chapter 9 Correlation and Regression Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Chapter Outline 9.1 Correlation 9.2 Linear Regression 9.3 Measures of Regression and Prediction Intervals 9.4 Multiple Regression Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Section 9.1

Correlation Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Section 9.1 Objectives An introduction to linear correlation, independent and dependent variables, and the types of correlation How to find a correlation coefficient How to test a population correlation coefficient using a table How to perform a hypothesis test for a population correlation coefficient How to distinguish between correlation and causation Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Correlation (1 of 2) Correlation A relationship between two variables.

The data can be represented by ordered pairs (x, y) x is the independent (or explanatory) variable y is the dependent (or response) variable Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Correlation (2 of 2) A scatter plot can be used to determine whether a linear (straight line) correlation exists between two variables. Example x 1 2 3 y 4 2 1 4 0 5 2

Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Types of Correlation Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Constructing a Scatter Plot (1 of 2) An economist wants to determine whether there is a linear relationship between a countrys gross domestic product (GDP) and carbon dioxide (CO2) emissions. The data are shown in the table. Display the data in a scatter plot and determine whether there appears to be a positive or negative linear

correlation or no linear correlation. (Source: World Bank and U.S. Energy Information Administration) CO2 emission GDP (millions of (trillions of \$), metric tons), x y 1.6 428.2 3.6 828.8 4.9 1214.2 1.1 444.6 0.9

264.0 2.9 415.3 2.7 571.8 2.3 454.9 1.6 358.7 1.5 573.5 Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Constructing a Scatter Plot (2 of 2) Appears to be a positive linear correlation. As the gross domestic products increase, the carbon dioxide emissions

tend to increase. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Constructing a Scatter Plot Using Technology (1 of 2) Old Faithful, located in Yellowstone National Park, is the worlds most famous geyser. The duration (in minutes) of several of Old Faithfuls eruptions and the times (in minutes) until the next eruption are shown in the table. Using a TI-83/84, display the data in a scatter plot. Determine the type of correlation. Duration Time, Duration Time,

x y x y 1.8 56 3.78 79 1.82 58 3.83 85 1.9 62 3.88 80 1.93 56 4.1

89 1.98 57 4.27 90 2.05 57 4.3 89 2.13 60 4.43 89 2.3 57 4.47 86 2.37 61

4.53 89 2.82 73 4.55 86 3.13 76 4.6 92 3.27 77 4.63 91 3.65 77 blank blank

Calculate the correlation coefficient for the gross domestic products and carbon dioxide emissions data. What can you conclude? CO2 emission GDP (millions of (trillions of \$), metric tons), x y 1.6 428.2 3.6 828.8 4.9 1214.2 1.1

444.6 0.9 264.0 2.9 415.3 2.7 571.8 2.3 454.9 1.6 358.7 1.5 573.5 Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Calculating the Correlation Coefficient (2 of 3) x

y xy x2 y2 1.6 428.2 685.12 2.56 183,355.24 3.6 828.8 2983.68 12.96 686,909.44 4.9 1214.2 5949.58 24.01 1,474,281.64

1.1 444.6 489.06 1.21 197,669.16 0.9 264.0 237.6 0.81 69,696 2.9 415.3 1204.37 8.41 172,474.09 2.7 571.8 1543.86 7.29

326,955.24 2.3 454.9 1046.27 5.29 206,934.01 1.6 358.7 573.92 2.56 128,665.69 1.5 573.5 860.25 2.25 328,902.25 x = 23.1 y = 5554 xy = 15,573.71 x2 = 67.35 y2 = 3,775,842.76 Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved

Example: Calculating the Correlation Coefficient (3 of 3) r 0.882 suggests a strong positive linear correlation. As the gross domestic product increases, the carbon dioxide emissions also increase. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Using Technology to Find a Correlation Coefficient (1 of 2) Use a technology tool to calculate the correlation coefficient for the Old Faithful data. What can you conclude? Duration Time, Duration Time, x y

x y 1.8 56 3.78 79 1.82 58 3.83 85 1.9 62 3.88 80 1.93 56 4.1 89 1.98

57 4.27 90 2.05 57 4.3 89 2.13 60 4.43 89 2.3 57 4.47 86 2.37 61 4.53 89

2.82 73 4.55 86 3.13 76 4.6 92 3.27 77 4.63 91 3.65 77 blank blank Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved

Example: Using Technology to Find a Correlation Coefficient (2 of 2) Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Using a Table to Test a Population Correlation Coefficient (1 of 4) Once the sample correlation coefficient r has been calculated, we need to determine whether there is enough evidence to decide that the population correlation coefficient is significant at a specified level of significance. Use Table 11 in Appendix B. If |r| is greater than the critical value, there is enough evidence to decide that the correlation coefficient is significant. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved

Using a Table to Test a Population Correlation Coefficient (2 of 4) Determine whether is significant for five pairs of data (n = 5) at a level of significance of = 0.01. If |r| > 0.959, the correlation is significant. Otherwise, there is not enough evidence to conclude that the correlation is significant. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Using a Table to Test a Population Correlation Coefficient (3 of 4) In Words 1. Determine the number of pairs of data in the sample. 2. Specify the level of significance. 3. Find the critical value.

In Symbols Determine n. Identify . Use Table 11 in Appendix B. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Using a Table to Test a Population Correlation Coefficient (4 of 4) In Words 4. Decide if the correlation is significant. In Symbols If |r| > critical value, the correlation is significant. Otherwise, there is not enough

evidence to support that the correlation is significant. 5. Interpret the decision in the blank context of the original claim. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: Using a Table to Test a Population Correlation Coefficient (1 of 2) Using the Old Faithful data, you used 25 pairs of data to find r 0.979. Is the correlation coefficient significant? Use = 0.05. Duration Time, Duration Time, x y

x y 1.8 56 3.78 79 1.82 58 3.83 85 1.9 62 3.88 80 1.93 56 4.1 89 1.98

57 4.27 90 2.05 57 4.3 89 2.13 60 4.43 89 2.3 57 4.47 86 2.37 61 4.53 89

2.82 73 4.55 86 3.13 76 4.6 92 3.27 77 4.63 91 3.65 77 blank blank Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved

Example: Using a Table to Test a Population Correlation Coefficient (2 of 2) Solution n = 25, = 0.05 |r| 0.979 > 0.396 There is enough evidence at the 5% level of significance to conclude that there is a significant linear correlation between the duration of Old Faithfuls eruptions and the time between eruptions. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Hypothesis Testing for a Population Correlation Coefficient (1 of 2) A hypothesis test can also be used to determine whether the sample correlation coefficient r provides enough evidence to conclude that the population

correlation coefficient is significant at a specified level of significance. A hypothesis test can be one-tailed or two-tailed. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Hypothesis Testing for a Population Correlation Coefficient (2 of 2) Left-tailed test H0: 0 (no significant negative correlation) Ha: < 0 (significant negative correlation) Right-tailed test H0: 0 (no significant positive correlation) Ha: > 0 (significant positive correlation Two-tailed test H0: = 0 (no significant correlation) Ha: 0 (significant correlation)

Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved The t-Test for the Correlation Coefficient Can be used to test whether the correlation between two variables is significant. The test statistic is r. The standardized test statistic Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Using the t-Test for (1 of 2) 1. 2. 3. 4. In Words State the null and

alternative hypothesis. Specify the level of significance. Identify the degrees of freedom. Determine the critical value(s) and rejection region(s). In Symbols State H0 and Ha. Identify . d.f. = n 2. Use Table 5 in Appendix B. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Using the t-Test for (2 of 2)

Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: t-Test for a Correlation Coefficient (1 of 2) Previously you calculated r 0.882. Test the significance of this correlation coefficient. Use = 0.05. CO2 emission GDP (millions of (trillions of \$), metric tons), x y 1.6 428.2

3.6 828.8 4.9 1214.2 1.1 444.6 0.9 264.0 2.9 415.3 2.7 571.8 2.3 454.9 1.6 358.7 1.5 573.5

Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Example: t-Test for a Correlation Coefficient (2 of 2) Decision: Reject H0 At the 5% level of significance, there is enough evidence to conclude that there is a significant linear correlation between gross domestic products and carbon dioxide emissions. Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Correlation and Causation (1 of 2) The fact that two variables are strongly correlated does not in itself imply a cause-and-effect relationship between the variables. If there is a significant correlation between two

variables, you should consider the following possibilities. 1. Is there a direct cause-and-effect relationship between the variables? Does x cause y? Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Correlation and Causation (2 of 2) 2. Is there a reverse cause-and-effect relationship between the variables? Does y cause x? 3. Is it possible that the relationship between the variables can be caused by a third variable or by a combination of several other variables? 4. Is it possible that the relationship between two variables may be a coincidence?

Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved Section 9.1 Summary Introduced to linear correlation, independent and dependent variables and the types of correlation Found a correlation coefficient Tested a population correlation coefficient using a table Performed a hypothesis test for a population correlation coefficient Distinguished between correlation and causation Copyright 2015, 2012, 2009 Pearson Education, Inc. All Rights Reserved