Skip to main content
v2026.11,610 entries · CC-BY 4.0

Two-Way ANOVA in SPSS: Main Effects, Interaction, and Simple Effects

Set up a two-way ANOVA via GLM Univariate, read the interaction row before the main effects, plot it, and run simple-effects follow-up tests when it’s significant.

Ask about Two-Way ANOVA in SPSS: Main Effects, Interaction, and Simple Effects

Answers are drawn from this guide and the rest of the CASRAI corpus, with a link to every source.

Answers are AI-generated from CASRAI’s own published pages and can be wrong, so check the linked sources before relying on one; your question is logged without personal data — never sold, never used to train a third-party model — to show us what CASRAI is missing, so please do not type personal or confidential details. How we use this

Written and maintained by CASRAI Editorial Board

Last updated

SPSS runs a two-way ANOVA through Analyze > General Linear Model > Univariate — not through the Compare Means menu, which only handles a single factor. The output table it produces answers three separate questions at once (does factor A matter, does factor B matter, does the effect of one depend on the other), and reading them in the wrong order is the most common mistake: the interaction row has to be read first, because a significant interaction changes what the two main-effect rows are allowed to mean.

Setting up the two-way ANOVA in SPSS

Go to Analyze > General Linear Model > Univariate. Move your continuous outcome into Dependent Variable and both categorical predictors into Fixed Factor(s) — order doesn’t matter here, SPSS treats them symmetrically. Leave the Model tab on its default, Full factorial: this automatically includes both main effects and the two-way interaction term, which is what you want for a standard two-way ANOVA. (Switching to Custom is only needed if you deliberately want to drop the interaction term, which is rarely correct — dropping it assumes no interaction exists rather than testing whether one does.)

Before clicking OK, set up two more tabs while you’re in the dialog:

  • Plots — move one factor to Horizontal Axis and the other to Separate Lines, then click Add. This produces the interaction plot described below.
  • Options — move all three terms (both main effects and the interaction) into Display Means for, then check Descriptive statistics, Estimates of effect size, and Homogeneity tests.

Click OK. SPSS returns several tables; the one that matters first is Tests of Between-Subjects Effects.

Reading the interaction term first

The Tests of Between-Subjects Effects table lists a row for each main effect (Factor A, Factor B) and one for the interaction (Factor A * Factor B), each with its own df, F, and Sig. value. Read the interaction row before either main-effect row:

  • If the interaction is significant (Sig. ≤ .05) — the effect of Factor A on the outcome is not the same at every level of Factor B (and vice versa). The two main-effect rows still print, but interpreting them on their own is misleading: a “significant main effect of A” can be an average across levels of B where A’s effect is large at one level and reversed or absent at another. The correct next step is simple-effects testing (below), not reporting the main effects as if they applied uniformly.
  • If the interaction is not significant — the two factors act independently on the outcome, and the main-effect rows can be interpreted directly: each one describes the effect of that factor averaged across the levels of the other, and that average is a fair summary because the effect doesn’t meaningfully change across those levels.

This read-the-interaction-first order is why the interaction row belongs at the top of your results section too, even though SPSS prints it last in the table.

Plotting the interaction

The profile plot from the Plots tab (visible in the output as a line chart with the horizontal-axis factor’s levels on the x-axis and one line per level of the other factor) is the fastest way to see what the interaction row is telling you numerically:

  • Parallel lines — the effect of the horizontal-axis factor is the same size and direction at every level of the other factor. This is the visual signature of a non-significant interaction.
  • Non-parallel but non-crossing lines — the effect is present at both levels but a different size (an “ordinal” interaction). Simple effects at each level will likely both be significant, just to different degrees.
  • Crossing lines — the effect reverses direction between levels (a “disordinal” interaction). This is the pattern most likely to produce a significant interaction with a non-significant, misleading average main effect, since the two opposite effects partly cancel out when averaged.

Use the plot to form an expectation, then confirm it against the actual interaction row’s Sig. value — a plot can look like it shows an interaction from sampling noise alone, especially with small cells, so the visual should support the test, not replace it.

Effect size and the homogeneity check

With Estimates of effect size checked, the Tests of Between-Subjects Effects table adds a Partial Eta Squared column for every row, including the interaction. Partial eta squared is the proportion of variance in the outcome that term accounts for, with the variance from the other terms in the model removed — conventionally read as roughly .01 (small), .06 (medium), and .14 (large), though these thresholds are a rough guide, not a fixed rule.

With Homogeneity tests checked, SPSS also produces Levene’s Test of Equality of Error Variances in a separate table. This tests whether the outcome’s variance is equal across all cells of the design (every combination of the two factors), which is an assumption of the F-tests above. A significant Levene’s test (Sig. ≤ .05) means that assumption is in question; with balanced or near-balanced cell sizes the F-test is fairly robust to violations, but with unequal cell sizes it’s worth reporting the violation and treating borderline results more cautiously.

Running simple effects when the interaction is significant

SPSS’s Univariate GLM dialog does not have a menu button for simple main effects — the Compare main effects checkbox on the Options tab only works when a single main-effect term is selected in Display Means for, not the interaction term, so it can’t produce a “effect of A within each level of B” breakdown by itself. Two practical routes get you there:

Split File (fastest, uses a separate error term per subgroup). Go to Data > Split File, choose Organize output by groups, and move the factor you want to hold constant into Groups Based on. Run Analyze > Compare Means > One-Way ANOVA (or GLM Univariate again) on the other factor; SPSS reruns the test separately within each level of the grouping factor. This is simple to do and widely used, but it estimates a fresh error variance from each subgroup instead of the pooled error term from the full two-way model, which is slightly less powerful and technically not the textbook version of a simple effects test. Remember to turn Split File back off (Analyze all cases, do not create groups) once you’re done, or every later analysis in the session will silently stay split.

