Bookmarks    
nPr and nCr    
Random Number    
SD Calculator    
Sample Size    
Percent Error    
Density    
Molarity    
Molar Mass    
Ohm's Law    
Watts to Amps    
Voltage Drop    
Long Division    
Mixed Numbers    
Rounding    
Nth Root    
Exponents    
Half-Life    
Polar Form    
De Moivre    
3D Distance    
Point to Line    
Cross Product    
Determinant    
Sin Cos Tan    
Triangle Area    
Scale Factor    
Sector Area    
Ellipse Area    
Cube Volume    
Box Volume    
Sphere Volume    
Cone Volume    
Pipe Volume    
Time Duration    
Time Card    
Present Value    
Future Value    
Churn Rate    
A/B Test Calc    
SEO Traffic    
Ideal Weight    
Fat Intake    
Child Height    
Golf Handicap    
Heat Index    
Wind Chill    
Dew Point    
Download Time    
kWh to Cost    
AC Size (BTU)    
Heating Costs    
LED Savings    
Trip Gas Cost    
Tire Size    
Solar Output    
Solar Payback    
Battery Size    
Wall Area    
Gravel Needed    
Mortar Mix    
Slope Grade    
Curtain Size    
Soil Needed    
Sod Needed    
Ramp Length    
Blind Size    
Drain Slope    
Board Feet    
Heat Loss    
Furniture Fit    
Moving Boxes    
Plywood Cuts    
Shelf Sag    
   Add
