Enter your values
Enter your data
Enter observations once. The calculator sorts them before analyzing the distribution.
Separate values with commas, spaces, semicolons, or new lines. Integers, decimals, negatives, and repeated observations are accepted.
What is a range calculator?
The range is the difference between the largest and smallest observations in a data set. It is a simple measure of total spread, expressed in the same units as the data.
Important terms
- Minimum
- The smallest observation in the data set.
- Maximum
- The largest observation in the data set.
- Midrange
- The arithmetic mean of the minimum and maximum: (min + max) / 2.
When this method is useful
- Quickly compare the total spread of two data sets measured on the same scale.
- Check the endpoints of a list of scores, measurements, or recorded values.
- Find the midrange, a simple center estimate based only on the endpoints.
Formula and variables
- R
- the range
- xₘₐₓ
- the largest observation
- xₘᵢₙ
- the smallest observation
Sort or inspect the values to locate the endpoints, then subtract the minimum from the maximum. The range cannot be negative.
Domain note: At least one finite real observation is required. With one observation, the minimum equals the maximum and the range is zero.
How to use this calculator
- 1
Enter one or more finite observations.
- 2
Identify the smallest and largest values.
- 3
Subtract the minimum from the maximum.
- 4
Interpret the result in the original measurement units.
Step-by-step examples
Example 1
Problem: Find the range of 12, 15, 18, 21, 30.
Substitution: The minimum is 12 and the maximum is 30, so R = 30 − 12.
Result: Range = 18.
The largest observation is 18 units greater than the smallest observation.
Example 2
Problem: Find the range of −8, −3, 2, 7.
Substitution: R = 7 − (−8).
Result: Range = 15.
Subtracting a negative minimum increases the distance between endpoints.
Example 3
Problem: Find the range of 5.2, 5.2, 5.2.
Substitution: The minimum and maximum are both 5.2.
Result: Range = 5.2 − 5.2 = 0.
Identical observations have no spread.
Rules, edge cases, and related ideas
The endpoints determine the range
Changing an observation that is not the minimum or maximum may leave the range unchanged.
Units are preserved
If measurements are in centimetres, the range is also in centimetres.
Range is nonnegative
The maximum is always at least as large as the minimum.
Edge cases and limitations
- A one-value data set has range zero.
- Repeated values do not change the endpoints unless they introduce a new minimum or maximum.
- Negative values are valid; subtract the signed minimum carefully.
- The range can overflow JavaScript's finite numeric representation for extreme magnitudes; invalid non-finite results should not be interpreted.
How this differs from a related concept
The range measures the full endpoint-to-endpoint span. The interquartile range measures the middle half of ordered observations and is less sensitive to extremes. Variance and standard deviation use deviations from the mean and reflect all observations.
Understand the result
The range is easy to calculate and communicate, but it uses only two observations. One unusually high or low value can make the range much larger, and it does not show whether the remaining values cluster together or are widely spread. For a more outlier-resistant measure, compare the interquartile range; for a measure that uses every value, consider variance or standard deviation.
Common mistakes
- Subtracting the maximum from the minimum, which reverses the sign.
- Forgetting parentheses when the minimum is negative.
- Assuming the range describes how the observations are distributed between the endpoints.
- Comparing ranges from measurements with different units or scales.
Frequently asked questions
How do you calculate range?
Subtract the smallest value from the largest value: range = maximum − minimum.
Can the range be negative?
No. The maximum is never smaller than the minimum, so the range is zero or positive.
What is the range of one number?
It is zero, because that observation is both the minimum and maximum.
Is range affected by outliers?
Yes. Since it depends only on the minimum and maximum, a single extreme observation can substantially change it.