Two-Way ANOVA Calculator + Plots (Summary Data)

Calculate Two-Way ANOVA (main effects, interaction), descriptive statistics, Tukey HSD post-hoc tests (with approximate significance indication), and interaction plots using summary data (N, Mean, SD).

1. Define Factors and Levels

Overview

This calculator performs a Two-Way ANOVA analysis using summary statistics. You do not need raw data, only the sample size, mean, and standard deviation for each group combination.

Step-by-Step Instructions

1 Define Your Factors and Levels

Begin by setting up your experimental design:

  • Factor A Name: Enter the name of your first independent variable (e.g., Treatment Type, Gender, Teaching Method)
  • Levels: Specify how many levels Factor A has (minimum 2)
  • Factor B Name: Enter the name of your second independent variable (e.g., Dosage, Age Group, Time Period)
  • Levels: Specify how many levels Factor B has (minimum 2)

Click Set Up Inputs when ready to proceed.

2 Name Your Levels

Customize the names for each level to make results easier to interpret:

  • Replace generic names like "Factor A Lvl 1" with descriptive labels
  • Examples: "Control", "Low Dose", "High Dose" or "Week 1", "Week 2", "Week 3"
  • Clear names help communicate results effectively
3 Enter Summary Statistics

For each combination of Factor A and Factor B, enter three values:

Input Symbol Description Requirements
Sample Size N Number of observations in the group Must be at least 2
Mean x̄ Average value for the group Any number
Standard Deviation s Measure of spread in the group Must be 0 or greater
4 Calculate and Review Results

Click Calculate ANOVA to generate comprehensive results:

  • Descriptive Statistics: Summary table of your input data
  • ANOVA Table: Test results including F-statistics and p-values
  • Interaction Plots: Visual graphs showing how factors interact
  • Tukey HSD Tests: Pairwise comparisons when appropriate
  • Interpretation: Automated explanation of your results

Understanding Your Results

Interaction Effect

The interaction tells you whether the effect of one factor depends on the level of the other factor:

Main Effects

Main effects show the overall impact of each factor averaged across all levels of the other factor:

Interaction Plots

Visual interpretation guide:

P-Values and Significance

The calculator uses alpha = 0.05 as the significance threshold:

Exporting Results

After calculating, you can save your complete results:

Both export options capture all tables, plots, and interpretations in a single file.

Data Requirements

Best Practices

Background: What Is Two-Way ANOVA?

Two-Way ANOVA (Analysis of Variance) tests whether two independent categorical factors — and the interaction between them — have a statistically significant effect on a continuous outcome variable. It extends One-Way ANOVA by letting you study two factors simultaneously, and crucially, whether they interact with each other.

The Core Formulas

Total variability is partitioned into four sources: SS(A), SS(B), SS(A×B), and SS(Within/Error). Each F-statistic is calculated as F = MS(effect) / MS(Within), where MS = SS / df. The degrees of freedom are df(A) = a−1, df(B) = b−1, df(A×B) = (a−1)(b−1), and df(Within) = N − ab, where a and b are the number of levels in each factor.

Ex Worked Example

Suppose you study Exercise Level (None, Light, Intense) and Diet (Regular, Low-carb) on weight loss (kg), with 10 people per cell. If the ANOVA table shows a significant interaction (p < 0.05), it means the effect of exercise on weight loss differs depending on diet type — for example, intense exercise might only outperform light exercise under a low-carb diet, not under a regular one. In that case, the main effects of Exercise and Diet alone should be interpreted with caution, and the interaction plots become the primary way to understand what's actually happening.

How to Do This in R Studio

Unlike this calculator, R's aov() works from raw data rather than summary statistics:

model <- aov(weight_loss ~ exercise * diet, data = mydata)
summary(model)

# Post-hoc test
TukeyHSD(model)

How to Do This in SPSS

Analyze → General Linear Model → Univariate. Set your outcome as the Dependent Variable, and both factors as Fixed Factor(s). Under Post Hoc, move your factors to the right and select Tukey. Under Plots, add an interaction plot with one factor on the horizontal axis and the other as Separate Lines.

How to Do This in JASP

ANOVA → ANOVA. Set your outcome as the Dependent Variable and both factors as Fixed Factors. Under Post Hoc Tests, move both factors in and check Tukey. Under Descriptive Plots, add both factors to generate the interaction plot automatically.

Related Statistical Calculators