Probability and random number calculators
Independent Events
Independent Events
Two Events Solver
Two Events Solver
Repeated Trials
Repeated Trials
Bayes' Theorem
Bayes' Theorem
Expected Value
Expected Value
Binomial Distribution
Binomial Distribution
nPr and nCr
nPr and nCr
Circular Permutation
Circular Permutation
With Repetition
With Repetition
Random Number
Random Number
Averages and statistics calculators
Average Calculator
Average Calculator
Mean Median Mode
Mean Median Mode
SD Calculator
SD Calculator
Quartiles & IQR
Quartiles & IQR
Frequency Table
Frequency Table
Correlation (r)
Correlation (r)
Normal Probability
Normal Probability
Z-Score Calculator
Z-Score Calculator
Confidence Interval
Confidence Interval
Sample Size
Sample Size
Mark & Recapture
Mark & Recapture
P-Value Calculator
P-Value Calculator
Percentage and ratio calculators
Percentage Calc
Percentage Calc
Percent Change
Percent Change
Percent Difference
Percent Difference
Percent Error
Percent Error
Ratio Calculator
Ratio Calculator
Discount Calculator
Discount Calculator
Sales Tax Calculator
Sales Tax Calculator
Margin Calculator
Margin Calculator
Speed calculators
Speed Calculator
Speed Calculator
Density and concentration calculators
Density
Density
Molarity
Molarity
Molar Mass
Molar Mass
Physics and electricity calculators
Ohm's Law
Ohm's Law
Watts to Amps
Watts to Amps
Resistor Colors
Resistor Colors
Voltage Drop
Voltage Drop
Unit conversion calculators
Weight Converter
Weight Converter
Shoe Size Converter
Shoe Size Converter
Integer and signed number calculators
Long Division
Long Division
LCM Calculator
LCM Calculator
GCF Calculator
GCF Calculator
Integer Calculator
Integer Calculator
Prime Factorization
Prime Factorization
Diophantine Solver
Diophantine Solver
Modulo Calculator
Modulo Calculator
Factor Calculator
Factor Calculator
Roman Numerals
Roman Numerals
Fraction, decimal and rounding calculators
Fraction Calculator
Fraction Calculator
Mixed Numbers
Mixed Numbers
Simplify Fractions
Simplify Fractions
Fraction to Decimal
Fraction to Decimal
Decimal to Fraction
Decimal to Fraction
Rounding
Rounding
Equation and inequality calculators
Linear Equation
Linear Equation
Linear Systems
Linear Systems
Quadratic Formula
Quadratic Formula
Absolute Value
Absolute Value
Quadratic Inequality
Quadratic Inequality
Polynomial calculators
Binomial Theorem
Binomial Theorem
Square root and nth root calculators
Simplify Radicals
Simplify Radicals
Nth Root
Nth Root
Exponent and logarithm calculators
Exponents
Exponents
Log Calculator
Log Calculator
Number of Digits
Number of Digits
Scientific Notation
Scientific Notation
Sci. Notation Math
Sci. Notation Math
Half-Life
Half-Life
Complex number calculators
Complex Numbers
Complex Numbers
Polar Form
Polar Form
De Moivre
De Moivre
Function and graph calculators
Slope Calculator
Slope Calculator
Linear Function
Linear Function
Direct & Inverse Variation
Direct & Inverse Variation
y = ax² Calculator
y = ax² Calculator
Distance Formula
Distance Formula
3D Distance
3D Distance
Section Formula
Section Formula
Point to Line
Point to Line
Lat/Long Distance
Lat/Long Distance
Complete the Square
Complete the Square
Circle Equation
Circle Equation
Conic Sections
Conic Sections
Polar Coordinates
Polar Coordinates
Sequence calculators
Arithmetic Sequence
Arithmetic Sequence
Geometric Sequence
Geometric Sequence
Fibonacci Sequence
Fibonacci Sequence
Recurrence Relation
Recurrence Relation
Vector calculators
Vector Calculator
Vector Calculator
Cross Product
Cross Product
Matrix calculators
Matrix Calculator
Matrix Calculator
Determinant
Determinant
Inverse Matrix
Inverse Matrix
Plane geometry calculators
Sin Cos Tan
Sin Cos Tan
Degrees ⇔ Radians
Degrees ⇔ Radians
a sin θ + b cos θ
a sin θ + b cos θ
Triangle Solver
Triangle Solver
Triangle Area
Triangle Area
Right Triangle
Right Triangle
Pythagorean Theorem
Pythagorean Theorem
Polygon Angles
Polygon Angles
Scale Factor
Scale Factor
Parallel Lines
Parallel Lines
Rectangle Area
Rectangle Area
Parallelogram Area
Parallelogram Area
Trapezoid Area
Trapezoid Area
Circle Calculator
Circle Calculator
Sector Area
Sector Area
Inscribed Angle
Inscribed Angle
Ellipse Area
Ellipse Area
Solid geometry calculators
Cube Volume
Cube Volume
Cube Surface Area
Cube Surface Area
Box Volume
Box Volume
Box Surface Area
Box Surface Area
Cylinder Volume
Cylinder Volume
Cylinder Surface
Cylinder Surface
Sphere Volume
Sphere Volume
Sphere Surface
Sphere Surface
Spherical Cap Volume
Spherical Cap Volume
Cap Surface Area
Cap Surface Area
Ellipsoid Volume
Ellipsoid Volume
Ellipsoid Surface
Ellipsoid Surface
Pyramid Volume
Pyramid Volume
Pyramid Surface
Pyramid Surface
Cone Volume
Cone Volume
Cone Surface Area
Cone Surface Area
Frustum Volume
Frustum Volume
Frustum Surface Area
Frustum Surface Area
Pipe Volume
Pipe Volume
Capsule Volume
Capsule Volume
Capsule Surface Area
Capsule Surface Area
Date and time calculators
Age Calculator
Age Calculator
Days Between Dates
Days Between Dates
Date Calculator
Date Calculator
Hours From Now
Hours From Now
Day of the Week
Day of the Week
Time Calculator
Time Calculator
Time Zone Converter
Time Zone Converter
Hours Calculator
Hours Calculator
Time Duration
Time Duration
Time Card
Time Card
Finance and economics calculators
Compound Interest
Compound Interest
Simple Interest
Simple Interest
Interest Calculator
Interest Calculator
TVM Calculator
TVM Calculator
Present Value
Present Value
Future Value
Future Value
ROI Calculator
ROI Calculator
IRR Calculator
IRR Calculator
Payback Period
Payback Period
Average Return
Average Return
GDP Calculator
GDP Calculator
Web marketing and ad metric calculators
CTR Calculator
CTR Calculator
Conversion Rate
Conversion Rate
CPC, CPM & CPA
CPC, CPM & CPA
ROAS Calculator
ROAS Calculator
Break-Even CPA
Break-Even CPA
LTV Calculator
LTV Calculator
CAC Calculator
CAC Calculator
Churn Rate
Churn Rate
A/B Test Calc
A/B Test Calc
A/B Sample Size
A/B Sample Size
SEO Traffic
SEO Traffic
Break-Even Point
Break-Even Point
Markup vs. Margin
Markup vs. Margin
CAGR Calculator
CAGR Calculator
Health and fitness calculators
BMI Calculator
BMI Calculator
Sleep Calculator
Sleep Calculator
Calorie Calculator
Calorie Calculator
BMR Calculator
BMR Calculator
TDEE Calculator
TDEE Calculator
Ideal Weight
Ideal Weight
Body Fat Calculator
Body Fat Calculator
Lean Body Mass
Lean Body Mass
Calories Burned
Calories Burned
Protein Intake
Protein Intake
Macro Calculator
Macro Calculator
Carb Calculator
Carb Calculator
Fat Intake
Fat Intake
Child Height
Child Height
Sports calculators
Golf Handicap
Golf Handicap
Pace Calculator
Pace Calculator
1RM Calculator
1RM Calculator
Target Heart Rate
Target Heart Rate
Weather calculators
Heat Index
Heat Index
Wind Chill
Wind Chill
Dew Point
Dew Point
Computer calculators
Base Converter
Base Converter
Subnet Calculator
Subnet Calculator
Download Time
Download Time
Household energy and budget calculators
Electricity Cost
Electricity Cost
kWh to Cost
kWh to Cost
Yearly kWh to Cost
Yearly kWh to Cost
AC Size (BTU)
AC Size (BTU)
AC Running Cost
AC Running Cost
Heating Costs
Heating Costs
Gas vs Electric
Gas vs Electric
LED Savings
LED Savings
Salary Calculator
Salary Calculator
Budget Calculator
Budget Calculator
Car calculators
Trip Gas Cost
Trip Gas Cost
EV Charging Cost
EV Charging Cost
EV vs Gas Cost
EV vs Gas Cost
MPG Calculator
MPG Calculator
Tire Size
Tire Size
Solar power and battery calculators
Solar Output
Solar Output
Solar Panel Count
Solar Panel Count
Solar Payback
Solar Payback
Battery Size
Battery Size
Home and DIY calculators
Tile Calculator
Tile Calculator
Stair Calculator
Stair Calculator
Concrete Volume
Concrete Volume
Wall Area
Wall Area
Wallpaper Rolls
Wallpaper Rolls
Paint Calculator
Paint Calculator
Flooring Needed
Flooring Needed
Exterior Walls
Exterior Walls
Gravel Needed
Gravel Needed
Mortar Mix
Mortar Mix
Slope Grade
Slope Grade
Lumber Cut List
Lumber Cut List
Lot Coverage/FAR
Lot Coverage/FAR
Sheet Vinyl Roll
Sheet Vinyl Roll
Insulation Needed
Insulation Needed
Curtain Size
Curtain Size
TV Size & Distance
TV Size & Distance
Soil Needed
Soil Needed
Sod Needed
Sod Needed
Block Calculator
Block Calculator
Brick Calculator
Brick Calculator
Deck Materials
Deck Materials
Ramp Length
Ramp Length
Pilot Hole Size
Pilot Hole Size
Room Ventilation
Room Ventilation
Paint Thinning
Paint Thinning
Baseboard & Trim
Baseboard & Trim
Blind Size
Blind Size
Picture Hanging
Picture Hanging
Drain Slope
Drain Slope
Screw Calculator
Screw Calculator
Board Feet
Board Feet
Fence Calculator
Fence Calculator
Wood Shrinkage
Wood Shrinkage
Caulk Calculator
Caulk Calculator
Heat Loss
Heat Loss
Furniture Fit
Furniture Fit
Moving Boxes
Moving Boxes
Storage Capacity
Storage Capacity
Plywood Cuts
Plywood Cuts
Shelf Sag
Shelf Sag

