Chapter 2
Table of contents
- Numerical Description of Data
- Comparison of Dispersion Measures
- Exercises
1. Numerical Description of Data
1.1 Measures of Central Tendency (Position)
Measures of central tendency provide a single value that represents the typical or middle value of a dataset. These measures help in understanding the center of the data distribution 1.
1.2 Arithmetic Mean
The arithmetic mean, commonly known as the average, is calculated by summing all values in a dataset and dividing by the total number of values. It is best suited for data that are additive, such as heights, ages, or temperatures 1.
- Raw Data: For N values x1,x2,…,xN, the mean xˉ is N∑i=1Nxi.
- Frequency Data: If a value xi appears ni times, and N=∑i=1kni, the mean is xˉ=N∑i=1knixi 1.
- Grouped Data (Classes): For data grouped into classes, the midpoint mi=2ai+bi of each class is used. The mean is xˉ=N∑i=1knimi 2.
Example 2.2. Arithmetic Mean - Raw Data Data: 2, 4, 6, 8 (N = 4). xˉ=42+4+6+8=420=5 2.
Example 2.3. Arithmetic Mean - Frequency Data
| Value (xi) | Frequency (ni) | nixi |
|---|---|---|
| 1 | 2 | 2 |
| 2 | 2 | 4 |
| 3 | 6 | 18 |
| 4 | 1 | 4 |
| Total | 10 | 26 |
xˉ=1026=2.6 2.
Example 2.4. Arithmetic Mean - Grouped Data
| Class | ni | mi | nimi |
|---|---|---|---|
| [10, 20[ | 4 | 15 | 60 |
| [20, 30[ | 6 | 25 | 150 |
| [30, 40[ | 8 | 35 | 280 |
| [40, 50[ | 2 | 45 | 90 |
| Total | 20 | — | 580 |
xˉ=20580=29 2.
- Properties of the Arithmetic Mean: 2.
- It uses every value in the data.
- It is sensitive to outliers.
- The sum of deviations from the mean is always zero: ∑(x−xˉ)=0.
1.3 Weighted Mean
The weighted mean is used when certain values in a dataset are considered more important than others. Each value xi is multiplied by a weight wi>0, which reflects its significance 3.
- Formula: The weighted mean is calculated as xˉw=∑i=1kwi∑i=1kwixi 3.
Example 2.7. Weighted Mean - University Marks A student's marks and their credit coefficients are: Maths (14, 3), Physics (10, 2), English (16, 1). The weighted mean mark is 3+2+1(3×14)+(2×10)+(1×16)=642+20+16=678=13 3.
1.4 Geometric Mean
The geometric mean is appropriate for data that are multiplicative in nature, such as growth rates, ratios, or index numbers. All values in the dataset must be positive 3.
- Formula: G=(∏i=1Nxi)1/N or G=Nx1⋅x2⋅⋯⋅xN 4.
- Frequency Data: G=(∏i=1kxini)1/N.
- Logarithmic Form: logG=N1∑i=1Nlogxi 3.
Example 2.9. Geometric Mean - Growth Rates A population grows by 10%, then 20%, then 50% over three years. The multipliers are 1.10, 1.20, 1.50. G=(1.10×1.20×1.50)1/3=(1.98)1/3≈1.256. The average growth rate is approximately 25.6% per year 3.
Example 2.10. Geometric Mean - Investment An investment grows by +50% one year and -50% the next year. Multipliers: 1.50 and 0.50. G=(1.50×0.50)1/2=0.75≈0.866. The average yearly rate is -13.4% (a loss), not 0% 4.
1.5 Harmonic Mean
The harmonic mean is used for rates and speeds, such as km/h or price per unit. It gives more weight to smaller values 4.
- Formula: H=∑i=1Nxi1N.
- Frequency Data: H=∑i=1kxiniN 4.
Example 2.12. Harmonic Mean - Average Speed A car travels 100 km at 50 km/h, then 100 km at 100 km/h. H=501+10012=0.02+0.012=0.032≈66.67 km/h. The arithmetic mean would be incorrect because the car spends more time at the slower speed 4.
- Ordering of the Means: For positive data, the means satisfy H≤G≤xˉ 4.
1.6 Comparison of the Four Means 4
| Mean | Formula | Best used for |
|---|---|---|
| Arithmetic | \bar{x} = \frac{\sum x_i}{N} | Everyday averages: heights, ages, grades. |
| Weighted | \bar{x}_w = \frac{\sum w_i x_i}{\sum w_i} | Averages with unequal importance (credits, prices). |
| Geometric | G = (\prod x_i)^{1/N} | Growth rates, ratios, index numbers. |
| Harmonic | H = \frac{N}{\sum \frac{1}{x_i}} | Rates and speeds (km/h, price per unit). |
1.7 The Mode (Mo)
The mode is the value that appears most frequently in a dataset. It is the only measure of central tendency that can be used for qualitative data, such as colors or brands, and a dataset can have multiple modes or no mode 5.
- Raw Data: The mode is the value with the highest count.
- Grouped Data (Equal Widths): The mode is calculated using the formula Mo=a+h⋅d1+d2d1, where a is the lower limit of the modal class, h is the class width, d1 is the difference between the modal class frequency and the previous class frequency, and d2 is the difference between the modal class frequency and the next class frequency.
- Grouped Data (Unequal Widths): When class widths differ, frequency density (di=ni/hi) is used to identify the modal class (the class with the highest density). The formula for the mode remains the same, using densities instead of frequencies for d1 and d2 5.
Example 2.16. Mode - Raw Data (single mode) Data: 1, 2, 2, 3, 3, 3, 4, 5. The value 3 appears most often (3 times), so Mo=3 5.
Example 2.17. Mode - Raw Data (two modes) Data: 2, 2, 5, 5, 7, 8. Values 2 and 5 both appear twice. The data is bimodal: Mo1=2, Mo2=5 5.
Example 2.18. Mode - Raw Data (three modes) Data: 1, 1, 2, 2, 3, 3, 4, 5, 6. Values 1, 2, and 3 appear twice each. The data is trimodal: Mo1=1, Mo2=2, Mo3=3 5.
Example 2.19. Mode - Raw Data (no mode) Data: 1, 2, 3, 4, 5. Every value appears once, so there is no mode 6.
Example 2.20. Mode - Raw Data (all frequencies equal) Data: 1, 1, 2, 2, 3, 3, 4, 4. Every value appears exactly twice. There is no mode 6.
Example 2.21. Mode - Qualitative Data Blood types of 20 patients: A, B, A, O, AB, A, O, A, B, O, O, A, B, A, AB, O, A, B, O, A.
| Blood Type | Frequency |
|---|---|
| A | 8 |
| B | 4 |
| O | 6 |
| AB | 2 |
The most frequent blood type is A, so Mo=A 6.
Example 2.22. Mode - Grouped Data (equal widths)
| Class | ni | hi | Density |
|---|---|---|---|
| [0, 10[ | 3 | 10 | 0.3 |
| [10, 20[ | 8 | 10 | 0.8 |
| [20, 30[ | 5 | 10 | 0.5 |
The modal class is [10, 20[. a=10, h=10, d1=8−3=5, d2=8−5=3. Mo=10+10⋅5+35=10+10⋅85=10+6.25=16.25 6.
Example 2.24. Mode - Grouped Data (unequal widths, case 1)
| Class | ni | hi | Density (di) |
|---|---|---|---|
| [0, 10[ | 5 | 10 | 0.5 |
| [10, 20[ | 14 | 10 | 1.4 |
| [20, 40[ | 18 | 20 | 0.9 |
| [40, 50[ | 3 | 10 | 0.3 |
The modal class is [10, 20[ with the highest density (1.4). a=10, h=10, d1=1.4−0.5=0.9, d2=1.4−0.9=0.5. Mo=10+10⋅0.9+0.50.9=10+10⋅1.40.9≈10+6.43=16.43 6 7.
- Finding the Mode from a Histogram: For equal class widths, identify the tallest bar. Draw lines connecting the top corners of the modal bar to the adjacent bars' top corners. The x-coordinate of their intersection is the mode. For unequal widths, use frequency density on the y-axis.
- Key Points for Histogram Mode:.
- Use frequency density for unequal widths.
- The modal bar has the highest density, not necessarily the highest frequency.
- The graphical method provides an approximation; the formula gives the exact value.
- The mode is pulled towards the adjacent class with the higher frequency.
- When to Use the Mode: Use the mode for the most frequent value or for qualitative data 8.
1.8 The Median (Me)
The median is the value that divides an ordered dataset into two equal halves, with 50% of the data below it and 50% above it. It is not affected by extreme values (outliers), making it robust 9.
- Raw Data (Odd N): Sort the data. The median is the value at position 2N+1.
- Raw Data (Even N): Sort the data. The median is the average of the two middle values at positions 2N and 2N+1 9.
- Grouped Data: The median is calculated using the formula Me=a+h⋅niN/2−Ni−1, where [a,b[ is the median class (the first class with cumulative frequency Ni≥N/2), h is the class width, Ni−1 is the cumulative frequency before the median class, and ni is the frequency of the median class 10.
Example 2.33. Median - Raw Data, Odd N Data: 7, 3, 9, 5, 11 (N = 5). Sorted: 3, 5, 7, 9, 11. Position = 25+1=3. Me=x(3)=7 9.
Example 2.34. Median - Raw Data, Even N Data: 4, 8, 2, 6 (N = 4). Sorted: 2, 4, 6, 8. Positions = 24=2 and 24+1=3. Me=2x(2)+x(3)=24+6=5 9.
Example 2.35. Median - Resistant to Outliers Dataset A = {2, 4, 6, 8, 10}: xˉA=6, MeA=6. Dataset B = {2, 4, 6, 8, 100}: xˉB=24, MeB=6.
The outlier 100 significantly changes the mean but not the median 9 10.
Example 2.36. Median - Grouped Data (equal widths)
| Class | ni | Ni |
|---|---|---|
| [10, 20[ | 4 | 4 |
| [20, 30[ | 6 | 10 |
| [30, 40[ | 8 | 18 |
| [40, 50[ | 2 | 20 |
| [0, 10[ | 3 | 3 |
N/2=10. The median class is [20, 30[. a=20, h=10, Ni−1=4, ni=6. Me=20+10⋅610−4=20+10⋅66=20+10=30 10.
Example 2.37. Median - Grouped Data (unequal widths)
| Class | ni | Ni | hi |
|---|---|---|---|
| [0, 10[ | 5 | 5 | 10 |
| [10, 20[ | 14 | 19 | 10 |
| [20, 40[ | 18 | 37 | 20 |
| [40, 50[ | 3 | 40 | 10 |
N/2=20. The median class is [20, 40[. a=20, h=20, Ni−1=19, ni=18. Me=20+20⋅1820−19=20+20⋅181≈20+1.11=21.11 10.
1.9 Quartiles (Q1, Q2, Q3) and IQR
Quartiles divide an ordered dataset into four equal parts. Q1 is the value below which 25% of the data falls, Q2 is the median (50%), and Q3 is the value below which 75% of the data falls.
The Interquartile Range (IQR) measures the spread of the middle 50% of the data 11 13.
- Raw Data: For k∈{1,2,3}, the position of Qk is 4k(N+1). Interpolate if the position is not an integer 11.
- Grouped Data: The formula is Qk=a+h⋅nikN/4−Ni−1, where [a,b[ is the class containing the kN/4-th individual, h is the class width, Ni−1 is the cumulative frequency before that class, and ni is the frequency of that class 12.
- Interquartile Range (IQR): IQR=Q3−Q1 13.
Example 2.41. Quartiles - Raw Data (position is integer) Data (sorted, N = 7): 2, 4, 5, 7, 9, 10, 12. Q1: position 41(7+1)=2⟹Q1=x(2)=4. Q2: position 42(7+1)=4⟹Q2=x(4)=7. Q3: position 43(7+1)=6⟹Q3=x(6)=10 11.
Example 2.42. Quartiles - Raw Data (position is not integer) Data (sorted, N = 8): 1, 3, 4, 6, 8, 9, 11, 15. Q1: position 41(8+1)=2.25. Between x(2)=3 and x(3)=4. Q1=3+0.25⋅(4−3)=3.25. Q2: position 42(8+1)=4.5. Between x(4)=6 and x(5)=8. Q2=6+0.5⋅(8−6)=7. Q3: position 43(8+1)=6.75. Between x(6)=9 and x(7)=11. Q3=9+0.75⋅(11−9)=10.5 11 12.
Example 2.43. Quartiles - Grouped Data (equal widths)
See the table in section 1.8.
N/4=5. For Q1, the class is [10, 20[. a=10, h=10, Ni−1=3, ni=8. Q1=10+10⋅85−3=10+10⋅82=10+2.5=12.5. 3N/4=15. For Q3, the class is [20, 30[. a=20, h=10, Ni−1=11, ni=6. Q3=20+10⋅615−11=20+10⋅64≈20+6.67=26.67 12.
Example 2.44. Quartiles - Grouped Data (unequal widths)
See the table in section 1.8.
N/4=10. For Q1, the class is [1
2. Comparison of Dispersion Measures
2.1 Measures of dispersion 19
This section compares various statistical measures used to quantify the spread or dispersion of data. These measures help understand how data points are distributed around the central tendency.
- Range (R): This is the simplest measure of dispersion, calculated as the difference between the maximum and minimum values in a dataset.
- It is highly sensitive to outliers, meaning extreme values can significantly affect its value.
- Variance (σ2): This measure quantifies the average squared difference of each data point from the mean.
- It uses all data points in its calculation.
- The unit of variance is the square of the data's unit.
- Standard Deviation (σ): This is the square root of the variance.
- It is the most commonly used measure of dispersion.
- Its unit is the same as the data's unit, making it easier to interpret than variance.
- Mean Absolute Deviation (MAD): This is the average of the absolute differences between each data point and the mean.
- It is relatively easy to interpret.
- It is less frequently used in theoretical contexts compared to standard deviation.
- Coefficient of Variation (CV): This is a unitless measure, calculated as the ratio of the standard deviation to the mean, often expressed as a percentage.
- It is useful for comparing the dispersion of datasets with different scales or units.
| Measure | Formula | Properties |
|---|---|---|
| Range (R) | Xmax−Xmin | Very simple, but sensitive to outliers. |
| Variance (σ2) | N1∑i=1N(xi−xˉ)2 | Uses all data; unit is squared. |
| Standard Deviation (σ) | σ2 | Same unit as data; most used measure. |
| MAD | N1∑i=1N∣xi−xˉ∣ | Easy to interpret; less used in theory. |
| CV | xˉσ×100% | Unitless; compares datasets of different scales. |
3. Exercises
3.1 Exercise 6: Statistical measures for salary data
This exercise requires calculating various statistical measures for a given dataset of salaries. The data is presented in a frequency table with salary ranges, counts (ni), and class widths (hi).
- Dataset: Salaries in thousands of DA.
- Frequency Table:
- [10, 15[: ni=6, hi=5
- [15, 20[: ni=10, hi=5
- [20, 30[: ni=18, hi=10
- [30, 50[: ni=12, hi=20
- [50, 60[: ni=4, hi=10
- Total observations: 50
The tasks are to compute:
- The mode using frequency densities.
- The median.
- The first quartile (Q1), third quartile (Q3), and interquartile range (IQR).
- The mean, variance, and standard deviation.
- The coefficient of variation.
- Draw a histogram and estimate the mode graphically 20.
3.2 Exercise 7: Mode from histogram
This exercise involves determining the mode of a dataset from its histogram, using both densities and an exact formula. The data represents 40 values distributed across different classes.
- Dataset: 40 values.
- Histogram Data:
- Class [0, 10[: ni=5, hi=10, di=0.5
- Class [10, 20[: ni=14, hi=10, di=1.4
- Class [20, 40[: ni=18, hi=20, di=0.9
- Class [40, 50[: ni=3, hi=10, di=0.3
The tasks are to:
- Identify the modal class using densities.
- Compute the mode exactly using the provided formula.
- Sketch the histogram and verify the answer graphically 20.
© 2026 Maeve. All rights reserved. This content is protected by copyright.