Two-way ANOVA + Tukey letters

MinutePlot® and R on the same data. MinutePlot version 1.0.0; R 4.5.2.

Dataset

  • npk — Yield of peas in a 2×2×2 factorial experiment on 6 blocks (R: datasets::npk; Yates 1935); factors N and P used here.
  • Data format for MinutePlot: npk_minuteplot.csv — arranged exactly as the app’s data template for this test expects (paste it into the app).
  • Data format for R: npk_r.csv — the long-format file the R script reads (keep it in the script’s folder).
  • R built-in: the script loads npk with data() (blocks and K pooled on the MinutePlot side).

Setup

In MinutePlot:

  • Workbench → Two-way ANOVA → paste npk_minuteplot.csv (N down the rows, P as column blocks, six replicates per cell; blocks and K pooled).
  • Post-hoc test: Tukey HSD (the default) · significance level α = 0.05 (the default) → Confirm and Analyze.
  • Read the ANOVA table and the cell means with letters from the results; the page compares the all-cells letter set.

In R:

  • Install once: install.packages(c("emmeans", "multcomp", "multcompView")); then run npk.R top to bottom (source it, or paste it into the console) with the R data file in the same folder.
  • R 4.5.2 and the package versions in the page header; each script prints the versions it runs under.

The analysis:

  • Two-way ANOVA of yield by N (0/1) and P (0/1) with interaction, n = 6 per cell, α = 0.05.
  • Pairwise comparisons of the cell means: Tukey HSD; compact letters from the significant pairs.
  • Blocks are omitted to match MinutePlot’s fully crossed design; this entry is a software comparison, not a recommended analysis of npk.

Side-by-side results

ANOVA summary

MinutePlot®

TermdfFp
N1, 205.75850.0263
P1, 200.25560.6187
N × P1, 200.64740.4305

R

TermdfFp
N1, 205.75850.0263
P1, 200.25560.6187
N × P1, 200.64740.4305

R values: verified in R 4.5.2 (see the verdict).

Cell means with significance letters

MinutePlot®

NPMeanLetters
N0P152.417a
N0P051.717a
N1P156.150a
N1P059.217a

R

NPMeanLetters
N0P152.417a
N0P051.717a
N1P156.150a
N1P059.217a

R values: verified in R 4.5.2 (see the verdict).

In the app each cell carries a compound label such as Aa (Aa1 with three factors): uppercase compares the first factor within each level of the second, lowercase the reverse (the digit the third factor). The plain letters shown here are MinutePlot’s single letter set over all cells, the direct counterpart of R’s cld(). MinutePlot assigns “a” to the highest mean, R to the lowest — a display convention, not a discrepancy; the grouping (which cells share a letter) is what is compared.

Verdict

F and p for N, P and N × P agree to R's printed values (tolerance 0.001); letters identical -- no cell differs from any other in either tool (all a).

R script

npk.R — each script loads its data, prints its versions and the R-side tables shown above, in page order; no plotting.

R values verified in R 4.5.2 (emmeans 2.0.4, multcomp 1.4-32, multcompView 0.1-12, ez 4.5.0, Hmisc 5.3.0, pls 2.9.0, drc 3.0-1, car 3.1-5) on 16–17 September 2026.