Error Bar Chart Maker

Draws an error bar chart from grouped data, with the summary statistics.Paste and it draws. There are three kinds of error bar.

Copy straight out of a spreadsheet, header row included. Groups may have different numbers of replicates — a short column is read as a short column.

How to use it

  1. Pick the layout. If your spreadsheet has one column per condition, wide is what you already have.
  2. Copy the block including the header row and paste it in. Groups may have different numbers of replicates.
  3. Type a y axis label and it is drawn on the chart.
  4. Pick an error bar. Leave it on all three at first to see the difference, then choose the one your figure will carry.
  5. Choose bars or dots. Showing the individual points is much more honest when there are few replicates.
  6. Copy the chart as a PNG, or copy the summary table.

The formulas, and what to watch for

The three error bars say different things. That is why this page puts them side by side.

Standard deviation (SD)

How spread out the data themselves are. More replicates do not shrink it — it is a property of what you are measuring, not of how well you measured it.

SD
√( Σ(xᵢ − x̄)² / (n − 1) )

Standard error (SEM)

How well the mean is known. It shrinks with the square root of the number of replicates. It is the one people reach for most, and it draws the shortest.

SEM
SD / √n

95 % confidence interval

Repeat the experiment and 95 % of such intervals contain the true mean. It is SEM multiplied by a t value, and with few replicates that t is large enough to make the interval far more than twice the SEM.

Interval
x̄ ± t(0.975, n−1) × SEM
n = 3
t = 4.303
n = 11
t = 2.228

Two groups — Welch's t-test

A t-test that does not assume the two groups share a variance, which is why its degrees of freedom are not a whole number.

t
(x̄₁ − x̄₂) / √(s₁²/n₁ + s₂²/n₂)
df
(s₁²/n₁ + s₂²/n₂)² / ( (s₁²/n₁)²/(n₁−1) + (s₂²/n₂)²/(n₂−1) )

What to watch for

  • An error bar means nothing until you say which one it is. SD, SEM and the 95 % interval differ substantially on the same data, and naming it in the figure caption is the rule.
  • A shorter SEM is not a better result. More replicates shrink the SEM and leave the spread of the data exactly where it was.
  • ⭐ With six replicates or fewer the 95 % interval reaches further than the standard deviation, because t(0.975, n−1) exceeds √n; the order flips at n = 7. The guess that the interval must be the narrowest of the three is wrong exactly where most experiments live.
  • A bar chart's axis has to start at zero. Bars force it here; the dot chart uses only the range the data occupy.
  • Stars are a convention, not a measurement: * p < 0.05, ** p < 0.01, *** p < 0.001, **** p < 0.0001. The p value is always printed beside them.
  • No test is run on three or more groups, because repeating a t-test on every pair inflates false positives.
  • Checking normality and choosing a test are outside this page. It runs one two-group Welch t-test and nothing else.

Frequently asked questions