Quiz 2
Registry Synced

Central Tendency — Mean, Median, and Mode

3731 words
19 min read

Reading compass

Now · 🎯 Learning Objectives

Central Tendency — Mean, Median, and Mode

🎯 Learning Objectives

After completing this topic, you will be able to:
  • Compute the mean, median, and mode for raw data and frequency distributions
  • Explain the properties and limitations of each measure
  • Choose the appropriate measure of central tendency based on data type and distribution shape
  • Identify skewness and understand how it affects the mean vs. median
  • Recognize outliers and their disproportionate effect on the mean

📋 Prerequisites

  • Data Types & Scales (01-data-types-scales) — knowing which measures are valid for which scales
  • Categorical Data (02-categorical-frequency) — familiarity with frequency tables
  • Basic arithmetic: addition, division, ordering

📖 Core Content

4.1 Intuition: Finding the "Center" of Data

Imagine you have a list of 100 salaries at a company. You want to give someone a single number that represents a "typical" salary. What number do you choose? There are three natural candidates:
  1. The average (mean): Add up all salaries and divide by 100
  2. The middle (median): Sort all salaries and pick the one in the middle
  3. The most common (mode): Find the salary that appears most frequently Each gives you a different kind of "typical" value. The interesting part is that they can tell very different stories — especially when the data is skewed (not symmetric).
Everyday analogy: At a party, people guess the "average" age. If there are 10 children (age 10), 10 adults (age 35), and 2 grandparents (age 70), the average is about 33, the median is between 10 and 35 (about 22), and the mode is 10 and 35 (two modes). Three different "typical" values, three different stories! 🔑 Key Insight: There's no single "correct" measure of central tendency. The right choice depends on your data and what you want to communicate.

4.2 The Mean (Arithmetic Average)

4.2.1 Intuition

The mean is what most people call "the average." It's the balance point of the data — if the data values were weights on a number line, the mean is where the fulcrum would balance them.

4.2.2 Formal Definition

Population mean (μ — "mu"):
μ=i=1NxiN\mu = \frac{\sum_{i=1}^{N} x_i}{N}
Sample mean (x̄ — "x-bar"):
xˉ=i=1nxin\bar{x} = \frac{\sum_{i=1}^{n} x_i}{n}
Where:
  • xix_i = each individual value
  • NN = population size
  • nn = sample size
  • \sum = "sum of"
Notation alert: μ (mu) is a parameter (population). x̄ (x-bar) is a statistic (sample). The formula is the same — only the letter changes.

4.2.3 Worked Example

Scenario: Five students scored: 70, 85, 90, 65, 80. Find the mean. Solution:
xˉ=70+85+90+65+805=3905=78\bar{x} = \frac{70 + 85 + 90 + 65 + 80}{5} = \frac{390}{5} = 78
The mean score is 78.

4.2.4 Properties of the Mean

PropertyExplanationExample
Every value affects itThe mean uses all data pointsChanging any single value changes the mean
Sensitive to outliersExtreme values pull the mean toward themOne salary of ₹50 lakhs can make a company's "average salary" look much higher
Balance pointSum of deviations from mean = 0(xixˉ)=0\sum(x_i - \bar{x}) = 0
UniqueThere's exactly one mean for a datasetUnlike mode (there can be multiple)
AlgebraicCan be used in further calculationsThe mean appears in variance, correlation, etc.

4.2.5 The Weighted Mean

When different values have different weights (importance), we compute a weighted mean:
xˉw=i=1nwixii=1nwi\bar{x}_w = \frac{\sum_{i=1}^{n} w_i x_i}{\sum_{i=1}^{n} w_i}
Example: A course has two exams. Exam 1 is worth 40% and Exam 2 is worth 60%. A student scores 75 on Exam 1 and 85 on Exam 2.
xˉw=0.40×75+0.60×850.40+0.60=30+511=81\bar{x}_w = \frac{0.40 \times 75 + 0.60 \times 85}{0.40 + 0.60} = \frac{30 + 51}{1} = 81
The weighted mean is 81, which is higher than the unweighted mean of 80 because the student did better on the heavier-weighted exam.

