Close
SciStat
 

Two-way ANOVA

Description

The two-way analysis of variance is an extension to the one-way analysis of variance. There are two qualitative factors (A and B) on one dependent variable Y.

Three null hypotheses are tested in this procedure:

  • factor A does not influence variable Y
  • factor B does not influence variable Y
  • the effect of factor A on variable Y does not depend on factor B (i.e. there is no interaction of factors A and B).

If the calculated P-values for the two main effects A and B, or for the 2-factor interaction is less than the conventional 0.05 (5%), then the corresponding null hypothesis is rejected, and the alternative hypothesis that there is indeed an influence, must be accepted.

Two-way analysis of variance requires that there are data for each combination of the two qualitative factors A and B.

Required input

  • Dependent data: select a continuous variable.

  • Factor A and B: select categorical or qualitative variables. These variables may either contain character or numeric codes. These codes are used to break-up the data into a two-way classification table.
  • Filter: an optional filter to include a subset of cases.
  • Options

Results

The two-way analysis of variance is an extension to the one-way analysis of variance. There are two qualitative factors (A and B) on one dependent variable Y.

Levene's test for equality of variances

Prior to the ANOVA test, Levene's test for equality of variances is performed. If the Levene test is positive (P<0.05) then the variances in the groups are different (the groups are not homogeneous), and therefore the assumptions for ANOVA are not met.

Tests of Between-Subjects Effects

If the calculated P-values for the two main factors A and B, or for the 2-factor interaction is less than the conventional 0.05 (5%), then the corresponding null hypothesis is rejected, and you accept the alternative hypothesis that there is indeed a difference between groups.

When the 2-factor interaction is significant the effect of factor A is dependent on the level of factor B, and it is not recommended to interpret the means and differences between means (see below) of the main factors.

Estimated marginal means

In the following tables, the means with standard error and 95% Confidence Interval are given for all levels of the two factors. Also, differences between groups, with Standard Error, and Bonferroni corrected P-value and 95% Confidence Interval of the differences are reported.

Analysis of residuals

See Analysis of residuals.

Literature

  • Altman DG (1991) Practical statistics for medical research. London: Chapman and Hall.
  • Armitage P, Berry G, Matthews JNS (2002) Statistical methods in medical research. 4th ed. Blackwell Science.
  • Neter J, Kutner MH, Nachtsheim CJ, Wasserman W (1996) Applied linear statistical models. 4th ed. McGraw-Hill.

See also

Link

Go to Two-way ANOVA.