Mean, Median, Mode and Range Calculator

Enter your data values separated by commas (,). The mean (arithmetic mean), median, mode and range are calculated together, along with the data sorted from smallest to largest.

Enter 2 or more numbers separated by commas (,), for example 10, 2, 38, 23, 38, 23, 21. Decimals and negative numbers are OK.
Result
Enter your numbers separated by commas in the field on the left and press "Calculate". The result will appear here.

What you can do on this page

  • Enter numbers separated by commas (,) and get four measures at once: the mean (arithmetic mean), the median, the mode and the range
  • The mode (the value that appears most often) is counted automatically. It also handles data with two or more modes (bimodal or multimodal) and data where every value appears once, so there is no mode
  • The data sorted from smallest to largest, the maximum, the minimum, the sum and the count are shown too, so you can check the median and the range yourself
  • A plain-language guide to "When should I use the mean, the median or the mode?" and copy-and-paste formulas for Excel, Google Sheets and Python are all on this page
The mode is found by counting whether exactly the same value appears two or more times. With data that is finely spread out, such as height or weight, the same value rarely appears twice. In that case it is usual to make a frequency distribution table (group the data into class intervals) first and look at the class interval with the highest frequency.

What is this calculation used for?

Stocking the best-selling sizes (in retail, the mode matters)

