Professional Documents
Culture Documents
Principles of The T-Test and ANOVA
Principles of The T-Test and ANOVA
zero
zero
zero
• The next slide shows the individual data that brought about a mean of
2.6 friends
Lecturer 1 had just 1 friend
His DEVIANCE from the mean is 1 – 2.6 (observed – expected)
The model / mean OVER-ESTIMATED how many friend he has
How well does the mean fit
• We could add up all of these deviances to get a sum of deviances,
which would be a measure of the TOTAL ERROR
= -1.6 + -0.6 + 0.4 + 0.4 + 1.4
=0
• One way to do this is to square each deviance (or error) and then add
them all up
• The Sum of Squared errors (SS)
How well does the mean fit?
However, surely the SS will be bigger just by having more observations, even of the “fit”
(how close each observation is to the mean) is very good?
87 70 55
70 65 65
75 60 70
78 70 55
82 65 55
90
CON
CHO
CAF
GRAND MEAN
Total sum of squares
• SST = S(x – grand mean)2
• But this is a pain to calculate
87 70 55
70 65 65
75 60 70
78 70 55
82 65 55
GRAND MEAN
Model Sum of Squares
1. Calculate difference between
mean of each group and grand
mean
2. Square these error terms 5d2 d2
(squared error) d2 5d2
5d2 d2
3. Multiply each result by
number in respective group
4. Add them up (sum of
squares!)
90 SSCON = {(78.4 – 68.13∙)2}*5 = 527
Mean CON = 78.4
Mean CHO = 66
SSCHO = {(60 – 68.13∙)2}*5 = 330.8
Mean CAF = 60
87 70 55
70 65 65
78 70 55
82 65 55
Mean Squares
• We need to eliminate the influence of the different number of
observations that make up each SS term
Epsilon (Ɛ) is an estimate of sphericity: 1 – 1/(no. conditions - 1) With a “failed” test of sphericity, the GG correction is
the safest/most conservative (but: type 2 error)
Problem. Sphericity is: (too) easy to detect with large sample size, (too) hard to detect with a small sample size
Field (2018) recommends ALWAYS using the corrected version of your ANOVA in accordance with the rules of thumb
Factorial & Factorial Repeated
Measures ANOVA
Oh no
Factorial (repeated) ANOVA
• Very commonly we measure parameters across two different factors
• We might measure plasma [FFA] over time with and without the consumption
of a high fat diet
“Two-Way ANOVA with repeated measures
on both factors (time*diet)”
Interaction? ✗
Main effect of time? ✗
Interaction? ✓✗
Main effect of time? ✓
Interaction? ✗
Main effect of time? ✓
Interaction? ✓✓✓
Main effect of time? ✓
Interaction? ✓
Factorial ANOVA
• We may also have a completely independent design, but with two
factors
• We might measure anxiety in male and female students (sex) in Further
Education and Higher Education (Education)
• Two-Way ANOVA (Sex*Education), with 2 levels for each factor
Male
Female
FE HE
Education
Mixed ANOVA
Male
Female
ANCOVA: analysis of covariance
Male
Female
• ANOVA compares (ratio of) the average model sum-of-squares with the average error sum-
of-squares
• Producing an F-ratio that is compared with the F-distribution
• Repeated measures designs need to examine the assumption of sphericity carefully
• When multiple factors are considered, there are both “main effects” and “interactions”
• Consider your experimental design carefully
Tasks
• Familiarise yourself with SPSS and follow step-by-step guides to
setting up an ANOVA
• ANOVA1
• https://my.hope.ac.uk/spss/SPSS.php