Skip to content

    Under active development. New calculators and features ship every week. Everything currently runs free while the site matures — pricing pages are a preview, checkout is not open yet.

    Calculates locally in your browser · two-way ANOVA
    Design of experiments / interaction

    Two-way ANOVA calculator

    One-way ANOVA tells you whether any group differs. A two-way design tells you which factor matters — and whether the two interact, meaning the effect of one depends on the level of the other. That interaction term is usually the reason you run the second factor at all.

    Design2 × 2Replicates2InteractionAbsent
    Factor A
    F 4.00
    p = 0.116
    Factor B
    F 16.00
    p = 0.016
    Interaction
    F 0.00
    p = 1.000
    Residual error
    2.00
    4 degrees of freedom
    Two-way ANOVA table
    Main effects and the interaction, each tested against the residual.
    F_AB 0.00
    Two-way ANOVA table
    SourceSSdfFp
    Factor A8.0014.000.116
    Factor B32.00116.000.016
    A × B0.0010.001.000
    Error8.004——

    A significant interaction means the effect of A depends on the level of B, so main effects alone mislead.

    Inspect the model
    Choose a quick result view, a scaled comparison, or the complete diagnostic set.
    Cell means
    Parallel lines between the levels would mean no interaction.
    Cell means0.0004.018.0212.0416.0520.0611.00A0 B0A0 B015.00A0 B1A0 B113.00A1 B0A1 B017.00A1 B1A1 B1Mean
    F ratios
    Anything above the critical value is significant.
    F ratios0.0003.787.5511.3315.1018.884.00AA16.00BB0.000A×BA×BF
    Canonical equations
    The exact relationships implemented by this engine.

    y = μ + α + β + αβ + ε · Two factors with interaction.

    MS_source / MS_error · One test per source.

    cell − α − β + μ · The part not explained by the main effects.

    engineering methodology

    A clear path from inputs to results.

    One-way ANOVA tells you whether any group differs. A two-way design tells you which factor matters — and whether the two interact, meaning the effect of one depends on the level of the other. That interaction term is usually the reason you run the second factor at all.

    Step-by-step methodWorked exampleAssumptions explained

    How to use

    1. Enter two observations in each of the four cells.
    2. Read the F ratios for A, B and the interaction.
    3. Check which p-values are below 0.05.
    4. Look at the cell means to interpret an interaction.

    The formula

    yijk=μ+αi+βj+(αβ)ij+εijky_{ijk} = \mu + \alpha_i + \beta_j + (\alpha\beta)_{ij} + \varepsilon_{ijk}

    Reference: Two-way analysis of variance with interaction, balanced design.

    Worked example

    2 × 2 design, two replicates per cell

    Inputs
    • A low, B low: 10, 12.
    • A low, B high: 14, 16.
    • A high, B low: 12, 14.
    • A high, B high: 16, 18.
    Calculation path
    1. 1

      Grand mean 14; cell means 11, 15, 13, 17.

    2. 2

      SS_A = 8, SS_B = 32, SS_AB = 0, SS_E = 8.

    3. 3

      F_A = 4.0 (p = 0.116); F_B = 16.0 (p = 0.016).

    4. 4

      F_AB = 0, so no interaction: the effects are additive.

    5. 5

      Factor B matters; factor A does not, at this sample size.

    Result

    F_B 16.0 (p 0.016) · no interaction.

    Interpreting the result

    With only two replicates the design has four error degrees of freedom, so it can only detect large effects. That is the trade: a 2×2 with replicates is cheap, but the interaction test is weak. If the interaction is the question, replicate more.

    Assumptions & limitations

    • Balanced design with equal replicates.
    • Independent, normally distributed errors with equal variance.
    • Two levels per factor.
    • No blocking or covariates.

    Frequently asked questions

    What does a significant interaction mean?

    The effect of A depends on the level of B, so a single main effect is misleading.

    Can I add more levels?

    Yes, but the arithmetic is the same; this form is fixed at two levels each.

    Why is F_AB zero here?

    The cell means are perfectly additive, so there is no interaction to detect.

    Methodology last reviewed 2026-10-21. Results are informational and not financial or engineering advice — see our disclaimer.