SECTION 9.2 Linear Regression 487 GDP (in trillions of dollars), x CO2 emissions (in millions of metric tons), y 1.7 620.1 2.4 475.2 3.0 457.6 1.2 389.7 4.1 810.8 2.3 352.9 0.9 235.0 1.8 297.8 2.9 413.9 5.4 1216.5 The equation of a regression line allows you to use the independent (explanatory) variable x to make predictions for the dependent (response) variable y. The equation of a regression line for an independent variable x and a dependent variable y is ny = mx + b where ny is the predicted y@value for a given x@value. The slope m and y@intercept b are given by m = nΣxy - 1Σx21Σy2 nΣx2 - 1Σx22 and b = y - mx = Σy n - m Σx n where y is the mean of the y@values in the data set, x is the mean of the x@values, and n is the number of pairs of data. The regression line always passes through the point 1x, y2. The Equation of a Regression Line Finding the Equation of a Regression Line Find the equation of the regression line for the gross domestic products and carbon dioxide emissions data used in Section 9.1. (See table at the left.) SOLUTION Recall from Example 7 of Section 9.1 that there is a significant linear correlation between gross domestic products and carbon dioxide emissions. Also, in Example 4 of Section 9.1, you found that n = 10, Σx = 25.7, Σy = 5269.5, Σxy = 16,687.99, and Σx2 = 82.81. You can use these values to calculate the slope m of the regression line m= nΣxy - 1Σx21Σy2 nΣx2 - 1Σx22 = 10116,687.992 - 125.7215269.52 10182.812 - 125.722 ≈ 187.660343 and its y@intercept b. b = y - mx ≈ 5269.5 10 - 1187.6603432a 25.7 10 b ≈ 44.663 So, the equation of the regression line is ny = 187.660x + 44.663. To sketch the regression line, first choose two x@values between the least and greatest x@values in the data set. Next, calculate the corresponding y@values using the regression equation. Then draw a line through the two points. The regression line and scatter plot of the data are shown at the right. Notice that the line passes through the point 1x, y2 = 12.57, 526.952. EXAMPLE 1 x GDP (in trillions of dollars) CO2 emissions (in millions of metric tons) y (x, y) 1 2 3 4 5 6 200 400 600 800 1000 1200 1400 Study Tip In Example 1, when writing the equation of a regression line, the slope m and the y@intercept b are rounded to three decimal places. This round-off rule will be used throughout the text. Tech Tip Although formulas for the slope and y@intercept are given, it is more convenient to use technology to calculate the equation of a regression line (see Example 2).
RkJQdWJsaXNoZXIy NjM5ODQ=