Suppose a store sold 7 pairs of shoes in one day, in sizes 9, 9.5, 9, 10, 9.5, 9 and 11. The mean is about 9.6, but what the store should stock more of is the size that sells most, which is the mode: size 9 (3 pairs).
When you decide what to order or keep in stock based on "which one sells most", such as sizes, colors or models, the mode, not the mean, is the number that matters.

Making sense of "the average is X dollars" in the news (mean or median?)

Suppose five households have savings of $30,000, $30,000, $40,000, $50,000 and $400,000. The mean is $110,000, but the median is $40,000 and the mode is $30,000.
For lopsided data such as savings or income, a few large values pull the mean up, so the median or the mode is closer to what a typical household has. That is why the US Census Bureau reports household income as both a median and a mean. Knowing the difference keeps you from being misled when you read about an "average" in the news.

Finding the most popular choice in a survey or vote (categorical data)

In a vote on favorite school lunches by a class of 30 students, with pizza 12 votes, tacos 10 and chicken nuggets 8, the typical choice is the mode, "pizza". There is no way to calculate a mean or median of lunch menus.
The mode is the only measure of center you can use for data that is not numbers (categorical data). From product surveys to election results, it is one of the most used basics of summarizing data.

Quality control on a production line (watching the spread with the range R)

In factories, a few products are regularly pulled from the line and measured for size or weight, and the range (maximum − minimum) of each small sample is recorded and watched. This is called an R chart, and it is widely used (control charts are one of the seven basic tools of quality).
If the range suddenly gets wider, it is a sign that something is wrong, such as a loose machine part or uneven material. Because one subtraction shows the spread, it is used every day on the factory floor.

Seeing how test scores are really spread out (for teachers and parents)

Even if the class average is 60 points, the class may be split into a group that did well (around 80) and a group that struggled (around 40), with almost no students near 60 (a bimodal distribution).
Instead of judging by the mean alone, also look at the mode, the median and the spread of the scores (the range). Then you can plan help that fits the real situation of the class.

Formula

