Sub topic 4
The Mode: The Most Frequent Value
What the Mode Measures
Assume you can count occurrences, compare numbers, and read a list of values. The mode is the value that appears most often in a data set.
For example, in the data set
2,\ 4,\ 4,\ 5,\ 7the mode is \(4\), because \(4\) appears twice and every other value appears once.
The mode describes the most common observation. Unlike the mean and median, it does not always have to be a number. For example, the mode of the colors red, blue, red, and green is red.
Finding the Mode
Count each distinct value. The value with the greatest count is the mode.
| Value | Number of occurrences |
|---|---|
| 2 | 1 |
| 4 | 2 |
| 5 | 1 |
| 7 | 1 |
The mode is \(4\).
The list does not need to be sorted to find the mode, but sorting can make repeated values easier to notice. On the GRE, a list may be intentionally unsorted.
from collections import Counter
data = [7, 4, 2, 4, 5]
counts = Counter(data)
largest_count = max(counts.values())
modes = [value for value, count in counts.items()
if count == largest_count]
print(modes) # [4]Multiple Modes and No Mode
A data set can have more than one mode. If two or more values tie for the greatest frequency, the data set is multimodal, meaning it has multiple modes.
For example:
1,\ 1,\ 2,\ 2,\ 3Both \(1\) and \(2\) appear twice. The modes are \(1\) and \(2\).
A data set can also have no mode. If every value appears exactly once, no value is more frequent than the others.
For example:
3,\ 5,\ 8,\ 11This data set has no mode. Do not choose the middle value or the largest value just because the question asks for a mode.
A Useful GRE Check
When a value is added to a data set, update its frequency before deciding whether the mode changes.
Suppose the original data set is
2,\ 3,\ 3,\ 4,\ 5.The mode is \(3\). Adding \(5\) gives
2,\ 3,\ 3,\ 4,\ 5,\ 5,so both \(3\) and \(5\) are modes. Adding another \(5\) gives \(5\) three occurrences, making \(5\) the unique mode.
Adding a value that is already the mode can strengthen its lead. Adding a different value can create a tie or a new mode.
Common Traps
- Do not assume every data set has exactly one mode.
- Do not confuse the mode with the number of times it occurs.
- Check all values before declaring a mode.
- A list can have two or more modes.
- A data set with no repeated values has no mode.
- For a frequency table, compare frequencies, not the values themselves.
Exercise
What are the modes of the data set 4, 7, 4, 2, 7, 9, 7?
Show answer
The mode is 7 because it appears three times. The value 4 appears twice, so it is not a mode.