2. What is Two-Way ANOVA?
Assumptions of Two-Way ANOVA
One Example
Objectives
Hypothesis
Data Analysis
Conclusion
3. Two- Way ANOVA is an extension of One-Way ANOVA.
Here we have two independent variables and one dependent variable
Here two independent variables are studied. That’s why it is called Two –
Way ANOVA.
The independent variables can have number of categories called levels or
factors.
Examples of dependent variable in ANOVA are Sales, Performance,
Emotional Intelligence, Health, opinion on any attribute etc.
Examples of Independent variable are Gender, cities, academic qualification,
colors, position etc.
4. Scale: The independent variables should be in categorical
scale(nominal or ordinal) and the dependent variable has to be in
continuous scale(interval or ratio).
Independence: The data should be independent of each other i.e. the
data of one group doesn’t influence the other group
Normality: The data should be normally distributed
Homogeneity of variance: variance of all groups should be equal
Group sizes should be same: each group should have same number
of respondents
The residuals are also normally distributed
5. A company wants to find out whether the Sales of their
product is influenced by their place of respondents and
the education of the respondents. The company selects a
sample of 27 respondents.
Place: Mumbai, Delhi, Pune
Education: Undergraduate, Graduate, Post Graduate
6. To study whether place influence sales
To study whether education influences sales
To study whether education influences sales in different cities
7. H01: Sales of product do not differ in different places.
H11: Sales of product differ in different places.
H02: Sales of product do not differ based on the education of respondents
H12: Sales of product differ based on the education of respondents
H03: Sales of product do not differ with education level of respondents belonging
to different places.
H13:Sales of product differ with education level of respondents belonging to
different places.
8. Hypothesis 1: Main Effect
Hypothesis 2: Main Effect
Hypothesis 3: Interaction Effect
9.
10. Tests of Normality
Place Kolmogorov-Smirnova Shapiro-Wilk
Statistic df Sig. Statistic df Sig.
Sales
Mumbai .205 9 .200* .955 9 .741
Delhi .188 9 .200* .916 9 .357
Pune .209 9 .200* .820 9 .034
*. This is a lower bound of the true significance.
a. Lilliefors Significance Correction
Tests of Normality
Education Kolmogorov-Smirnova Shapiro-Wilk
Statistic df Sig. Statistic df Sig.
Sales
Undergraduate .250 8 .150 .918 8 .416
Graduate .137 12 .200* .955 12 .716
Post graduate .175 7 .200* .915 7 .429
*. This is a lower bound of the true significance.
a. Lilliefors Significance Correction
11. Tests of Normality
Place Kolmogorov-Smirnova
Shapiro-Wilk
Statistic df Sig. Statistic df Sig.
Residual for Sales
Mumbai .198 9 .200*
.912 9 .332
Delhi .186 9 .200*
.899 9 .244
Pune .211 9 .200*
.895 9 .222
*. This is a lower bound of the true significance.
a. Lilliefors Significance Correction
Tests of Normality
Education Kolmogorov-Smirnova Shapiro-Wilk
Statistic df Sig. Statistic df Sig.
Residual for Sales
Undergraduate .147 8 .200* .931 8 .521
Graduate .248 12 .039 .855 12 .042
Post graduate .137 7 .200* .985 7 .981
*. This is a lower bound of the true significance.
a. Lilliefors Significance Correction
12. The Shapiro-Wilk significant value is >0.05. which proves
that the data is normal.
The Shapiro-Wilk significant value is >0.05 for residuals
also. Hence the residuals are also normally distributed.
13. The Levene’s Test shows that the significant value is 0.084
which implies that homogeneity of variance is not
significant(p>0.05).
That means that the error variance across all groups are equal.
Hence the assumption of homogeneity of variance is
satisfying.
Levene's Test of Equality of Error Variancesa
Dependent Variable: Sales
F df1 df2 Sig.
2.152 8 18 .084
Tests the null hypothesis that the error variance of the dependent variable is equal across groups.
a. Design: Intercept + Place + Education + Place * Education
14. Since the p>0.05 for place, so the null hypothesis (H01) is accepted,
and p<0.05 for education, the null hypothesis(H02)is rejected and
since the p>0.05 for the interaction effect, the null hypothesis (H03)
is accepted.
Tests of Between-Subjects Effects
Dependent Variable: Sales
Source Type III Sum of
Squares
df Mean Square F Sig. Partial Eta
Squared
Corrected Model 4638.957a
8 579.870 4.000 .007 .640
Intercept 30867.022 1 30867.022 212.948 .000 .922
Place 639.603 2 319.802 2.206 .139 .197
Education 3584.455 2 1792.228 12.364 .000 .579
Place * Education 92.752 4 23.188 .160 .956 .034
Error 2609.117 18 144.951
Total 38801.000 27
Corrected Total 7248.074 26
a. R Squared = .640 (Adjusted R Squared = .480)
15. Multiple Comparisons
Dependent Variable: Sales
Tukey HSD
(I) Education (J) Education Mean Difference
(I-J)
Std. Error Sig. 95% Confidence Interval
Lower Bound Upper Bound
Undergraduate
Graduate -13.17 5.495 .068 -27.19 .86
Post graduate -32.14*
6.231 .000 -48.05 -16.24
Graduate
Undergraduate 13.17 5.495 .068 -.86 27.19
Post graduate -18.98*
5.726 .010 -33.59 -4.36
Post graduate
Undergraduate 32.14*
6.231 .000 16.24 48.05
Graduate 18.98*
5.726 .010 4.36 33.59
Based on observed means.
The error term is Mean Square(Error) = 144.951.
*. The mean difference is significant at the .05 level.
16. Multiple Comparisons
Dependent Variable: Sales
Tukey HSD
(I) Place (J) Place Mean
Difference (I-J)
Std. Error Sig. 95% Confidence Interval
Lower Bound Upper Bound
Mumbai
Delhi 4.89 5.676 .671 -9.60 19.37
Pune 13.56 5.676 .069 -.93 28.04
Delhi
Mumbai -4.89 5.676 .671 -19.37 9.60
Pune 8.67 5.676 .302 -5.82 23.15
Pune
Mumbai -13.56 5.676 .069 -28.04 .93
Delhi -8.67 5.676 .302 -23.15 5.82
Based on observed means.
The error term is Mean Square(Error) = 144.951.
17. Using the Tukey HSD further, we can conclude that there is no difference
in the responses of respondents with education level of undergraduate
and graduate.
But there is a significant difference in when the education level of
respondents are (postgraduate and graduate) and (post graduate and
undergraduate).
In the post hoc test of place, the data is not significant in any combination
of place. That means the responses are same irrespective of cities.
18. From the above data analysis, it is concluded that, there is
a significant difference in the sales of the product with
different education. No effect on sales with respondents
from different cities. Even the interaction effect is also not
significant.
All assumptions of Two-Way ANOVA are being met in the
case.