4.3 The Median

4.3.1 Intuition

The median is the middle value when data is sorted. It's the 50th percentile — half the values are below it, half above. It's like finding the person in the middle of a line.

4.3.2 Formal Definition

For sorted data:
  • Odd n: The median is the value at position (n+1)/2(n+1)/2
  • Even n: The median is the average of the two middle values (positions n/2n/2 and n/2+1n/2 + 1)

4.3.3 Worked Examples

Example A (odd count): Scores: 65, 70, 80, 85, 90
  • Sort: ✓ already sorted
  • n = 5 (odd)
  • Position = (5+1)/2=3(5+1)/2 = 3
  • 3rd value = 80
  • Median = 80 Example B (even count): Scores: 65, 70, 80, 85, 90, 95
  • Sort: ✓ already sorted
  • n = 6 (even)
  • Positions: 6/2=36/2 = 3 and 6/2+1=46/2 + 1 = 4
  • 3rd value = 80, 4th value = 85
  • Median = (80+85)/2=82.5(80 + 85)/2 = \textbf{82.5}

4.3.4 Properties of the Median

PropertyExplanation
Robust to outliersExtreme values don't affect the median much
Only uses orderThe median only depends on the middle values
Always existsEvery dataset has a median
Not algebraicCan't use median in further calculations easily

4.4 The Mode

4.4.1 Intuition

The mode is the most frequently occurring value. It's the "fashion" of the data — the most popular value.

4.4.2 Formal Definition

The mode is the value that appears most frequently in a dataset. A dataset can have:
  • No mode: All values appear once
  • One mode (unimodal): One value appears most frequently
  • Two modes (bimodal): Two values tie for highest frequency
  • Multiple modes (multimodal): More than two values tie

4.4.3 Worked Example

Scenario: Shoe sizes sold: 7, 8, 7, 9, 8, 7, 10, 8, 7, 9
SizeFrequency
74
83
92
101
Mode = 7 (appears 4 times, more than any other)

4.4.4 Properties of the Mode

PropertyExplanation
Only measure for nominal dataFor eye colors, the mode tells us the most common color
Can be non-uniqueThere can be 0, 1, 2, or many modes
Not affected by outliersOutliers don't change the mode
Simple to findJust identify the most frequent value

4.5 Comparing Mean, Median, and Mode

(Diagram)

Relationship in Different Distribution Shapes

(Diagram) Why this relationship holds:
  • The mean is pulled toward the long tail (toward extreme values)
  • The median stays at the middle position
  • The mode stays at the peak (most common value)
ShapeOrderExample
SymmetricMean = Median = ModeHeights of adult women
Right-skewed (tail on right)Mode < Median < MeanIncome distribution (few people earn very high salaries)
Left-skewed (tail on left)Mean < Median < ModeAge at death (most people die old, few die young)

4.6 Which Measure to Use?

SituationRecommendWhy
Nominal data (colors, gender)ModeOnly valid measure
Ordinal data (ratings, ranks)Median (or mode)Mean requires equal intervals
Symmetric numerical dataMeanMost precise, uses all data
Skewed numerical dataMedianNot affected by extreme values
Bimodal dataReport both modesMean and median hide the bimodality
{text}When outliers are presentMedianMean is distorted
Need further calculationsMeanMedian isn't algebraic

4.7 The Effect of Outliers

An outlier is an extreme value that differs significantly from other observations. Example: Five startup employees earn (in ₹lakhs/year): 5, 6, 5.5, 6.5, 50 (the founder)
  • Mean: (5 + 6 + 5.5 + 6.5 + 50) / 5 = 73 / 5 = 14.6
  • Median: Sorted: 5, 5.5, 6, 6.5, 50 → 6
  • Mode: 5 (appears once... actually all values are unique except) → No clear mode Interpretation:
  • The mean says the "average" salary is ₹14.6 lakhs — but no one except the founder earns close to that!
  • The median says the middle salary is ₹6 lakhs — which reflects what most employees earn
  • The mode has no clear value If we remove the outlier (50):
  • Mean becomes (5 + 6 + 5.5 + 6.5) / 4 = 5.75
  • Median becomes (5.5 + 6) / 2 = 5.75 Without the outlier, mean and median are almost identical.
