# Analysis of variance (ANOVA) ```LEZIONI IN LABORATORIO
Corso di MARKETING
L. Baldi
Universit&agrave; degli Studi di Milano
Analysis of variance
(ANOVA)
Estratto dal Cap. 7 di:
“Statistics for Marketing and Consumer Research”,
M. Mazzocchi, ed. SAGE, 2008.
1
Example: expenditure in alcohol by economic
position
Economic position of H ousehold Reference Person
SelfFulltime Part time
Unempl.
employed employee employee
EFS: Total
Alcoholic
Beverages,
Tobacco
Mean
St. Dev.
m1
m2
m3
m4
18.56
14.64
12.39
19.48
s1
s2
s3
s4
19.0
18.5
15.0
19.7
Ret unoc
over min
ni age
Student
m5
m6
7.34
s5
14.6
TOTAL
m
11.99
12.67
s6
s
19.1
17.8
Are there significant difference across the means of
these groups?
Or do the differences depend on the different levels of
variability across the groups?
2
Tests on multiple hypotheses



Consider the situation where the means for more
than two groups are compared, e.g. mean
alcohol expenditure for: (a) students; (b)
unemployed; (c) employees
One could run a set of two mean comparison
tests (students vs. unemployed, students vs.
employed, employed vs. unemployed)
But.....too many results...
3
Analysis of Variance

It is an alternative approach to mean
comparison for multiple groups

It is applicable to a sample of individuals that
differ for one or more given factors

It allows tests where variability in a variable is
attributable to one (or more) factors
4
Analysis of Variance
Here:
 the target variable is alcohol expenditure

the factor is the economic position of the
consumers
5
One-way ANOVA

Only one categorical variable (a single factor)

Several levels (categories) for that factor

The typical hypothesis tested through ANOVA is
that the factor is irrelevant to explain differences in
the target variable (i.e. the means are equal)

Apart from the tested factor(s), the groups should be
safely considered homogeneous between each
other
6
Null and alternative hypothesis for ANOVA

Null hypothesis (H0): all the means are equal

Alternative hypothesis (H1): at least two
means are different
7
Measuring and decomposing the total variation
VARIATION BETWEEN THE GROUPS
+
VARIATION WITHIN EACH GROUP=
________________________________
TOTAL VARIATION
8
The basic principle of the ANOVA

If the variation explained by the different
factor between the groups is significantly
more relevant than the variation within the
groups, then:
the factor is assumed to be statistically relevant
in explaining the differences
9
The test statistic

The test statistic is computed as:
sB2 Variance between groups
F 2 
sW
Variance within groups
Rejection area
Distribution of the
F-statistic (one-tailed test)
10
Post-hoc tests


They open the way to further explore the
sources of variability when the null
hypothesis of mean equality is rejected.
It is usually relevant to understand which
particular means are different from each
other.
11
Some post-hoc tests






LSD (least significant difference)
Duncan test
Tukey’s test
Scheffe test
Bonferroni post-hoc method
.......
12
Multi-way (factorial) analysis of variance



This analysis measures the influence of two
or more factors
Beside the influence of each individual factor,
it provides testing of interactions between
treatments belonging to different factors
ANOVA with more than two factors is rarely
employed, as interpretation of results
becomes quite complex
13
```