Mode
Standard notation (the usual math form)
\(M_o\) \(=\) \(x \ \ \bigl(\, f(x) = f_{\max} \,\bigr)\)
In words (symbols replaced with words)
② \(M_o\): mode \(=\) ① \(x\): the value that appears most often
The formula in words
① Count how many times each value appears in the data (its frequency), and pick \(x\): the value that appears most often
② That value is the \(M_o\): mode
Quick example
For the scores of 5 tests, 60, 70, 70, 80, 95, only 70 appears twice, the most of any value, so the mode is
\(M_o\): mode \(=\) the value that appears most often (70)
\(M_o = 70 \ \ \bigl(\, f(70) = 2 \,\bigr)\)
Key idea
The mode is a measure of center that you find just by counting, with no adding or dividing as in the mean. In the formula, \(f(x)\) is "how many times the value \(x\) appears in the data (its frequency)", and \(f_{\max}\) is "the largest of those frequencies". If two or more values share the highest count, all of them are modes (data with two peaks is called bimodal). If every value appears only once, there is no mode. The biggest strength of the mode is that it is the only measure of center that also works for data that is not numbers (categorical data), such as a vote on favorite school lunches.
Mean (arithmetic mean)
Standard notation (the usual math form)
\(\bar{x}\) \(=\) \((x_1 + x_2 + \cdots + x_n)\) \(\div\) \(n\)
In words (symbols replaced with words)
③ \(\bar{x}\): mean \(=\) ① sum of the data \(\div\) ② \(n\): number of values
The formula in words
① Take the sum of the data
② divide it by the \(n\): number of values
③ and you get the \(\bar{x}\): mean
Quick example
The mean of the scores of 5 tests, 60, 70, 70, 80, 95, is
\(\bar{x}\): mean \(=\) sum (60 + 70 + 70 + 80 + 95 = 375) \(\div\) count (5 tests)
\((60 + 70 + 70 + 80 + 95) \div 5 = 375 \div 5 = 75\)
Key idea
The mean tells you how much each person would get if the total were shared out equally. It is the only measure of center that uses the value of every data point in the calculation. Because of that, its weak point is that extremely large (or small) values, called outliers, pull it strongly. In the example above, the best score of 95 pulls the mean of 75 above three of the five scores (60, 70, 70). In statistics, the mean of a sample is usually written \(\bar{x}\) (x-bar), and the mean of a whole population is written \(\mu\) (mu).
Median
Standard notation (the usual math form)
\(\tilde{x}\) \(=\) \(x_{\left(\,(n+1)/2\,\right)}\)
\(\tilde{x}\) \(=\) \(\left( x_{(n/2)} + x_{(n/2+1)} \right)\) \(\div\) \(2\)
In words (symbols replaced with words)
② \(\tilde{x}\): median (odd number of values) \(=\) ① the middle value after sorting from smallest to largest
⑤ \(\tilde{x}\): median (even number of values) \(=\) ③ sum of the two middle values \(\div\) ④ \(2\): number of middle values
The formula in words
① Sort the data from smallest to largest. When there is an odd number of values, the value exactly in the middle
② is the \(\tilde{x}\): median
③ When there is an even number of values, there are two middle values. Take the sum of the two middle values
④ divide it by the \(2\): number of middle values (this is the mean of the two middle values)
⑤ and you get the \(\tilde{x}\): median
Quick example
Sorted from smallest to largest, the scores of 5 tests are 60, 70, 70, 80, 95 (an odd number of values, 5). The median is the value exactly in the middle (the 3rd one), so
\(\tilde{x}\): median \(=\) 3rd value from the smallest (70)
\(\tilde{x} = x_{(3)} = 70\)
Key idea
In the formula, \(x_{(k)}\) means "the \(k\)th value when the data is sorted from smallest to largest" (for example, \(x_{(1)}\) is the minimum). The median is the middle by rank, so its strength is that extremely large or small values (outliers) hardly affect it. In the example above, the mean is 75 but the median is 70, which is not pulled up by the single score of 95. When the mean and the median are far apart, it is a sign that the data is being pulled by a few large (or small) values.
Range
Standard notation (the usual math form)
\(R\) \(=\) \(x_{\max}\) \(-\) \(x_{\min}\)
In words (symbols replaced with words)
③ \(R\): range \(=\) ① \(x_{\max}\): maximum \(-\) ② \(x_{\min}\): minimum
The formula in words
① Take the maximum (the largest value)
② subtract the minimum (the smallest value)
③ and you get the \(R\): range
Quick example
For the scores of 5 tests, 60, 70, 70, 80, 95, the range is the maximum 95 minus the minimum 60, so
\(R\): range \(=\) maximum (95) \(-\) minimum (60)
\(95 - 60 = 35\)
Key idea
The range is the quickest way to see how widely the data is spread out. The mean, the median and the mode describe the center of the data, while the range is the one measure here that describes the spread. Keep this difference in mind. But the range only looks at two values, the maximum and the minimum, so a single outlier can change it a lot. To measure the spread more accurately, the standard deviation and similar measures are used. The word "range" can mean other things in some fields, but this calculator uses the most basic definition, "maximum − minimum".
The mean, the median and the mode are the three main measures of center, each summing up data in a single number. The mean reflects every small difference, the median resists outliers, and the mode is found just by counting and also works for categorical data. Each has its own strength, so choose the one that fits the shape of your data. The range (maximum − minimum) is the quickest measure of how wide the spread is.