Moral: When outliers are present, the median is usually a better measure of "typical" than the mean.

4.8 Mean from a Frequency Table

When data is grouped into a frequency table, we can estimate the mean:
xˉ=i=1kfi×min\bar{x} = \frac{\sum_{i=1}^{k} f_i \times m_i}{n}
Where:
  • fif_i = frequency of class i
  • mim_i = midpoint of class i
  • nn = total frequency
  • kk = number of classes Example: Ages of participants at an event
Age RangeMidpoint (m)Frequency (f)f × m
10-1914.5572.5
20-2924.512294.0
30-3934.58276.0
Total25642.5
xˉ642.525=25.7 years\bar{x} \approx \frac{642.5}{25} = 25.7 \text{ years}
Note: This is an estimate because we've lost the exact values. The true mean of the raw data may differ slightly.

4.9 Worked Examples

Example 1: All Three Measures (Easy)

Scenario: 9 students scored: 55, 60, 65, 70, 75, 80, 85, 90, 95 Find mean, median, and mode. Solution: Mean:
xˉ=55+60+65+70+75+80+85+90+959=6759=75\bar{x} = \frac{55 + 60 + 65 + 70 + 75 + 80 + 85 + 90 + 95}{9} = \frac{675}{9} = 75
Median:
  • Sorted (already): 55, 60, 65, 70, 75, 80, 85, 90, 95
  • n = 9 (odd), position = (9+1)/2 = 5
  • 5th value = 75 Mode: All values appear exactly once → No mode Result: Mean = Median = 75. This is symmetric data.

Example 2: Outlier Effect (Medium)

Scenario: The same scores plus one student who scored 0: 0, 55, 60, 65, 70, 75, 80, 85, 90, 95 Find mean and median. Compare with Example 1. Solution: Mean:
xˉ=0+55+60+65+70+75+80+85+90+9510=67510=67.5\bar{x} = \frac{0 + 55 + 60 + 65 + 70 + 75 + 80 + 85 + 90 + 95}{10} = \frac{675}{10} = 67.5
Median:
  • Sorted: 0, 55, 60, 65, 70, 75, 80, 85, 90, 95
  • n = 10 (even), positions = 5 and 6
  • 5th = 70, 6th = 75
  • Median = (70 + 75)/2 = 72.5 Comparison:
MeasureWithout outlierWith outlierChange
Mean7567.5↓ 7.5
Median7572.5↓ 2.5
Interpretation: The outlier (0) pulled the mean down much more than the median. The median better represents the "typical" student performance.

Example 3: Skewed Income Data (Harder)

Scenario: A small company has 10 employees with monthly salaries (in ₹thousands):
20, 22, 25, 25, 28, 30, 32, 35, 38, 200 (CEO) a) Compute mean and median. b) Which better represents "typical" employee salary? c) How would you describe the skew? Solution: a) Mean:
xˉ=20+22+25+25+28+30+32+35+38+20010=45510=45.5\bar{x} = \frac{20 + 22 + 25 + 25 + 28 + 30 + 32 + 35 + 38 + 200}{10} = \frac{455}{10} = 45.5
So the mean is ₹45.5 thousand. Median:
  • Sorted: 20, 22, 25, 25, 28, 30, 32, 35, 38, 200
  • n = 10 (even), positions = 5 and 6
  • 5th = 28, 6th = 30
  • Median = (28 + 30)/2 = 29 So the median is ₹29 thousand. b) Which is more representative? The median (₹29K) is much more representative. Only the CEO (₹200K) earns more than ₹38K. The mean (₹45.5K) is inflated by the CEO's extreme salary and doesn't reflect what most employees earn. c) Skew: This is right-skewed (positive skew). Most values cluster at the low end (₹20K-₹38K), with one extreme value pulling a long tail to the right. We confirm: Mode (<25) < Median (29) < Mean (45.5).

4.10 Edge Cases & Gotchas

