Utilvo Studio100% Client-Side Suite
HomeCalculatorsStatistics Calculator
Descriptive & Inferential Statistics Engine

Statistics Calculator: Mean, Std Dev & Box Plot

Calculate mean, median, mode, variance, standard deviation, and quartiles. Inspect Tukey outlier fences and dynamic SVG box-and-whisker plots with step-by-step mathematical logs.

Loading Statistics Calculator...

Measures of Central Tendency: Locating the Center

How mean, median, mode, and midrange summarize the central location of a probability distribution.

In descriptive statistics, a measure of central tendency is a single summary value that attempts to describe a set of data by identifying the central position within that dataset. Depending on whether your data is symmetric, normal, or heavily skewed, different centrality metrics provide vastly different insights.

MetricMathematical FormulaOutlier SensitivityBest Used For
Arithmetic Mean (x̄)x̄ = Σx / nHighly SensitiveSymmetric, bell-shaped normal distributions without extreme outliers.
Median (Q₂)Middle value of sorted arrayResistant (Robust)Skewed data (household income, home prices, response latencies).
Modearg max(frequency)ResistantCategorical and discrete data, detecting multimodal distributions.
Midrange(Min + Max) / 2Extremely SensitiveQuick mental approximations when only extremes are known.

Measures of Dispersion: Sample vs. Population

Understanding standard deviation, variance, and why dividing by n − 1 is essential.

Why Sample Variance Divides by n − 1 (Bessel's Correction)

When you calculate variance from a sample rather than the entire population, the sample data points are naturally closer to their own sample mean (x̄) than to the true, unknown population mean (μ). If you divide the sum of squared deviations by n, you systematically underestimate the true variance. Dividing by n − 1 (degrees of freedom) cancels this bias and yields an unbiased estimator:

Sample Variance (s²)s² = Σ(x - x̄)² / (n − 1)
Population Variance (σ²)σ² = Σ(x - μ)² / N

Standard Deviation (s, σ)

The square root of variance (s = √s²). Because it is expressed in the exact same units as the original raw data, it is the primary metric for interpreting spread and applying the Empirical Rule (68-95-99.7%).

Mean Absolute Dev (MAD)

The average linear distance between each data point and the dataset mean: Σ|x - x̄| / n. Unlike standard deviation, MAD does not square deviations, making it less punitive toward moderate outliers.

Interquartile Range (IQR)

The difference between the 75th percentile (Q₃) and 25th percentile (Q₁): IQR = Q₃ − Q₁. It captures the dispersion of the middle 50% of the dataset and serves as the foundation for Tukey outlier detection.

The Five-Number Summary & Box-and-Whisker Plots

How John Tukey's exploratory data analysis framework reveals symmetry, spread, and anomalies.

Introduced by mathematician John Tukey in 1977, the Five-Number Summary provides a comprehensive non-parametric summary of a distribution regardless of its underlying shape:

01

The Central Box (Q₁ to Q₃)

The rectangular body spans from the 25th percentile (Q₁) to the 75th percentile (Q₃). This box encloses exactly half of all data points. The vertical line inside represents the Median (Q₂).

02

The Whiskers (Min to Max)

Whiskers extend outward from the box edges to the smallest and largest observations that fall within the non-outlier range. When whisker lengths are unequal, the distribution exhibits positive or negative skewness.

03

Tukey's 1.5 × IQR Outlier Fences

Outliers are quantitatively identified using Tukey's fence formulas: Lower = Q₁ − 1.5 × IQR and Upper = Q₃ + 1.5 × IQR. Any point outside these fences is marked as a red outlier dot.

04

Linear Percentile Interpolation

This calculator implements the standard continuous linear interpolation method (Rank = (P / 100) × (n - 1)). This produces smooth, statistically accurate quartile estimates even for small sample sizes.

Worked Step-by-Step Statistical Examples

Practical calculations illustrating symmetric and skewed datasets.

Symmetric Distributionn = 5
Dataset: [10, 20, 30, 40, 50]
Sum: 150
Mean: 150 / 5 = 30

• Deviations: [-20, -10, 0, +10, +20]

• Sum of Squares: 400+100+0+100+400 = 1000

• Sample Variance: 1000 / 4 = 250

Std Dev (s)√250 ≈ 15.8114
Outlier ImpactSalary Data
Values: [40k, 42k, 45k, 48k, 50k, 250k]
Mean: $79,166.67
Median: $46,500.00

• Outlier ($250k) inflates mean by 70%.

• Median accurately reflects typical worker.

• Upper Fence ($60.1k) flags 250k as anomaly.

Flagged Outlier250,000
Tukey QuartilesIQR Analysis
Sorted: [2, 4, 4, 4, 5, 5, 7, 9]
Q₁ (25%): 4.0
Q₃ (75%): 5.5

• IQR = 5.5 − 4.0 = 1.5

• Lower Fence = 4.0 − (1.5×1.5) = 1.75

• Upper Fence = 5.5 + (1.5×1.5) = 7.75

Detected Outlier9 (> 7.75)

Statistical Computing Highlights

Engineered for researchers, students, data scientists, and analysts.

100% In-Browser Privacy

Processes thousands of observations entirely on your device. Your sensitive data is never uploaded to remote servers.

Dual-Scope Formulas

Toggle seamlessly between Sample (n − 1) Bessel correction and true Population (n) variance and standard deviation.

Dynamic SVG Box Plot

Instant graphical visualization of the Five-Number summary, IQR spread, and flagged red outlier markers.

Complete Working Logs

Inspect the complete step-by-step arithmetic deductions, intermediate sums, and formula substantiations for homework or audits.

Frequently Asked Questions

Common questions regarding quartile interpolation, degrees of freedom, and outlier thresholds.

Q:Which quartile calculation method does this tool use?

It uses linear interpolation between ranked values (the standard 'Method 1' approach), not the exclusive median-of-halves method — so Q1 and Q3 may differ slightly from tools that split the dataset into a strict lower and upper half.

Q:Does the standard deviation use the sample or population formula?

By default it uses the sample formula (dividing by n-1), the standard choice for estimating population parameters from a subset — but you can switch to the population formula (dividing by n) with the Data Scope toggle if your dataset represents the entire population.

Q:How are outliers detected and what threshold is applied?

Any value below Q1 minus 1.5 times the IQR, or above Q3 plus 1.5 times the IQR, is marked as an outlier in the box plot.

Q:Can the calculator handle large datasets in the browser?

Yes, it processes thousands of values locally without sending data to a server, keeping calculations fast and private.