Symbols and terms

Symbols

\(x_1, x_2, \ldots, x_n\) x sub 1, x sub 2, …, x sub n The individual data values. (Example - the scores of 5 tests)
\(n\) n The number of values. (Example - for 5 tests, \(n = 5\))
\(\bar{x}\) x-bar The mean (arithmetic mean). A bar over the letter is the standard way to write a mean in statistics. The mean of a whole population is written \(\mu\) (mu) instead.
\(\tilde{x}\) x-tilde The median. Textbooks often just write the word "median" instead of a symbol, and some write it as M or Med.
\(M_o\) M sub o (mode) The mode, a short form of the word "mode". It is also written Mo. Textbooks usually just write the word instead of a symbol.
\(f(x)\) f of x How many times the value \(x\) appears in the data (its frequency). (Example - if 70 appears twice, \(f(70) = 2\))
\(f_{\max}\) f max The largest frequency (the highest count). A mode is a value whose frequency equals this number.
\(x_{(k)}\) x sub k in parentheses The \(k\)th value when the data is sorted from smallest to largest. (Example - \(x_{(1)}\) is the minimum)
\(x_{\max},\ x_{\min}\) x max, x min The maximum and the minimum of the data. They are the inputs to the range formula.
\(R\) R The range, the maximum minus the minimum. It comes from the first letter of "range".

Terms

measure of center A single number that sums up where the data is centered. The three main ones are the mean, the median and the mode. In US schools they are usually taught in Grade 6.
arithmetic mean All the data added up and divided by the number of values. This is what people usually mean by "average". Because it uses every value, it is easily pulled by outliers.
median The value exactly in the middle when the data is sorted from smallest to largest. With an even number of values, take the mean of the two middle values. It is a measure of center that outliers hardly affect.
mode The value that appears most often in the data. If several values share the highest frequency, all of them are modes; if every value appears once, there is no mode. It is the only measure of center that also works for categorical data.
range The maximum minus the minimum. It is the quickest measure of how spread out the data is.
frequency How many times a value (or a class interval) appears in the data. The mode is the value with the highest frequency.
frequency distribution table A table that splits the data into ranges (class intervals) such as "60 to under 70" and counts the frequency of each. For finely spread data such as height, the mode is thought of as the class interval with the highest frequency.
class interval In a frequency distribution table, one of the ranges such as "60 to under 70" that the data is split into (also called a class or a bin). The value in the middle of a class interval is its midpoint, and for finely spread data the mode is taken as the midpoint of the class interval with the highest frequency.
bimodal (multimodal) When the distribution of the data has two (or more) peaks. Having more than one mode is a sign of this, and the data may be a mix of two groups with different characteristics.
outlier A value that is extremely far from the other values. The mean and the range are pulled strongly by outliers, but the median and the mode are hardly affected.

Good to know before you start

Here is what helps you use the calculation on this page with real understanding, not just by pressing the button.

Addition, subtraction and division (Grades 3–4)
  • Being able to add three or more numbers one after another
  • Being able to subtract a smaller number from a larger one
The mean (Grade 6)
  • Knowing that the mean shows the value you get when uneven amounts are leveled out
  • Knowing that mean = sum ÷ count
Statistics and measures of center (Grade 6)
  • Being able to sort data from smallest to largest
  • Knowing what the three measures of center (mean, median and mode) mean and how they differ
  • Being able to read the most common value from a dot plot (dots stacked above a number line)
Frequency tables and histograms (Grade 6)
  • Knowing that frequency is how many times a value (or a class interval) appears
  • Knowing that for finely spread data you group it into class intervals before looking for the mode, and that range = maximum − minimum

How to calculate it in Excel

