T tests, ANOVAs and regression. Tom Jenkins Ellen Meierotto SPM Methods for Dummies 2007. Why do we need t tests?. Objectives. Types of error Probability distribution Z scores T tests ANOVAs. Error. Null hypothesis Type 1 error ( Î± ): false positive Type 2 error ( Î² ): false negative.
Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.
T tests, ANOVAs and regression
Tom Jenkins
Ellen Meierotto
SPM Methods for Dummies 2007
Z=(xÎ¼)/Ïƒfor one point compared to pop.
Pooled standard error of the mean
Variance
F test = Model variance /Error variance
Group 1
Group 1
Group 1
Group 2
Group 2
Group 2
Partitioning the variance
Total =
Model +
(Between groups)
Error
(Within groups)
Correlation and Regression
Y
X
Y
Y
Y
Y
Y
X
X
Positive correlation
Negative correlation
No correlation
Covariance ~
DX * DY
Variance ~
DX * DX
x
(
)(
)


y


x
x
y
y
x
x
y
y
i
i
i
i
0
3

3
0
0
2
2

1

1
1
3
4
0
1
0
4
0
1

3

3
6
6
3
3
9
Ã¥
=
=
7
y
3
=
x
3
What does this number tell us?
CorrelationNegativePositive
Small0.29 to 0.1000.10 to 0.29
Medium0.49 to 0.300.30 to 0.49
Large1.00 to 0.500.50 to 1.00
Å· = ax + b
slope
Îµ
= y i , true value
Îµ =residual error
minimises distance between
data and fitted line, i.e.
the residuals
intercept
= Å·, predicted value
Model line: Å· = ax + b
a = slope, b = intercept
Residual (Îµ) = y  Å·
Sum of squares of residuals = Î£ (y â€“ Å·)2
Î£ (y â€“ Å·)2
b
b
Îµ
Îµ
b
b
b
b
sums of squares (S)
Gradient = 0
min S
Values of a and b
Î£(y  ax  b)2
r sy
r = correlation coefficient of x and y
sy = standard deviation of y
sx = standard deviation of x
a =
sx
y = ax + b
b = y â€“ ax
b = y â€“ ax
r sy
r = correlation coefficient of x and y
sy = standard deviation of y
sx = standard deviation of x
x
b = y 
sx
How well does this line fit the data, or how good is it at predicting y from x?
âˆ‘(Å· â€“ y)2
âˆ‘(y â€“ y)2
SSy
SSpred
sy2 =
sÅ·2 =
=
=
n  1
n  1
dfÅ·
dfy
âˆ‘(y â€“ Å·)2
SSer
serror2 =
=
n  2
dfer
This is the variance explained by our regression model
This is the variance of the error between our predicted y values and the actual y values, and thus is the variance in y that is NOT explained by the regression model
How good is our model cont.
sy2 = sÅ·2 + ser2
sÅ·2 = r2 sy2
r2 = sÅ·2 / sy2
ser2 = sy2 â€“ r2sy2
= sy2 (1 â€“ r2)
sÅ·2
r2 (n  2)2
F
=
(dfÅ·,dfer)
ser2
1 â€“ r2
complicated
rearranging
=......=
So all we need to
know are r and n !
r(n  2)
t(n2) =
(because F = t2)
âˆš1 â€“ r2
y = ax + b +Îµ
y = a1x1+ a2x2 +â€¦..+ anxn + b + Îµ