Notes 1.5 Scatterplots and Least-Square Lines

Notes 1.5 Scatterplots and Least-Square Lines

Algebra II CP1

Notes 1.5 Scatterplots and Least-Square Lines

What is a correlation coefficient?

  • Represented by the letter ______
  • The closer ______is to ______or ______then the more perfect the fit is.

Types of Scatter Plots

Ways to Determine the Line of Best Fit (AKA the Least-Sqares Line or Least-Squares Regression)

Method #1: Draw a scatter plot, sketch in what you think is the line of best, calculate the slope and the y-intercept.

Method #2: Using the graphing calculator.

Step 1: Enter the data

  • Go to STAT (located in the center column under the DEL button) and select #1 EDIT. Now you can enter values into the different list columns.
  • If you want to clear all the entries from a list then arrow up so that the list number is highlighted and hit CLEAR (located in the far right column above the carat key) and then hit enter. All list entries will be cleared out. If you accidentally hit DEL instead of CLEAR then the entire list column will be deleted. To get it back, go to STAT and select #5 SETUpEditor and hit enter. You will now get a DONE message on your home screen and all lists will be restored.

Exercise: Enter total fat into L1, calories from fat into L2, and total calories into L3.

Sandwich (McDonalds) / Total Fat (g) / Calories from Fat / Total Calories
Hamburger / 9 / 80 / 260
Cheeseburger / 13 / 120 / 320
Quarter Pounder / 21 / 190 / 420
Quarter Pounder with Cheese / 30 / 270 / 530
Big Mac / 31 / 280 / 560
Arch Deluxe / 31 / 280 / 550
Arch Deluxe with Bacon / 34 / 310 / 590
Crispy Chicken Deluxe / 25 / 220 / 500
Fish Fillet Deluxe / 28 / 250 / 560
Grilled Chicken Deluxe / 20 / 180 / 440
Grilled Chicken Plain / 5 / 45 / 300

Step 2 (OPTONAL-not done in class): If you want to view the scatterplot, you need to adjust your window and turn on the STAT PLOTS. (Note: This step is not required to determine the line of best fit)

  • Make sure that Y= is cleared out or that all equations’ equal signs are un-highlighted as to not graph lines and curves over your data set.
  • Go to StatPlots by selecting 2nd Y=.
  • Select PLOT1 and turn the plot ON.
  • Select the type. The first option is the scatterplot.
  • Xlist is where the x-data values are stored which is defaulted to L1. If necessary you can select a different list number by using 2nd and then the appropriate number.
  • Ylist is where the y-data values are stored which is defaulted to L2.
  • Mark is how you would like the data points to be displayed.
  • Adjust the window to fit the data. ZoomStat (option 9 under Zoom) will do this for you or consider the range of your variables. For example since the x-values range from 5 to 34 then a window setting of Xmin=0 and Xmax=40 is sufficient.
  • Select GRAPH to view the scatterplot.
  • Once you are done with the scatterplot, you can quickly turn off your plots by going to Y= and scroll up to the PLOT1 and hit enter to un-highlight.

Step 3: Run the Linear Regression:

  • Go to STAT, arrow over to CALC and select option #4, LinReg. Note by default, L1 and L2 are used as the XList and YList. If needed, use second and then the appropriate number to change a list.
  • Scroll down and hit enter on Calculate. Note “a” is the slope and “b” is the y-intercept.
  • If you do not get “r” values, go to your catalog (2nd Zero) and scroll down until you see “Diagnostic On”. Hit enter to pull this to the home screen. Hit enter to run the command and now you will get a message that says “Done”. Now if you run the regression again, you should get your “r” values.
  • Note: We will run other regressions in addition to linear ones.
  • A common error message “DIM MISMATCH”. This means that your lists do not contain an equal number of data points. For every “x” there must be a “y” so you missed have missed a data value.

Exercises:

1) Determine the line of best fit that relates total fat (L1) to fat calories (L2). Round to four decimals.

  1. What is the correlation coefficient to four decimals? What is its significance?
  1. Interpret the meaning of the slope and the y-intercept within the context of this data set. Relate to what you learned in health class!
  1. How many fat calories would you expect to find in a McDonald’s sandwich with 14 grams of fat?
  1. If a sandwich has 210 fat calories, how many grams of fat would expect the sandwich to have?

2) Determine the line of best fit that relates total fat (L1) to total calories (L3). Round all decimals to four places. Also state the correlation coefficient and its significance.

  1. Interpret the meaning of the slope and the y-intercept in the context of this data.
  1. If McDonalds were going to introduce a New McRabbit sandwich, and we found that it contained 16 grams of fat, how many total calories would you expect?

Exercise: Scientists have monitored the number of chirps per minute made by crickets and the corresponding temperature.

Number of Chirps/Min / 136 / 165 / 98 / 110 / 150 / 210 / 84 / 158 / 221 / 178
Temp (F) / 72 / 84 / 68 / 75 / 80 / 94 / 60 / 75 / 92 / 89

1) Which is the independent variable?

2) Determine the line of best fit rounding decimals to four places.

3) What is suggested by the correlation coefficient?

4) Predict the number of chirps per minute if the temperature is 70° F.