Copy the whole table below and paste it into cell A1 in Excel. It works as is.
Table to find the mode
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Mode =MODE.SNGL(B1:B5)
Table to find the mean (arithmetic mean)
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Sum =SUM(B1:B5)
Count =COUNT(B1:B5)
Mean (arithmetic mean) =AVERAGE(B1:B5)
Table to find the median
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Median =MEDIAN(B1:B5)
Table to find the range (max − min)
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Maximum =MAX(B1:B5)
Minimum =MIN(B1:B5)
Range (max − min) =B6-B7
After pasting, B1 to B5 are the cells for your numbers, and the cells in bold green are calculated automatically.
The first table shows the mode 70 in B6. The second shows the sum 375 in B6, the count 5 in B7 and the mean 75 in B8. The third shows the median 70 in B6, and the fourth shows the range 35 in B8.
MODE.SNGL returns only the first mode when there are several. To get all of them, use "=MODE.MULT(B1:B5)" (the results spill into several cells). When every value appears once, you get the "#N/A" error, which means there is no mode.
To use a different number of values, add (or remove) rows of numbers, then change "B1:B5" in the formulas to your actual data range (for 7 values, B1:B7).

How to calculate it in Google Sheets

Copy the whole table below and paste it into cell A1 in Google Sheets. It works as is.
Table to find the mode
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Mode =MODE(B1:B5)
Table to find the mean (arithmetic mean)
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Sum =SUM(B1:B5)
Count =COUNT(B1:B5)
Mean (arithmetic mean) =AVERAGE(B1:B5)
Table to find the median
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Median =MEDIAN(B1:B5)
Table to find the range (max − min)
Value 1 60
Value 2 70
Value 3 70
Value 4 80
Value 5 95
Maximum =MAX(B1:B5)
Minimum =MIN(B1:B5)
Range (max − min) =B6-B7
Almost the same functions as in Excel (AVERAGE, MEDIAN, MAX, MIN) work as is. Only the mode function is named "MODE" (it works the same as MODE.SNGL in Excel; to get several modes at once, use MODE.MULT).
Copy the whole table, paste it into cell A1, and replace B1 to B5 with your own numbers.

How to calculate it in Python

import statistics

numbers = [10, 2, 38, 23, 38, 23, 21]  # the data to look at

mean_value = statistics.mean(numbers)        # mean (arithmetic mean)
median_value = statistics.median(numbers)    # median
mode_values = statistics.multimode(numbers)  # mode (a list with all modes if there are several)
value_range = max(numbers) - min(numbers)    # range (max - min)

print(f"Mean: {mean_value}")
print(f"Median: {median_value}")
print(f"Mode: {mode_values}")
print(f"Range: {value_range}")
print(f"Sorted: {sorted(numbers)}")
Runs with the standard library only (the statistics module). Replace the numbers list at the top with your own numbers and run it. For the mode, multimode (Python 3.8 and later) returns a list with all the modes if there are several. In the example above it is [38, 23] (38 and 23 each appear twice). When every value appears once, it returns all the values; read this as "no mode".

How to write it in LaTeX and other math languages (copy and paste)

Mode
Mo = x (f(x) = f_max)
M_o = x \quad \bigl(\, f(x) = f_{\max} \,\bigr)
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mrow>
    <msub><mi>M</mi><mi>o</mi></msub>
    <mo>=</mo>
    <mi>x</mi>
    <mspace width="1em"/>
    <mrow>
      <mo>(</mo>
      <mi>f</mi><mo>(</mo><mi>x</mi><mo>)</mo>
      <mo>=</mo>
      <msub><mi>f</mi><mi>max</mi></msub>
      <mo>)</mo>
    </mrow>
  </mrow>
</math>
M_o = x (f(x) = f_(max))
Commonest[{x1, x2, x3}]
Statistics:-Mode([x1, x2, x3]);
M = mode(x);
M_o = x (f(x) = f_max)
Mean (arithmetic mean)
x̄ = (x₁ + x₂ + ⋯ + xₙ) ÷ n
\bar{x} = \frac{x_1 + x_2 + \cdots + x_n}{n} = \frac{1}{n}\sum_{i=1}^{n} x_i
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mrow>
    <mover accent="true"><mi>x</mi><mo>&#x00AF;</mo></mover>
    <mo>=</mo>
    <mfrac>
      <mrow>
        <msub><mi>x</mi><mn>1</mn></msub>
        <mo>+</mo>
        <msub><mi>x</mi><mn>2</mn></msub>
        <mo>+</mo>
        <mo>&#x22EF;</mo>
        <mo>+</mo>
        <msub><mi>x</mi><mi>n</mi></msub>
      </mrow>
      <mi>n</mi>
    </mfrac>
  </mrow>
