Standard Deviation and Variance
Separate with commas, spaces or newlines
How to Use
What this tool does
Two datasets can share a mean and differ wildly in spread. This tool takes a set of numbers and returns the mean, sample variance, population variance, sample standard deviation and population standard deviation, then draws a histogram and a box plot with points beyond 1.5 times the interquartile range flagged separately.
The difference between the two conventions is the denominator: sample variance divides by n−1 and population variance by n. For 2, 4, 4, 4, 5, 5, 7, 9 the mean is 5, population standard deviation is 2, and sample standard deviation is about 2.138. Both are reported so the tool never silently picks one on your behalf.
The input accepts spaces, commas or line breaks as separators, and any non-numeric item is reported by position. Charts redraw to the container width, and the numeric results copy out as a short block of text ready for a lab note or report.
Two conventions are reported because choosing the wrong denominator is a quiet error that changes the answer without any warning. Sample variance divides the sum of squared deviations by n minus one, population variance divides by n, and the two standard deviations are the square roots of those values. On a short dataset the gap is large; on a long one it narrows, which is exactly why the difference is easy to overlook until someone checks the working. The mean is printed first so the rest of the output can be reproduced by hand. Outlier detection uses the interquartile range: a point beyond one and a half times that range from a quartile is flagged and listed by value and position. A flag is a prompt to inspect the raw data, not an instruction to delete anything, because a genuine extreme value can be the most interesting observation in a set. The histogram bins are chosen automatically from the data, so the chart is a visual guide rather than a publication-grade density estimate; the box plot shows median, quartiles and whiskers on the same scale. Input parsing accepts spaces, commas and line breaks, and a non-numeric token is reported by position instead of being silently skipped, because skipping a value would change n and therefore both variances. Full-width punctuation should be normalised before pasting. With only one or two values the sample statistic is not meaningful and the tool says so explicitly.
Key features
- Both conventions: Sample divides by n−1 and population by n, with both results shown side by side.
- Flexible separators: Spaces, commas and line breaks all work, so a copied column of numbers can be pasted straight in.
- Outlier flags: Points outside 1.5 times the interquartile range are identified and listed separately.
- Histogram and box plot: Both charts redraw with each calculation, showing shape and median position directly.
- Invalid items located: Text or empty tokens produce a positional prompt rather than being dropped or returning NaN.
- Copyable summary: Mean, variance and standard deviation are emitted as aligned lines for a report.
How to use it
- Paste the data: Drop a set of numbers into the input, separated by spaces, commas or newlines.
- Press Calculate: The result area shows the mean plus both variances and both standard deviations.
- Read the charts: Use the histogram and box plot to see skew and extreme values.
- Check flagged points: Review outliers against the raw data to decide whether they are entry mistakes.
- Copy or clear: Copy the summary for your records, or clear to start the next dataset.
Things to keep in mind
- Pick the right convention: Use the sample form for sampled experiments and the population form for a complete set; they are not interchangeable.
- Very small sets: With only one or two values the sample variance is not meaningful, and the tool says so.
- Outliers are not errors: A flag is statistical, not a verdict; removing points is a domain decision, not an automatic one.
- Watch punctuation: Full-width commas and Chinese enumeration marks may be read as non-numeric, so normalise separators before pasting.
- Charts are indicative: Histogram bin count is chosen automatically; verify precise binning in specialist software if needed.