All Values Are the Same

If all 10 values are 5, then mean = median = mode = 5. They all agree.

Symmetric Bimodal Distribution

Values: 1, 1, 2, 2, 3, 3 (two modes: 1, 2, 3 — actually each appears twice) Actually let's use a clearer example: 1, 1, 2, 3, 4, 4
  • Mean = (1 + 1 + 2 + 3 + 4 + 4) / 6 = 15/6 = 2.5
  • Median: sorted 1, 1, 2, 3, 4, 4 → (2+3)/2 = 2.5
  • Modes: 1 and 4 (bimodal) The mean and median don't reveal the bimodality — they suggest a normal distribution when the data actually has two clusters. Always visualize!

The Median for Ordinal Data

For ordinal data (like survey responses: SD, D, N, A, SA), the median is valid. Convert to numeric codes (1-5), find the middle value, then convert back. Example: Responses: D, SA, N, A, SD, A, A, N, D, SA
  • Codes: 2, 5, 3, 4, 1, 4, 4, 3, 2, 5
  • Sorted: 1, 2, 2, 3, 3, 4, 4, 4, 5, 5
  • Median: positions 5,6 → (3+4)/2 = 3.5 → between Neutral and Agree The median response is between Neutral and Agree — a valid conclusion. The mean (3.3) would be invalid because we're assuming equal intervals.

4.11 Why This Matters

Measures of central tendency are the first thing anyone asks about data:
  • Business: "What's the average revenue per customer?"
  • Education: "What's the average test score?"
  • Healthcare: "What's the average recovery time?"
  • Policy: "What's the median income of a region?" They also form the foundation for almost every other statistical concept:
  • Variance (next topic) uses the mean
  • Correlation (Week 4) uses the mean
  • Hypothesis testing (Stats 2) uses the mean
  • Regression uses the mean Understanding which measure to use and why is the difference between good analysis and misleading analysis.

📐 Key Formulas / Concepts

MeasureDefinitionFormulaScale Validity
Population Mean (μ)Sum of all values divided by countμ=xiN\mu = \frac{\sum x_i}{N}Interval, Ratio
Sample Mean (x̄)Same formula, different notationxˉ=xin\bar{x} = \frac{\sum x_i}{n}Interval, Ratio
Weighted MeanWeighted values divided by weightsxˉw=wixiwi\bar{x}_w = \frac{\sum w_i x_i}{\sum w_i}Interval, Ratio
MedianMiddle value of sorted data(n+1)/2(n+1)/2 position if oddOrdinal, Interval, Ratio
ModeMost frequent valueLargest frequencyNominal, Ordinal, Interval, Ratio
Mean from Freq TableEstimated mean from grouped datafimin\frac{\sum f_i m_i}{n}Interval, Ratio

⚠️ Common Pitfalls

Pitfall 1: Using the Mean for Skewed Data

The mistake: Reporting the mean salary when the distribution is heavily right-skewed, making it seem like employees earn more than they do. Why it happens: The mean is the most familiar measure. People default to it. How to catch it: Check if the mean is substantially different from the median. If mean > median significantly, the data is right-skewed. Correct approach: Report the median for skewed data. If you report the mean, also report the median and note the skewness.

Pitfall 2: Forgetting the Mode Is the Only Measure for Nominal Data

The mistake: Trying to compute the mean or median of eye colors (or another nominal variable). Why it happens: Students get comfortable with mean/median and forget the scale of measurement matters. Correct approach: Only the mode is valid for nominal data. Report the most common category and its percentage.

Pitfall 3: Confusing Mean and Median

The mistake: Saying "the average" without specifying which measure, or assuming all measures of central tendency give the same result. Why it happens: In everyday language, "average" usually means the mean. People don't distinguish. Correct approach: Always specify which measure you're using. When reporting, consider whether the mean or median is more appropriate for your data.

Pitfall 4: Thinking the Mean Is Always a Value in the Dataset

The mistake: Looking at a dataset and thinking the mean must be one of the values present. Why it happens: The mode is always a data value. The median is always a data value (for odd n). The mean can be anything. Example: Data: 1, 2, 3, 4, 100. Mean = 110/5 = 22. That's not in the dataset!

