Presentation is loading. Please wait.

Presentation is loading. Please wait.

Statistics Correlation

Similar presentations


Presentation on theme: "Statistics Correlation"— Presentation transcript:

1 Statistics Correlation

2 Inputs and Outputs In formulas, some variables are “input” variables The thing you are calculating with the formula is the “output”

3 Inputs and Outputs In a factory, the inputs are the components

4 Inputs and Outputs The output is the final product

5 Inputs and Outputs The input variable is ALWAYS put on the x-axis (horizontal axis) No reason – it’s a TRADITION!

6 Inputs and Outputs It can sometimes be hard to figure out which is the input variable and which the output variable

7 Inputs and Outputs Input variables sometimes CAUSE the result

8 Inputs and Outputs Sometimes input variables occur before the out variables

9 Inputs and Outputs Frequently the input variables cannot be controlled by us (time, for example) For this reason, input variables are frequently called “independent” variables

10 Inputs and Outputs And, the output variables (which depend on the values of the independent input variables) are called “dependent” variables

11 Questions?

12 Correlation A relationship can be seen by graphing the independent and dependent variables in a scatter graph

13 Correlation A linear relationship is very common

14 Correlation When we calculated a correlation coefficient, we said it was a measure of the closeness to a linear relationship between the two variables

15 Line of Best Fit That means, we could find the formula for a line that would be the best fit for the two variables

16 Line of Best Fit We “fit” a line to the data

17 Line of Best Fit Real-world data rarely lands exactly on a straight line

18 Line of Best Fit But we fit the “best” line to the data

19 Line of Best Fit When you graph two variables on an x-y plot, you can fit a line through the data called a “trend line”

20 Line of Best Fit This trend line is a “line of best fit” to the data

21 Regression The “line of best fit” is created by minimizing the total distance of all the points to the line (deviations)

22 Regression The line of best fit is called the “regression” line

23 Regression Because it is a line, it has an equation: y = b + mx m = slope b = y-intercept

24 Regression The slope “m” and the correlation coefficient “r” will both have the same sign

25 Regression R2 tells how closely the regression line “fits” the data – “goodness of fit”

26 Regression As you can imagine, the calculations for correlation and the regression line are scary

27 Regression Hooray for Excel!

28 Regression Francis Galton

29

30 Questions?

31 Regression in Excel Does coming to class affect my grade?

32 What Does It Say?

33 Regression in Excel Edwin Hubble gathered and analyzed data from astronomical objects He used regression to show that the universe is expanding

34 Regression in Excel Let’s take a look!

35

36 Regression in Excel What do we do first?

37 Regression in Excel What do we do first? GRAPH THE DATA!

38 Regression in Excel

39 Regression in Excel Does it look like a straight line would fit the data well?

40 Regression in Excel Now we’re going to go to: Data Data Analysis Regression

41 Regression in Excel They want “y” first (I HATE this…)

42 Regression in Excel Let’s use “distance” for “x” and “velocity” for “y”

43 Regression in Excel Eeek! What’s all this????

44 Regression in Excel Here’s the RSQ. What is the %?

45 Regression in Excel For the trend line, you need:

46 Regression in Excel This (believe it or not) is the equation of the line of best fit!

47 Regression in Excel Line of best fit: y = mx + b

48 Regression in Excel Our equation is: Vel = x Dist

49 Regression in Excel Highlight and copy:

50 Regression in Excel Paste on the “Hubble” page

51 Regression in Excel Add a new column heading: Trend

52 We’re going to calculate our line:

53 Copy it down…

54 Oops! That doesn’t look right!

55 The reference cells are changing for each row We need to make those constant

56 Go back to the first entry Add a $ before the row numbers you want to keep constant

57 Now, copy it down!

58 Much better!

59 Regression in Excel Create a new graph:

60 Regression in Excel Make it purty! To make the trend line a line: change Marker Options to “none” change line color to “solid line”

61 TAH-DAH!

62 What Does It Say?

63 Regression Note: some people use the symbol “ŷ” for the trend data corresponding to the “y” observation data

64 Regression in Excel Summary of Regression Analysis: Data/Data Analysis/Regression Enter “y” first Copy the first two coefficients in the bottom table Trend line is: =Coeff*Data+Intercept Make a graph Change the trend dots into a line

65 Questions?


Download ppt "Statistics Correlation"

Similar presentations


Ads by Google