You are on page 1of 24

Lecture 10:

Analysis of Variance (ANOVA)


Aftab Ahmed Mirza Baig
MS(Advanced Physiotherapy)| PHD scholar (Health,
Physical Education and Sports Sciences)
Senior Physiotherapist | Sindh Institute of Physical
Medicine and Rehabilitation
Analysis of Variance (ANOVA)
An analysis of variance (ANOVA) is used to compare
the means of three or more independent samples
and to test whether the differences between the
means are statistically significant
• T-Test
– Compare the means of two groups
• Independent samples
• Paired samples
• ANOVA
– No restriction on the number of groups
T-test
Disadvantages of Multiple T-Tests
• Time consuming
• Increase chance of committing type-I error
One-Way ANOVA (F-test)
ANOVA
• One-way ANOVA (single factor)
1. One Dependent Variable e.g. Blood Pressure
2. One Independent Variable e.g. BMI (Underweight,
Normal, Overweight)
• Two-way ANOVA (two factors)
– One Dependent Variable e.g. Intelligence (measured
using IQ score),
– Two Independent Variables: e.g.
• Physical Activity Level (low, moderate high),
• BMI (Underweight, Normal, Overweight)
One Way ANOVA
The one-way analysis of variance (one-way
ANOVA) is an extension of a two independent
samples t-test.
– It is used when there are three or more
independent groups.
Examples
One way ANOVA
– The effect of one independent variable with three or
more levels on a dependent variable
What are the independent & dependent variables
in each of the following studies?
– The effect of three drugs on reaction time
– The effect of five styles of teaching on exam results
– The effect of age (old, middle, young) on recall
ANOVA Assumptions
Assumption #1:
– Your dependent variable should be measured on a continuous scale e.g.,
level of job satisfaction, or test anxiety.
Assumption #2:
– Your independent variable should consist of three or more
categorical/independent groups e.g., instructional methods, grade level,
or marital status..
Assumption #3:
– You should have independence of observations, which means that there
is no relationship between the observations in each group or between
the groups themselves.
Assumption #4:
– There should be no significant outliers (Detect outlier through box plots).
Assumption #5:
– Your dependent variable should be approximately normally distributed
for each group of the independent variable (Check Through Normality
Test in SPSS).
Assumption #6:
– There needs to be homogeneity of variances. You can test this
assumption in SPSS using Levene’s test for homogeneity of variances.
Steps of One Way ANOVA
1. Checking for Normality Assumption and Box
plot for each group
2. Descriptive Statistics
3. Mean Plot
4. Checking for Variance Assumption
5. Hypothesis Testing for Means
6. Post Hoc Test
Example (One Way ANOVA)
Students were given different drug treatments
before revising their exams. Some were given a
memory drug. Some a placebo drug and some
no treatment. The exam scores (%) are given
below for the three groups:

Carry out one-way ANOVA test to test the


hypothesis that the treatments with have different
effects at 5% level of significance.
Assumptions (Normality Test and Box Plot)
Step 1 - Assumptions (Normality Test and Box Plot)

Assumption of Normality:
• Ho : Data follows normal distribution
• Ha : Data does not follow normal distribution
From SPSS (Shapiro-Wilks test)
• Memory drug : P-value = 0.978
• Placebo: P-value = 0.929
• No Treatment: P-value = 0.978
Conclusion: Since p-value is greater than α therefore we fails to reject Ho
and conclude that data follows normal distribution. Therefore we can
proceed to apply a Parametric Test i.e. One Way ANOVA
Outlier
– Box plots show that there is no outlier exist in the data sets
To Do One Way ANOVA
OUT PUT of One Way ANOVA
Step 2 - Descriptive Statistics
Groups N Mean Std. Deviation
Memory Drug 5 83.40 10.597
Placebo 5 50.00 10.440
No Treatment 5 16.60 10.597
Step 3 - Mean Plot
The mean plot shows that there is a negative
linear trend exist between the three groups (i.e.
as the students of no treatment there scores are
decreases.)
Step 4 - Checking for Variance Assumption (Homogeneity
of Variance)
Statement of Hypothesis:
– Ho: Population variances are equal
– H1: Population variances are not equal
Leven’s Test
– From SPSS: p value is 1.000.
Since p value is greater than the α level we fail to reject Ho
and conclude that the population variances are equal for all
groups and the homogeneity of variance assumption is
satisfied.
Steps for Hypothesis Testing in ANOVA
1. Set up the null and alternate (research) hypothesis
– Ho: All population means are equal
– H1: At least one mean is significantly different from the others
2. Level of Significance: α = 0.05
3. Run the appropriate statistical test
– One-way ANOVA (Between Subjects)
4. Critical Region: Reject Ho if P-value ≤ α = 0.05
5. Computation: Obtain the test statistic (F-test) & p-value
6. Conclusion: Decide whether to reject or fail to reject Ho
on the basis of the p value If the p value is very small
(<0.05), reject Ho and conclude that at least one sample
mean is significantly different to the other means
Step 5 - Hypothesis Testing Procedure for Means
1. Statement of Hypothesis:
– H1: At least one mean is different from the other
2. Level of Significance: α = 0.05
3. Choose Test: ONE WAY ANOVA / (F Test)
4. Critical Region: Reject Ho if P-value ≤ α = 0.05
5. Computation: P-value = 0.000 which is write as P-value
<0.001
6. Conclusion: Since P-value is less than α therefore we
reject Ho and there is a sufficient evidence to
conclude that mean scores are significantly different
from the other.
Now which pair of group mean scores are different? We
will apply Post Hoc / Multiple Comparison Test.
One Way ANOVA- post-hoc test
• It is important to realize that the one-way ANOVA
cannot tell you which specific groups were
significantly different from each other; it only
tells you that at least two groups were different.
• Since you may have three, four, five or more
groups in your study design, determining which
of these groups differ from each other is
important. You can do this using a post-hoc test
Commonly Use Post Hoc Tests
• Equal Variances Assumed Test
• For Equal Sample Size:
– Tukey (Priority)
– LSD
• For Equal & Unequal Sample Size:
– LSD
• For Comparison with a Control:
– Dunnett’s Test
• Equal Variances Not Assumed Test
– Games-Howell (Equal/Unequal Sample Size)
Be like the mango tree. Always provide
fruit in spite of evil’s eye

You might also like