📝 Practice Questions

Q1: Basic Mean Calculation
Find the mean of: 12, 15, 20, 22, 25, 28, 30
<details> <strong>Solution</strong>
Step 1: Sum = 12 + 15 + 20 + 22 + 25 + 28 + 30 = 152 Step 2: n = 7 Step 3: Mean = 152 / 7 ≈ 21.71
xˉ21.71\boxed{\bar{x} \approx 21.71}
</details> > **Q2: Median with Even Count** > > Find the median of: 3, 7, 8, 12, 15, 18, 20, 22 > > <details> <strong>Solution</strong> > > **Step 1:** Sort (already sorted). **Step 2:** n = 8 (even). **Step 3:** Position 1 = 8/2 = 4, Position 2 = 8/2 + 1 = 5. **Step 4:** 4th value = 12, 5th value = 15. **Step 5:** Median = (12 + 15) / 2 = 13.5 > > $\boxed{\text{Median} = 13.5}$ </details> > **Q3: Identifying Modes** > > Find the mode(s) for each dataset: > > a) 2, 3, 5, 3, 4, 3, 6, 3 b) 1, 2, 2, 3, 4, 4, 5, 6 c) 10, 20, 30, 40, 50 > > <details> <strong>Solution</strong> > > **a)** Value 3 appears 4 times, others appear once or twice. **Mode = 3** (unimodal) > > **b)** Values 2 and 4 each appear twice. **Modes = 2 and 4** (bimodal) > > **c)** All values appear exactly once. **No mode**. </details> > **Q4: Weighted Mean** > > A student's grades: Homework = 85 (weight 10%), Quizzes = 78 (weight 20%), Midterm = 92 (weight 30%), Final = 88 (weight 40%). Find the weighted mean. > > <details> <strong>Solution</strong> > > **Step 1:** Convert percentages to decimals. > > **Step 2:** $\bar{x}_w = \frac{0.10(85) + 0.20(78) + 0.30(92) + 0.40(88)}{0.10 + 0.20 + 0.30 + 0.40}$ > > **Step 3:** Numerator = 8.5 + 15.6 + 27.6 + 35.2 = 86.9 > > **Step 4:** Denominator = 1.0 > > **Step 5:** Weighted mean = 86.9 / 1.0 = 86.9 > > $\boxed{\bar{x}_w = 86.9}$ </details> > **Q5: Mean from Frequency Table** > >
ClassFrequency
0-104
10-208
20-306
30-402
Find the estimated mean.
<details> <strong>Solution</strong>
ClassMidpoint (m)ff × m
0-105420
10-20158120
20-30256150
30-4035270
Total20360
xˉ36020=18\bar{x} \approx \frac{360}{20} = 18
xˉ18\boxed{\bar{x} \approx 18}
</details> > **Q6: Effect of Adding a Constant** > > If you add 5 to every value in a dataset, what happens to the mean, median, and mode? > > <details> <strong>Solution</strong> > > **All three increase by 5.** > > - **Mean:** If $\bar{x} = \frac{\sum x}{n}$, then new mean $= \frac{\sum (x + 5)}{n} = \frac{\sum x + 5n}{n} = \bar{x} + 5$ > - **Median:** Every value shifts right by 5, so the middle value also shifts by 5 > - **Mode:** The most frequent value each increases by 5 > > **General rule:** Adding a constant to all data shifts all measures of central tendency by that constant. </details> > **Q7: Multiplying by a Constant** > > If you multiply every value in a dataset by 3, what happens to the mean, median, and mode? > > <details> <strong>Solution</strong> > > **All three are multiplied by 3.** > > - **Mean:** $\frac{\sum 3x}{n} = 3 \times \frac{\sum x}{n} = 3\bar{x}$ > - **Median:** Every value triples, so the middle value triples > - **Mode:** The most frequent value triples > > **General rule:** Multiplying all data by a constant multiplies all measures of central tendency by that constant. </details> > **Q8: Choosing the Right Measure** > > For each scenario, recommend a measure of central tendency and explain why: > > a) Housing prices in a city (most homes ₹30-50 lakhs, some mansions ₹10+ crores) b) Favorite color of 500 respondents c) Daily website visitors over a month d) Cancer survival times (most patients die within 2 years, some live 20+ years) > > <details> <strong>Solution</strong> > > **a) Housing prices — Median** > > - Distribution is heavily right-skewed (a few mansions pull the mean high) > - Median better represents the "typical" home price > > **b) Favorite color — Mode** > > - Nominal data — mean and median are invalid > - Mode tells us the most popular color > > **c) Daily visitors — Mean** > > - Website traffic is typically roughly symmetric day-to-day > - Mean gives the most precise estimate using all data > - (Unless there are extreme spikes — then consider median) > > **d) Cancer survival — Median** > > - Heavily right-skewed (most patients die relatively quickly, a few live much longer) > - Mean would be misleadingly high > - Median better represents "typical" survival time </details> > **Q9: Outlier Impact** > > Dataset: 10, 12, 13, 15, 16, 18, 20, 22, 25, 100 > > a) Compute the mean and median. b) Identify the outlier. c) Remove the outlier and recompute. How much did each change? > > <details> <strong>Solution</strong> > > **a) With outlier:** > > - Sum = 10 + 12 + 13 + 15 + 16 + 18 + 20 + 22 + 25 + 100 = 251 > - Mean = 251/10 = 25.1 > - Sorted: 10, 12, 13, 15, 16, 18, 20, 22, 25, 100 > - Median = (16 + 18)/2 = 17 > > **b) Outlier:** 100 (far above the rest) > > **c) Without outlier (100 removed):** > > - Sum = 151 > - n = 9 > - Mean = 151/9 ≈ 16.78 > - Sorted: 10, 12, 13, 15, 16, 18, 20, 22, 25 > - Median = 16 > > **Changes:** > >
MeasureWith outlierWithoutChange
Mean25.116.78↓ 8.32 (33% drop)
Median1716↓ 1 (6% drop)
The mean was far more affected by the single outlier than the median.
</details> > **Q10: Symmetric Distribution** > > A symmetric dataset has mean = 50 and median = 50. If the largest value increases by 20, what happens to the mean and median? > > <details> <strong>Solution</strong> > > **Mean:** Increases (by 20/n). Adding 20 to one value increases the sum by 20, so the mean increases by 20/n. > > **Median:** Stays the same (assuming the increased value was already above the median and the change doesn't affect the middle position). > > **Example with n = 5:** > > Original: 40, 45, 50, 55, 60 > > - Mean = 250/5 = 50 > - Median = 50 > > New (largest increases by 20): 40, 45, 50, 55, 80 > > - Mean = 270/5 = 54 (↑ 4) > - Median = 50 (unchanged) > > $\boxed{\text{Mean increases; Median unchanged}}$ </details> * * * ## 🔗 Cross-References - **Next topic:** [Dispersion and Percentiles](/notes/01-foundation-bsma1002-stats-1-week03-04-dispersion-percentiles) — central tendency alone isn't enough; we also need to measure spread - **Previous:** [Data Types & Scales](/notes/01-foundation-bsma1002-stats-1-week01-01-data-types-scales) — understanding which measures are valid - **Week 4 (Correlation):** The mean is used in calculating Pearson's r - **Week 9-10 (Random Variables):** Expectation (E\[X\]) is the mean of a distribution - **BSMA1004 (Stats 2):** Hypothesis testing centers on comparing means [Join Discord](https://discord.gg/gE2m4Qrdqv) [Previous**Categorical Data**](/notes/01-foundation-bsma1002-stats-1-week02-02-categorical-frequency)[Next**Dispersion & Percentiles**](/notes/01-foundation-bsma1002-stats-1-week03-04-dispersion-percentiles)
Document outline

Keep your place and jump directly to a heading.

Table of Contents
System Normal // Awaiting Context

Intelligence Hub

Navigate the knowledge graph to generate context. The Hub adapts dynamically to surface backlinks, related notes, and metadata insights.