500 likes | 695 Views
BVD Ch. 7. Scatterplots, boo ya!. Examining Relationships. Two variablesExplanatory
E N D
1. APSTAT Section Two Line it up!!!!!
2. BVD Ch. 7 Scatterplots, boo ya!
3. Examining Relationships Two variables
Explanatory Explains the change (cause-ish)
Response Outcome (effect-ish)
ie. Amount of Time Studying Vs. GPA
4. Scatterplot Explanatory (if there is one) variable on X-Axis
Response (if there is one) variable on Y-Axis
Important things to look for
Direction Positive, Negative
Strength of association, from weak to strong
Form Linear, Curved, Groupings
Outliers and any other weirdness
5. Hedge Words Adjectives (?) that keep us out of trouble:
Somewhat
Fairly
Moderately
Roughly
Rather
More or less
Reasonably
Sort of
6. Describe this -
7. Correlation Coefficient- r Numerical representation of strength and direction
Denoted by r
Formula:
8. Lets do it by hand-ish!!! Data:
n=5, but to find other stuff, lets cheat and use the TI-83
Pop Age into L1 and HRs into L2
STAT>CALC>2VariableStats
x =14, Sx=3.2, y =11, Sy=3.4
9. Lets do it by hand-ish!!! Data:
n=5, x =14, Sx=3.2, y =11, Sy=3.4
So
10. Want an Easier Way??? STAT>CALC>LinReg
r =
r2 =
Plus other cool stuff for later
Not working? Turn Diagnostics on!
Catalog>DiagnosticsOn>ENTER
11. What is r ? Shows Direction
If positive, slope of points is positive
If negative, slope is negative
12. More r Shows Strength of LINEAR Relationship
13. Describing Strength of Linear Relationship
14. Lets do one Data: Score on APStat Final vs Score on Alg2 Final
Use TI-83 to graph, sketch it
Pop into L1 and L2, StatPlot, Window
Find r
Describe correlation
15. Averaged Data Using averaged data
Reduces variability
OK, but understand correlation will likely be higher than if you had used individuals.
Example - Heights in classrooms vs individual heights
16. Causation Correlation shows an ASSOCIATION
DOES NOT show a cause and effect relationship
Only with a well controlled experiment can even consider talking about cause and effect
17. Lurking Variable Variables you cant see, but might be causative factors
18. Common Respose Does a high GPA lead to a High SAT score?
Is there something that affects both?
19. Confounding Influence of a lurking variable on the response variable
Ex. A study finds that people who drink in bars have a higher chance of developing lung cancer.
20. BVD Ch. 8 A Linear Model
21. Least Squares Regression Idea:
Hmmm.Could a line model the data???
22. LSRL Basics
23. LSRL Basics
24. LSRL Line that Minimizes the Sum of the SQUARE of the residuals
25. LSRL Equation BOOK VS. AP EXAM
26. TGFC! Linear Regression on TI-83 STAT>CALC>LinReg(a + bx)
Gives you:
LinReg
y=a+bx
a= -3.7
b= 1.05
r2=.9587
r=.9791
27. Fun with our LSRL Interpret Y-intercept:
Interpret Slope:
Interpolation
Timmy is 13, what is his predicted total of home runs?
Extrapolation (not a good idea)
When Timmy is 104, how many HRs?
28. What is r2 anyway? Simple answer:
Take r (correlation coefficient) and square it
Not so simple, but most important answer:
Coefficient of determination
Fraction (or percentage) of variation in y-values that can be explained by a linear relationship with x
ie. In HR/Age problem, roughly 96% of the variation in home runs can be explained by a linear relationship with age
29. Residual Love Remember this?
30. Residual Plot Plotting Residual Error vs. X - Value
31. Why Residual Plot? Can Show Patterns (Bad News)
32. Patterns Part 2 How bout this one
33. Residual Issues, Crazy Points Check Dis
34. Residual Issues 2 Uno mas
35. Using TI-83 for LSRL Store LSRL from LinReg into Y1
STAT>CALC>LinReg
Press enter
STO>VARS>Y-VARS>Funtion> Y1
Go to STAT PLOT change options
Go to Zoom>ZoomStat
Beautiful!
36. Using TI-83 to Graph Resids LSRL MUST be stored in Y1 for this to work
LIST>NAMES>RESID
Press ENTER STO> L3 (in LIST) and press ENTER again
Now graph go to STAT PLOT and change stuff
X is still the old X (L1)
Y is now the residuals (L3)
Graph it!!!
37. BVD Ch. 9 Blah Blah Blah
38. Outliers Technically, anything outside of overall pattern
Usually in y direction (up/down)
If in x direction (side/side), we call it an influential point.
40. Influential Points How to find:
Plot LSRL with influential point and without
Compare Linear regression line and correlation coefficient
If no data, just sketch and show change without influential point
41. BVD Ch. 10 My data is curvy!
42. CURVY DATA Sometimes data is not really linear
2 ways to deal
Easy (but incomplete) way on calc
Hard (correct) way using LOGs
43. Money in the bank Put in 1 G at 10% and wait 10 years
44. The easy way (TI83) Yr. $$$$
0 1000
1 1100
2 1210
3 1331
4 1464
5 1600
6 1760
7 1930
8 2120
9 2330
10 2563
45. The correct way (using logs) Yr. $$$$ LOGY
0 1000 3.00
1 1100 3.04
2 1210 3.08
3 1331 3.12
4 1464 3.17
5 1600 3.20
6 1760 3.25
7 1930 3.29
8 2120 3.33
9 2330 3.36
10 2563 3.41
46. Predicted Value Ex: How much in bank at 5.5 years?
log = 3.001+0.0407x
Throw in 5.5 for x
47. Double Log Situation Log both X and y
But Why???
After logging y, resids still show curviness
Power Functions!
48. Here We Go!!! Ht WT
5 102
5.25 113
5.5 125
5.75 137
6 151
6.25 166
49. Log y only
50. Log x and log y
51. MUY IMPORTANTE!!!!!! USE LSRL and R-Squared
ONLY FOR LINEAR MODELS
ONLY IF THERE ARE NO EXTREME OBSERVATIONS
ONLY USE LSRL FOR INTERPOLATION
NO EXTRAPOLATION!!!!!