Post on 18-Jan-2016
SPSS
SPSS Problem #2
• 7.37 (7.19)
• 7.11 (b)
Smile
Jerry 10
Elan 6
George 8
Newman 9
Kramer 7
Smile
Jerry 10
Elan 6
George 8
Newman 9
Kramer 7
You can calculate:
Central tendency
Variability
You could graph the data
Talk
Jerry 5
Elan 1
George 3
Newman 4
Kramer 2
You can calculate:
Central tendency
Variability
You could graph the data
Bivariate Distribution
Smile Talk
Jerry 10 5
Elan 6 1
George 8 3
Newman 9 4
Kramer 7 2
Positive Correlation
Smile Talk
Jerry 10 5
Elan 6 1
George 8 3
Newman 9 4
Kramer 7 2
Positive Correlation
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
Correlation
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
r = 1.00
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
. . .. .
r = .64
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
. .. .
r = .64
.
Practice
Smile Talk
Jerry 9 5
Elan 2 1
George 5 3
Newman 4 4
Kramer 3 2
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
.
.. ..
Regression Line
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Smil
e
.
.. ..
Frown Talk
Jerry 10 2
Elan 6 6
George 8 4
Newman 9 3
Kramer 7 5
Frown Talk
Jerry 10 2
Elan 6 6
George 8 4
Newman 9 3
Kramer 7 5
Negative Correlation
Negative Correlation
0
2
4
6
8
10
12
2 3 4 5 6
Talk
Fro
wn
r = - 1.00
Negative Correlation
0
2
4
6
8
10
12
1 2 3 4 5
Talk
Fro
wn
.
.
. .. r = - .85
Gas in car Talk
Jerry 10 8
Elan 6 9
George 8 3
Newman 9 4
Kramer 7 3
Gas in car Talk
Jerry 10 8
Elan 6 9
George 8 3
Newman 9 4
Kramer 7 3
Zero Correlation
Zero Correlation
0
2
4
6
8
10
12
3 4 5 6 7 8 9
Talk
Gas
in c
ar
.
... .r = .00
Correlation Coefficient
• The sign of a correlation (+ or -) only tells you the direction of the relationship
• The value of the correlation only tells you about the size of the relationship (i.e., how close the scores are to the regression line)
Excel Example
• Which is a bigger effect?
r = .40 or r = -.40
How are they different?
Interpreting an r value
• What is a “big r”
• Rule of thumb:
Small r = .10
Medium r = .30
Large r = .50
Practice
• Do you think the following variables are positively, negatively or uncorrelated to each other?
• Alcohol consumption & Driving skills• Miles of running a day & speed in a foot race• Height & GPA• Forearm length & foot length• Test #1 score and Test#2 score
Statistics Needed
• Need to find the best place to draw the regression line on a scatter plot
• Need to quantify the cluster of scores around this regression line (i.e., the correlation coefficient)
Covariance• Correlations are based on the statistic called
covariance
• Reflects the degree to which two variables vary together– Expressed in deviations measured in the original
units in which X and Y are measured
1
))((
N
YYXXCOVXY
• Note how it is similar to a variance– If Ys were changed to Xs it would be s2
• How it works (positive vs. negative vs. zero)
1
))((
N
YYXXCOVXY
Computational formula
1
NN
YXXY
COVXY
Smile Talk
Jerry 9 5
Elan 2 1
George 5 3
Newman 4 4
Kramer 3 2
1
NN
YXXY
COVXY
Ingredients:
∑XY
∑X
∑Y
N
Smile (Y)
Talk (X)
XY
Jerry 9 5
Elan 2 1
George 5 3
Newman 4 4
Kramer 3 2
Smile (Y)
Talk (X)
XY
Jerry 9 5 45
Elan 2 1 2
George 5 3 15
Newman 4 4 16
Kramer 3 2 6
Smile (Y)
Talk (X)
XY
Jerry 9 5 45
Elan 2 1 2
George 5 3 15
Newman 4 4 16
Kramer 3 2 6
∑ = 23
∑ = 15
∑ = 84
N = 5
∑XY = 84
∑Y = 23
∑X = 15
N = 5
1
NN
YXXY
COVXY
∑XY = 84
∑Y = 23
∑X = 15
N = 5
1
84
NN
YX
COVXY
∑XY = 84
∑Y = 23
∑X = 15
N = 5
1
)23(1584
NNCOVXY
∑XY = 84
∑Y = 23
∑X = 15
N = 5
155
)23(1584
XYCOV
∑XY = 84
∑Y = 23
∑X = 15
N = 5
155
)23(1584
75.3
Problem!
• The size of the covariance depends on the standard deviation of the variables
• COVXY = 3.75 might occur because– There is a strong correlation between X and
Y, but small standard deviations
– There is a weak correlation between X and Y, but large standard deviations
Solution
• Need to “standardize” the covariance
• Remember how we standardized single scores
Correlation
YX
XY
SS
COVr
Smile (Y)
Talk (X)
XY
Jerry 9 5
Elan 2 1
George 5 3
Newman 4 4
Kramer 3 2
SY =2.70 SX =1.58
Correlation
YX
XY
SS
COVr
Correlation
)70.2(58.1
75.388.
Practice
• You are interested in if candy intake is related to childhood depression. You collect data from 5 children.
Practice
Candy Depression
Charlie 5 55
Augustus 7 43
Veruca 4 59
Mike 3 108
Violet 4 65
Scandy = 1.52 Sdepression = 24.82
Practice
Candy
(X)
Depression
(Y)
XY
Charlie 5 55 275
Augustus 7 43 301
Veruca 4 59 236
Mike 3 108 324
Violet 4 65 260
∑
Practice
Candy
(X)
Depression
(Y)
XY
Charlie 5 55 275
Augustus 7 43 301
Veruca 4 59 236
Mike 3 108 324
Violet 4 65 260
∑ 23 330 1396
∑XY = 1396
∑Y = 330
∑X = 23
N = 5
1
NN
YXXY
COVXY
∑XY = 1396
∑Y = 330
∑X = 23
N = 5
155
)330(231396
5.30
Correlation
YX
XY
SS
COVr
COV = -30.5
Sx = 1.52
Sy = 24.82
Correlation
)82.24(52.1
5.3081.
COV = -30.5
Sx = 1.52
Sy = 24.82
Hypothesis testing of r
• Is there a significant relationship between X and Y (or are they independent)– Like the X2
Steps for testing r value
• 1) State the hypothesis
• 2) Find t-critical
• 3) Calculate r value
• 4) Calculate t-observed
• 5) Decision
• 6) Put answer into words
Practice
• Determine if candy consumption is significantly related to depression.– Test at alpha = .05
Practice
Candy Depression
Charlie 5 55
Augustus 7 43
Veruca 4 59
Mike 3 108
Violet 4 65
Scandy = 1.52 Sdepression = 24.82
Step 1
• H1: r is not equal to 0
– The two variables are related to each other
• H0: r is equal to zero
– The two variables are not related to each other
Step 2
• Calculate df = N - 2
• Page 747– First Column are df– Look at an alpha of .05 with two-tails
t distributiondf = 3
0
t distribution
tcrit = 3.182tcrit = -3.182
0
t distribution
tcrit = 3.182tcrit = -3.182
0
Step 3
)82.24(52.1
5.3081.
COV = -30.5
Sx = 1.52
Sy = 24.82
Step 4
• Calculate t-observed
21
2
r
Nrt
Step 4
• Calculate t-observed
2)81.(1
2581.
t
Step 4
• Calculate t-observed
2)81.(1
2581.39.2
Step 5
• If tobs falls in the critical region:
– Reject H0, and accept H1
• If tobs does not fall in the critical region:
– Fail to reject H0
t distribution
tcrit = 3.182tcrit = -3.182
0
t distribution
tcrit = 3.182tcrit = -3.182
0
-2.39
Step 5
• If tobs falls in the critical region:
– Reject H0, and accept H1
• If tIf tobsobs does not fall in the critical region: does not fall in the critical region:
– Fail to reject HFail to reject H00
Step 6
• Determine if candy consumption is significantly related to depression.– Test at alpha = .05
• Candy consumption is not significantly related to depression– Note: this finding is due to the small sample
size
Practice
• Is there a significant (.05) relationship between aggression and happiness?
Aggression Happiness
Mr. Blond 10 9
Mr. Blue 20 4
Mr. Brown 12 5
Mr. Pink 16 6
Mean aggression = 14.50; S2aggression = 19.63
Mean happiness = 6.00; S2happiness = 4.67
Answer
• Cov = -7.33• r = -.76
• t crit = 4.303
• Thus, fail to reject Ho
• Aggression was not significantly related to happiness
)76.(1
2476.65.1
2