Syntax with the model’s pooled error term (closer to the textbook version). Instead of clicking OK in the Univariate dialog, click Paste to open the syntax it generates, then add an EMMEANS subcommand with a COMPARE keyword for the factor you want to test within levels of the other:

UNIANOVA outcome BY factorA factorB /EMMEANS=TABLES(factorA*factorB) COMPARE(factorA) ADJ(BONFERRONI) /EMMEANS=TABLES(factorA*factorB) COMPARE(factorB) ADJ(BONFERRONI) /PRINT=ETASQ HOMOGENEITY /PLOT=PROFILE(factorA*factorB) /DESIGN=factorA factorB factorA*factorB.

Highlight the block and run it (Run > Selection). The first EMMEANS line compares the levels of factorA within each level of factorB (pairwise, Bonferroni-adjusted); the second does the reverse. Because these comparisons come from the same model as the omnibus test, they use its pooled error term rather than a fresh one per subgroup — the reason this route is preferred when you need the more defensible version of a simple effects follow-up rather than the quicker approximation.

Reporting the results in APA style

Report the interaction first, then whichever follow-up applies:

Interaction significant: “A two-way ANOVA revealed a significant interaction between Factor A and Factor B on [outcome], F(dfA×B, dfError) = X.XX, p = .0XX, partial η² = .XX. Simple effects analysis showed [describe the pattern at each level].”

Interaction not significant: “There was no significant interaction between Factor A and Factor B, F(dfA×B, dfError) = X.XX, p = .XXX, partial η² = .XX. There was a significant main effect of Factor A, F(dfA, dfError) = X.XX, p = .0XX, partial η² = .XX, but no significant main effect of Factor B, F(dfB, dfError) = X.XX, p = .XXX.”

Pull the degrees of freedom straight from the Tests of Between-Subjects Effects table — the first df in each F comes from that term’s own row, the second (error) df is shared from the Error row.

Before you trust the result: check the assumptions

A two-way ANOVA carries the same assumptions as one-way ANOVA, applied across the full factorial design: the outcome should be roughly normally distributed within each of the cells (check via Analyze > Descriptive Statistics > Explore, split by both factors, or by examining the residuals), variances should be roughly equal across cells (Levene’s test above), observations must be independent of each other (a design issue, not something SPSS can test), and cell sizes should not be badly unequal — a design with very small or empty cells makes both the omnibus test and any simple-effects follow-up unstable, since some comparisons will be based on very little data.

Frequently asked questions

Do I report the main effects if the interaction is significant?

You can still report them for completeness, but flag that they’re qualified by the interaction and shouldn’t be read as applying uniformly — lead with the interaction and the simple-effects breakdown, since that’s what actually describes what happened in the data.

What’s the difference between GLM Univariate and the old Factorial ANOVA options?

There isn’t a separate “Factorial ANOVA” procedure in current SPSS — General Linear Model > Univariate is the one procedure for any between-subjects design with one or more fixed factors, whether that’s one factor (equivalent to one-way ANOVA) or several with their interactions. One-Way ANOVA under Compare Means is a separate, simpler procedure limited to exactly one factor.

Can I get real simple-effects F-tests instead of pairwise comparisons?

The EMMEANS/COMPARE syntax above gives pairwise mean comparisons within levels, which is what most reporting needs when a factor has only two levels (a pairwise comparison and a simple-effect F-test are the same thing in that case). For a factor with three or more levels, an EMMEANS/COMPARE result is a set of pairwise comparisons rather than a single omnibus simple-effects F; getting the omnibus version with the pooled error term requires writing a custom contrast in syntax, which is a step beyond what most two-way designs need.

Why does my interaction plot look like it shows an effect, but the interaction row isn’t significant?

Small cell sizes produce visibly non-parallel lines from sampling variability alone. Treat the plot as illustrating the pattern the test already found (or didn’t find), not as independent evidence — if the Sig. value for the interaction is above .05, don’t report an interaction because the lines aren’t perfectly parallel.

Related CASRAI resources

For the underlying logic of comparing group means — hypotheses, assumptions, and when ANOVA is the right tool at all — see CASRAI’s analysis of variance guide and the ANOVA dictionary entry. For the single-factor version of this same SPSS procedure, see running a t-test in SPSS and the related repeated-measures assumption check in Mauchly’s test of sphericity in SPSS. For controlling Type I error across the pairwise comparisons a significant interaction leads to, see Bonferroni correction and multiple comparisons. For effect-size reporting beyond partial eta squared, see effect size and Cohen’s d. If your design doesn’t meet ANOVA’s assumptions, compare it against the nonparametric alternative in the Kruskal-Wallis test. For SPSS itself, see what SPSS is and who uses it, or compare it against alternatives in SPSS vs. R and SPSS vs. Stata.

Follow CASRAI

Research-administration guidance, standards updates and independent tool reviews.

Referenced across the research world

University of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logoUniversity of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logo
  • University of Cambridge logo
  • Columbia University logo
  • Crossref logo
  • University of Edinburgh logo
  • Harvard University logo
  • University of Oxford logo
  • Princeton University logo
  • Stanford School of Medicine logo
  • University College London logo
  • ORCID logo

View CASRAI adoption →

Regulatory Radar

Stop finding out after the fact

$29/month, cancel anytime. Daily digest updates from our analysis, a dashboard holding the same items, and a cited assistant for everything they raise.

  • Federal Register, Federal Register+, Grants.gov, Regulations.gov, NSF News, UKRI, plus CASRAI’s own published content.
  • 44,322 indexed passages, and every answer cites the ones it drew on.