Presentation is loading. Please wait.

Presentation is loading. Please wait.

SECTION 6.2 Linear Regression

Similar presentations


Presentation on theme: "SECTION 6.2 Linear Regression"— Presentation transcript:

1 SECTION 6.2 Linear Regression
Objectives: Find the line of best fit for two quantitative variables by hand. Find the line of best fit using the calculator. Make predictions based upon the equation of the line of best fit.

2

3 If there is a strong linear relationship between two variables (positive or negative), a line of best fit, or a line that best fits the data, can be used to make predictions. This is also called a trend line, regression line, least-squares line, or a linear regression.

4 Finding the Line of Best Fit
A line of best fit (or "trend" line) is a straight line that best represents the data on a scatter plot.  This line may pass through some of the points, none of the points, or all of the points. You can examine lines of best fit with:      1. paper and pencil only      2. a combination of graphing calculator and paper and pencil      3. or solely with the graphing calculator

5 Example:  Is there a relationship between the fat grams and the total calories in fast food?
Sandwich Total Fat (g) Total Calories Hamburger Cheeseburger Quarter Pounder Quarter Pounder with Cheese Big Mac Arch Sandwich Special Arch Special with Bacon Crispy Chicken Fish Fillet Grilled Chicken Grilled Chicken Light

6 Paper and Pencil Solution:
1.  Create a scatter plot of the data on graph paper. Use a straight edge to draw the line of best fit. 2.  Find two points that you think will be on the "best-fit" line.  Different people may choose different points. Calculate the slope of the line through your two points (rounded to three decimal places).  4.  Write the equation of the line.  This equation can now be used to predict information that was not plotted in the scatter plot.  For example, you can use the equation to find the total calories based upon 22 grams of fat.

7 Graphing Calculator Solution:
Different people may choose different points and arrive at different equations.  All of them are "correct", but which one is actually the "best"?  To determine the actual "best" fit, we will use a graphing calculator. Graphing Calculator Solution: 1.  Enter the data in the calculator lists.  Place the data in L1 and L2.       STAT, #1Edit, type values into the lists 2.  Prepare a scatter plot of the data.  Set up for the scatterplot.       2nd StatPlot - choose the first icon.   Choose ZOOM #9 ZoomStat. 3.  Have the calculator determine the line of best fit.   STAT → CALC #4 LinReg(ax+b)  

8 You now have the values of a and b needed to write the equation of the actual line of best fit.              y = x   4.  Graph the line of best fit.  Simply hit GRAPH. To get a predicted value within the window, hit TRACE, up arrow, and type the desired value.  The screen shows x = 22.

9 Slope-intercept equation y = mx + b Linear Regression Equation
In Geometry, m = slope b = y-intercept In Stats, a = slope b = y-intercept Slope-intercept equation y = mx + b Linear Regression Equation y = ax + b

10 HINT: When drawing a line of best fit, try to have about the same number of points above and below the line. EXAMPLE 1 Albany and Sydney are about the same distance from the equator. Make a scatter plot with Albany’s temperature as the independent variable. Name the type of correlation. Then sketch a line of best fit and find its equation.

11 Step 1: Plot the data points. Step 2: Identify the correlation.
Notice that the data set is negatively correlated–as the temperature rises in Albany, it falls in Sydney.

12 Step 3: Sketch a line of best fit.
Draw a line that splits the data evenly above and below.

13 Step 4: Identify two points on the line.
For this data, you might select (35, 64) and (85, 41). Step 5: Find the slope of the line that models the data. Use the point-slope form. y –y1= m(x –x1) y –64= –0.46(x –35) y = –0.46x An equation that models the data is y = –0.46x

14 Example 2: Anthropology Application
Anthropologists can use the femur, or thighbone, to estimate the height of a human being. The table shows the results of a randomly selected sample.

15 c.) Interpret the slope of the equation in the context of the problem.
a.) Make a scatter plot of the data with femur length as the independent variable. b.) Use the calculator to find the correlation coefficient and the equation of the line of best fit. h = 2.91f r = .99 (strong positive) c.) Interpret the slope of the equation in the context of the problem. The slope is about 2.91, so for each 1 cm increase in femur length, the predicted increase in a human being’s height is 2.91 cm.

16 A man’s femur is 41 cm long. Predict the man’s height.
The equation of the line of best fit is h = 2.91f Use the equation to predict the man’s height. For a 41-cm-long femur h = 2.91(41) The height of a man with a 41-cm-long femur would be about 173 cm.

17 Example 3: The gas mileage for randomly selected cars based upon engine horsepower is given in the table. a.) Make a scatter plot of the data with horsepower as the independent variable

18 b.) Find the correlation coefficient r and the line of best fit.
y = –0.15x r=-.916 (strong negative) c.) Interpret the slope of the line of best fit in the context of the problem. The slope is about –0.15, so for each 1 unit increase in horsepower, gas mileage drops ≈ 0.15 mi/gal.

19 d.) Predict the gas mileage for a 210-horsepower engine.
The equation of the line of best fit is y ≈ –0.15x Use the equation to predict the gas mileage. For a 210-horsepower engine, y = –0.15(210) y = 16 The mileage for a 210-horsepower engine would be about 16.0 mi/gal.

20 Example 4 Find the following information for this data set on the number of grams of fat and the number of calories in sandwiches served at Dave’s Deli. Use the equation of the line of best fit to predict the number of grams of fat in a sandwich with 420 Calories. 420 ≈ 11.1x How close is your answer to the value given in the table? The line predicts 10 grams of fat. This is not close to the 15 g in the table.

21 Calculator Practice Use your calculator to find each of the following:
Scatterplot Correlation Coefficient Linear Regression Equation Graph the Linear Regression Line

22 Calculator Practice Use your calculator to find each of the following:
Scatterplot Correlation Coefficient Linear Regression Equation Graph the Linear Regression Line


Download ppt "SECTION 6.2 Linear Regression"

Similar presentations


Ads by Google