830 likes | 1.42k Views
Chapter Outline. 9.1 Correlation9.2 Linear Regression9.3 Measures of Regression and Prediction Intervals9.4 Multiple Regression. 2. Larson/Farber 4th ed.. Section 9.1. Correlation. 3. Larson/Farber 4th ed.. Section 9.1 Objectives. Introduce linear correlation, independent and dependent variables,
E N D
1. Chapter 9 Correlation and Regression 1 Larson/Farber 4th ed.
2. Chapter Outline 9.1 Correlation
9.2 Linear Regression
9.3 Measures of Regression and Prediction Intervals
9.4 Multiple Regression 2 Larson/Farber 4th ed.
3. Section 9.1 Correlation 3 Larson/Farber 4th ed.
4. Section 9.1 Objectives Introduce linear correlation, independent and dependent variables, and the types of correlation
Find a correlation coefficient
Test a population correlation coefficient ? using a table
Perform a hypothesis test for a population correlation coefficient ?
Distinguish between correlation and causation 4 Larson/Farber 4th ed.
5. Correlation 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 5 Larson/Farber 4th ed.
6. Correlation 6 Larson/Farber 4th ed.
7. Types of Correlation 7 Larson/Farber 4th ed.
8. Example: Constructing a Scatter Plot A marketing manager conducted a study to determine whether there is a linear relationship between money spent on advertising and company sales. 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. 8 Larson/Farber 4th ed.
9. Solution: Constructing a Scatter Plot 9 Larson/Farber 4th ed.
10. Example: Constructing a Scatter Plot Using Technology Old Faithful, located in Yellowstone National Park, is the world’s most famous geyser. The duration (in minutes) of several of Old Faithful’s 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. 10 Larson/Farber 4th ed.
11. Solution: Constructing a Scatter Plot Using Technology Enter the x-values into list L1 and the y-values into list L2.
Use Stat Plot to construct the scatter plot. 11 Larson/Farber 4th ed.
12. Correlation Coefficient Correlation coefficient
A measure of the strength and the direction of a linear relationship between two variables.
The symbol r represents the sample correlation coefficient.
A formula for r is
The population correlation coefficient is represented by ? (rho). 12 Larson/Farber 4th ed.
13. Correlation Coefficient The range of the correlation coefficient is -1 to 1. 13 Larson/Farber 4th ed.
14. Linear Correlation 14 Larson/Farber 4th ed.
15. Calculating a Correlation Coefficient 15 Larson/Farber 4th ed.
16. Calculating a Correlation Coefficient 16 Larson/Farber 4th ed.
17. Example: Finding the Correlation Coefficient Calculate the correlation coefficient for the advertising expenditures and company sales data. What can you conclude? 17 Larson/Farber 4th ed.
18. Solution: Finding the Correlation Coefficient 18 Larson/Farber 4th ed.
19. Solution: Finding the Correlation Coefficient 19 Larson/Farber 4th ed.
20. Example: Using Technology to Find a Correlation Coefficient Use a technology tool to calculate the correlation coefficient for the Old Faithful data. What can you conclude? 20 Larson/Farber 4th ed.
21. Solution: Using Technology to Find a Correlation Coefficient 21 Larson/Farber 4th ed.
22. Using a Table to Test a Population Correlation Coefficient ? 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.
22 Larson/Farber 4th ed.
23. Using a Table to Test a Population Correlation Coefficient ? Determine whether ? is significant for five pairs of data (n = 5) at a level of significance of a = 0.01.
If |r| > 0.959, the correlation is significant. Otherwise, there is not enough evidence to conclude that the correlation is significant. 23 Larson/Farber 4th ed.
24. Using a Table to Test a Population Correlation Coefficient ? 24 Larson/Farber 4th ed.
25. Using a Table to Test a Population Correlation Coefficient ? 25 Larson/Farber 4th ed.
26. Example: Using a Table to Test a Population Correlation Coefficient ? Using the Old Faithful data, you used 25 pairs of data to find r ˜ 0.979. Is the correlation coefficient significant? Use a = 0.05. 26 Larson/Farber 4th ed.
27. Solution: Using a Table to Test a Population Correlation Coefficient ? n = 25, a = 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 Faithful’s eruptions and the time between eruptions. 27 Larson/Farber 4th ed.
28. Hypothesis Testing for a Population Correlation Coefficient ? 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.
28 Larson/Farber 4th ed.
29. Hypothesis Testing for a Population Correlation Coefficient ? Left-tailed test
Right-tailed test
Two-tailed test 29 Larson/Farber 4th ed.
30. 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
follows a t-distribution with d.f. = n – 2.
In this text, only two-tailed hypothesis tests for ? are considered. 30 Larson/Farber 4th ed.
31. Using the t-Test for ? 31 Larson/Farber 4th ed.
32. Using the t-Test for ? 32 Larson/Farber 4th ed.
33. Example: t-Test for a Correlation Coefficient Previously you calculated r ˜ 0.9129. Test the significance of this correlation coefficient. Use a = 0.05. 33 Larson/Farber 4th ed.
34. Solution: t-Test for a Correlation Coefficient 34 Larson/Farber 4th ed.
35. Correlation and Causation 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.
Is there a direct cause-and-effect relationship between the variables?
Does x cause y? 35 Larson/Farber 4th ed.
36. Correlation and Causation Is there a reverse cause-and-effect relationship between the variables?
Does y cause x?
Is it possible that the relationship between the variables can be caused by a third variable or by a combination of several other variables?
Is it possible that the relationship between two variables may be a coincidence?
36 Larson/Farber 4th ed.
37. Section 9.1 Summary Introduced 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 37 Larson/Farber 4th ed.
38. Section 9.2 Linear Regression 38 Larson/Farber 4th ed.
39. Section 9.2 Objectives Find the equation of a regression line
Predict y-values using a regression equation 39 Larson/Farber 4th ed.
40. Regression lines After verifying that the linear correlation between two variables is significant, next we determine the equation of the line that best models the data (regression line).
Can be used to predict the value of y for a given value of x.
40 Larson/Farber 4th ed.
41. Residuals Residual
The difference between the observed y-value and the predicted y-value for a given x-value on the line.
41 Larson/Farber 4th ed.
42. Regression line (line of best fit)
The line for which the sum of the squares of the residuals is a minimum.
The equation of a regression line for an independent variable x and a dependent variable y is
y = mx + b
Regression Line 42 Larson/Farber 4th ed.
43. The Equation of a Regression Line y = mx + b where
is the mean of the y-values in the data
is the mean of the x-values in the data
The regression line always passes through the point 43 Larson/Farber 4th ed.
44. Example: Finding the Equation of a Regression Line Find the equation of the regression line for the advertising expenditures and company sales data. 44 Larson/Farber 4th ed.
45. Solution: Finding the Equation of a Regression Line 45 Larson/Farber 4th ed.
46. Solution: Finding the Equation of a Regression Line 46 Larson/Farber 4th ed.
47. Solution: Finding the Equation of a Regression Line To sketch the regression line, use any two x-values within the range of the data and calculate the corresponding y-values from the regression line. 47 Larson/Farber 4th ed.
48. Example: Using Technology to Find a Regression Equation Use a technology tool to find the equation of the regression line for the Old Faithful data. 48 Larson/Farber 4th ed.
49. Solution: Using Technology to Find a Regression Equation 49 Larson/Farber 4th ed.
50. Example: Predicting y-Values Using Regression Equations The regression equation for the advertising expenses (in thousands of dollars) and company sales (in thousands of dollars) data is y = 50.729x + 104.061. Use this equation to predict the expected company sales for the following advertising expenses. (Recall from section 9.1 that x and y have a significant linear correlation.)
1.5 thousand dollars
1.8 thousand dollars
2.5 thousand dollars 50 Larson/Farber 4th ed.
51. Solution: Predicting y-Values Using Regression Equations y = 50.729x + 104.061
1.5 thousand dollars
51 Larson/Farber 4th ed.
52. Solution: Predicting y-Values Using Regression Equations 2.5 thousand dollars 52 Larson/Farber 4th ed.
53. Section 9.2 Summary Found the equation of a regression line
Predicted y-values using a regression equation 53 Larson/Farber 4th ed.
54. Section 9.3 Measures of Regression and Prediction Intervals 54 Larson/Farber 4th ed.
55. Section 9.3 Objectives Interpret the three types of variation about a regression line
Find and interpret the coefficient of determination
Find and interpret the standard error of the estimate for a regression line
Construct and interpret a prediction interval for y 55 Larson/Farber 4th ed.
56. Variation About a Regression Line Three types of variation about a regression line
Total variation
Explained variation
Unexplained variation
To find the total variation, you must first calculate
The total deviation
The explained deviation
The unexplained deviation 56 Larson/Farber 4th ed.
57. Variation About a Regression Line 57 Larson/Farber 4th ed.
58. Total variation
The sum of the squares of the differences between the y-value of each ordered pair and the mean of y.
Explained variation
The sum of the squares of the differences between each predicted y-value and the mean of y. Variation About a Regression Line 58 Larson/Farber 4th ed.
59. Unexplained variation
The sum of the squares of the differences between the y-value of each ordered pair and each corresponding predicted y-value. Variation About a Regression Line 59 Larson/Farber 4th ed.
60. Coefficient of Determination Coefficient of determination
The ratio of the explained variation to the total variation.
Denoted by r2
60 Larson/Farber 4th ed.
61. Example: Coefficient of Determination The correlation coefficient for the advertising expenses and company sales data as calculated in Section 9.1 isr ˜ 0.913. Find the coefficient of determination. What does this tell you about the explained variation of the data about the regression line? About the unexplained variation? 61 Larson/Farber 4th ed.
62. The Standard Error of Estimate Standard error of estimate
The standard deviation of the observed yi -values about the predicted y-value for a given xi -value.
Denoted by se.
The closer the observed y-values are to the predicted y-values, the smaller the standard error of estimate will be. 62 Larson/Farber 4th ed.
63. The Standard Error of Estimate 63 Larson/Farber 4th ed.
64. Example: Standard Error of Estimate The regression equation for the advertising expenses and company sales data as calculated in section 9.2 is y = 50.729x + 104.061
Find the standard error of estimate. 64 Larson/Farber 4th ed.
65. Solution: Standard Error of Estimate 65 Larson/Farber 4th ed.
66. Solution: Standard Error of Estimate 66 Larson/Farber 4th ed.
67. Prediction Intervals Two variables have a bivariate normal distribution if for any fixed value of x, the corresponding values of y are normally distributed and for any fixed values of y, the corresponding x-values are normally distributed. 67 Larson/Farber 4th ed.
68. Prediction Intervals A prediction interval can be constructed for the true value of y.
Given a linear regression equation y = mx + b and x0, a specific value of x, a c-prediction interval for y is
y – E < y < y + E where
The point estimate is y and the margin of error is E. The probability that the prediction interval contains y is c. 68 Larson/Farber 4th ed.
69. Constructing a Prediction Interval for y for a Specific Value of x 69 Larson/Farber 4th ed.
70. Constructing a Prediction Interval for y for a Specific Value of x 70 Larson/Farber 4th ed.
71. Example: Constructing a Prediction Interval Construct a 95% prediction interval for the company sales when the advertising expenses are $2100. What can you conclude?
Recall, n = 8, y = 50.729x + 104.061, se = 10.290 71 Larson/Farber 4th ed.
72. Solution: Constructing a Prediction Interval 72 Larson/Farber 4th ed.
73. Section 9.3 Summary Interpreted the three types of variation about a regression line
Found and interpreted the coefficient of determination
Found and interpreted the standard error of the estimate for a regression line
Constructed and interpreted a prediction interval for y 73 Larson/Farber 4th ed.
74. Section 9.4 Multiple Regression 74 Larson/Farber 4th ed.
75. Section 9.4 Objectives Use technology to find a multiple regression equation, the standard error of estimate and the coefficient of determination
Use a multiple regression equation to predict y-values 75 Larson/Farber 4th ed.
76. Multiple Regression Equation In many instances, a better prediction can be found for a dependent (response) variable by using more than one independent (explanatory) variable.
For example, a more accurate prediction for the company sales discussed in previous sections might be made by considering the number of employees on the sales staff as well as the advertising expenses. 76 Larson/Farber 4th ed.
77. Multiple Regression Equation Multiple regression equation
y = b + m1x1 + m2x2 + m3x3 + … + mkxk
x1, x2, x3,…, xk are independent variables
b is the y-intercept
y is the dependent variable
77 Larson/Farber 4th ed.
78. Example: Finding a Multiple Regression Equation A researcher wants to determine how employee salaries at a certain company are related to the length of employment, previous experience, and education. The researcher selects eight employees from the company and obtains the data shown on the next slide. Use Minitab to find a multiple regression equation that models the data.
78 Larson/Farber 4th ed.
79. Example: Finding a Multiple Regression Equation 79 Larson/Farber 4th ed.
80. Solution: Finding a Multiple Regression Equation Enter the y-values in C1 and the x1-, x2-, and x3-values in C2, C3 and C4 respectively.
Select “Regression > Regression…” from the Stat menu.
Use the salaries as the response variable and the remaining data as the predictors. 80 Larson/Farber 4th ed.
81. Solution: Finding a Multiple Regression Equation 81 Larson/Farber 4th ed.
82. Predicting y-Values After finding the equation of the multiple regression line, you can use the equation to predict y-values over the range of the data.
To predict y-values, substitute the given value for each independent variable into the equation, then calculate y. 82 Larson/Farber 4th ed.
83. Example: Predicting y-Values Use the regression equation y = 49,764 + 364x1 + 228x2 + 267x3to predict an employee’s salary given 12 years of current employment, 5 years of experience, and 16 years of education.
83 Larson/Farber 4th ed.
84. Section 9.4 Summary Used technology to find a multiple regression equation, the standard error of estimate and the coefficient of determination
Used a multiple regression equation to predict y-values 84 Larson/Farber 4th ed.