</math>
bar x = (x_1 + x_2 + cdots + x_n) / n
Mean[{x1, x2, x3}]
xbar := add(x[i], i = 1 .. n)/n;
xbar = mean(x);
x̄ = (x_1 + x_2 + ⋯ + x_n)/n
Median
\tilde{x} = \begin{cases} x_{(\,(n+1)/2\,)} & (n:\ \mathrm{odd}) \\[6pt] \dfrac{x_{(n/2)} + x_{(n/2+1)}}{2} & (n:\ \mathrm{even}) \end{cases}
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mrow>
    <mover accent="true"><mi>x</mi><mo>&#x7E;</mo></mover>
    <mo>=</mo>
    <mrow>
      <mo>{</mo>
      <mtable columnalign="center left">
        <mtr>
          <mtd><msub><mi>x</mi><mrow><mo>(</mo><mo>(</mo><mi>n</mi><mo>+</mo><mn>1</mn><mo>)</mo><mo>/</mo><mn>2</mn><mo>)</mo></mrow></msub></mtd>
          <mtd><mrow><mo>(</mo><mi>n</mi><mo>:</mo><mtext>odd</mtext><mo>)</mo></mrow></mtd>
        </mtr>
        <mtr>
          <mtd><mfrac>
            <mrow>
              <msub><mi>x</mi><mrow><mo>(</mo><mi>n</mi><mo>/</mo><mn>2</mn><mo>)</mo></mrow></msub>
              <mo>+</mo>
              <msub><mi>x</mi><mrow><mo>(</mo><mi>n</mi><mo>/</mo><mn>2</mn><mo>+</mo><mn>1</mn><mo>)</mo></mrow></msub>
            </mrow>
            <mn>2</mn>
          </mfrac></mtd>
          <mtd><mrow><mo>(</mo><mi>n</mi><mo>:</mo><mtext>even</mtext><mo>)</mo></mrow></mtd>
        </mtr>
      </mtable>
    </mrow>
  </mrow>
</math>
tilde x = {(x_(((n+1)/2)), if n odd), ((x_((n/2)) + x_((n/2+1)))/2, if n even):}
Median[{x1, x2, x3}]
Statistics:-Median([x1, x2, x3]);
med = median(x);
x̃ = (x_((n/2)) + x_((n/2+1)))/2 (for an even number of values; for an odd number, x̃ = x_(((n+1)/2)))
Range
R = xₘₐₓ − xₘᵢₙ
R = x_{\max} - x_{\min}
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mrow>
    <mi>R</mi>
    <mo>=</mo>
    <msub><mi>x</mi><mi>max</mi></msub>
    <mo>&#x2212;</mo>
    <msub><mi>x</mi><mi>min</mi></msub>
  </mrow>
</math>
R = x_(max) - x_(min)
Max[{x1, x2, x3}] - Min[{x1, x2, x3}]
R := max(L) - min(L);
R = max(x) - min(x);
R = x_max − x_min

How to have ChatGPT  do the calculation

You are a statistics calculation assistant. Do the following calculation by actually running Python code, and base your answer only on the numbers from the execution result (do not answer by mental math or guessing).

For the following data, find each of the values below.
Data: 10, 2, 38, 23, 38, 23, 21
1. The mean (arithmetic mean)
2. The median
3. The mode. If there are several, list all of them. If every value appears once, answer "no mode"
4. The range (maximum − minimum)
5. The data sorted from smallest to largest

Show the formulas you used and the numbers from the execution result.

How to Use
  1. 1
    Enter your numbers
    Type the numbers you want to calculate with into the input fields
  2. 2
    Calculate
    Press the "Calculate" button
  3. 3
    Check the result
    The result appears on the spot. The same page also explains the idea behind the calculation and the formula
  DataChef Features
Easy and Free
Unlimited conversions for free.
No technical knowledge required.
Intuitive and user-friendly operation.
No Registration Required
Available immediately after access.
Can be used without registering personal information.
Safe and Secure
Fully SSL encrypted communication.
Automatic file deletion by clicking "download".
Fast
High-speed site access
and rapid file conversion.
No Watermark
No watermark.
No attribution required.
Commercial Use Available
Free for commercial use.
No need to contact us for commercial use permission.