All tools

Statistics calculator

Descriptive statistics, box plot, regression and normal/binomial/Poisson probabilities.

Separate numbers with commas, spaces or new lines. Use a point for decimals: 2.5.

Results

Count (n)
13
Sum
243
Mean
18.6923
Median
15
Mode
153 times
Minimum
11
Maximum
45
Range
34
Q1 (first quartile)
14
Q3 (third quartile)
18
Interquartile range
4
Outlier fences (1.5 × IQR)
8 … 24
Outliers
30, 45
Variance (sample, s²)
86.7308
Standard deviation (sample, s)
9.31294
Standard error of the mean
2.58294
Skewness (sample G1)
2.25217
Excess kurtosis (sample G2)
5.29475
Coefficient of variation
49.82 %
95% confidence interval for the mean
13.0646 … 24.3201mean ± t × SEM with t = 2.1788 (12 degrees of freedom)

Box plot

1114151822

Histogram

92111145

5 equal-width bins (Sturges' rule).

z-scores

ValueCountz
111-0.826
121-0.7186
131-0.6112
141-0.5038
153-0.3965
161-0.2891
171-0.1817
181-0.07434
2210.3552
3011.214
4512.825

What this tool does

Paste a list of numbers and it computes the usual descriptive statistics at once: count, sum, mean, median and mode, minimum, maximum and range, quartiles by the method you choose, the interquartile range and outliers, variance and standard deviation for a sample or a whole population, the standard error of the mean, skewness, excess kurtosis, the coefficient of variation and a confidence interval for the mean at 90, 95 or 99%. It draws a box plot and a histogram and lists a z-score for every distinct value. Data with frequencies ("value count" on each line) is expanded for you.

The second tab takes pairs of numbers and gives Pearson's correlation r, R², the least-squares line with its equation, the standard error of the estimate, a scatter plot with the line and every residual. The third tab answers probability questions about the normal, binomial and Poisson distributions. Everything is computed in the page; the data is not sent anywhere.

Which numbers to look at

The mean uses every value and is pulled by extreme ones; the median is the middle value and ignores how extreme the ends are. With the sample data in the box, 12, 15, 11, 18, 22, 15, 14, 30, 13, 16, 17, 15 and 45, the mean is 18.69 but the median is 15: the 30 and the 45 pull the mean up. When the mean and median differ a lot, report the median (and the quartiles), or report both. The mode is the most common value, 15 here (three times); a list where every value occurs equally often has no mode.

The standard deviation measures spread in the data's own units. Choose sample when your numbers are a sample from something larger (almost always), which divides by n − 1; population divides by n and is right only when you have every member. For the sample above s = 9.31; without the two outliers it falls to 3.04. The standard error of the mean (s/√n) measures how precisely the mean is known, not how spread the data is.

Quartiles and outliers: the method matters

There is no single definition of a quartile, and calculators disagree on small data sets. Three are offered:

  • Tukey's hinges: the medians of the lower and upper halves (including the median when n is odd). This is what most school textbooks and box plots use.
  • Inclusive: linear interpolation at position (n − 1)p + 1, as in Excel's QUARTILE.INC, R's default and NumPy.
  • Exclusive: position (n + 1)p, as in Excel's QUARTILE.EXC and Minitab.

For 2, 4, 4, 4, 5, 5, 7, 9 the third quartile is 6, 5.5 or 6.5 depending on the method. Outliers are values beyond 1.5 × IQR from the quartiles (Tukey's fences); the box plot's whiskers stop at the most extreme values inside the fences and the outliers are drawn as circles. An outlier is a value to check, not one to delete.

Shape, intervals and z-scores

Skewness (sample G1, as in Excel's SKEW) is positive when the long tail is on the right. Excess kurtosis (sample G2, Excel's KURT) is 0 for a normal distribution and positive for heavy tails. Both are unreliable with small samples.

The confidence interval is mean ± t × SEM, with t from Student's t distribution with n − 1 degrees of freedom; the tool computes t itself (2.262 for n = 10 at 95%) rather than using a normal 1.96, which is too narrow for small samples. It assumes independent values from a roughly normal population or a large sample. A z-score says how many standard deviations a value is from the mean.

Regression and distributions

Pearson's r measures the strength of a straight-line relationship, from −1 to 1; R² is the share of the variance in y that the line explains. Correlation does not show cause, and a curved relationship can have r near 0, so look at the scatter plot. The normal panel gives the density, P(X ≤ x), P(X ≥ x) and the inverse (the x for a given probability); the special functions are implemented here and checked against SciPy to about 1e-12. Binomial gives the chance of exactly, at most or at least k successes in n trials; Poisson the same for counts at an average rate λ. For a worked comparison of mean, median and standard deviation, read which average to report; for counting problems, the combinatorics calculator is next door, and the function grapher plots curves.

Frequently asked questions

Should I use the sample or the population standard deviation?

Use the sample version (dividing by n − 1) unless your data include every member of the group you are describing. It corrects the tendency of a sample to understate the spread. The population version divides by n.

Why do calculators give different quartiles?

There are several definitions. This tool offers Tukey's hinges (textbooks), the inclusive method (Excel QUARTILE.INC, R, NumPy) and the exclusive method (Excel QUARTILE.EXC, Minitab). They agree on large data sets and differ on small ones.

When should I report the median instead of the mean?

When the data are skewed or have outliers, such as incomes, prices or waiting times. Then the median describes a typical value better. Reporting both, with the quartiles, is often best.

How is the confidence interval computed?

As mean ± t × s/√n, with t from Student's t distribution with n − 1 degrees of freedom at the chosen level. It assumes independent observations from a roughly normal population, or a reasonably large sample.

How accurate are the normal and t values?

The error function, incomplete gamma and beta functions and the inverse normal are implemented in the page and agree with SciPy to about 1e-12 in the tests, including far tails such as P(Z ≤ −8).