Chapter 13 ยท Statistics

13.2 Mean Deviation for Grouped Data

Real data arrive as frequency tables. Weight each distance by its frequency โ€” $\text{M.D.}(a)=\tfrac1N\sum f_i|x_i-a|$ โ€” use class marks for class intervals, and find the median from the cumulative frequencies.

A survey of $40$ school football matches does not list forty separate scores; it says "$5$ matches had no goals, $10$ had one goal, $12$ had two โ€ฆ". A hospital reporting the ages of $600$ patients does not print $600$ ages; it gives the number of patients aged $0$โ€“$10$, $10$โ€“$20$ and so on. Most real data come grouped like this, in a frequency table, and that is how Board papers present them too.

In Section 13.1 we found mean deviations of plain lists. Here we do the same for frequency tables. The idea is simple: a value that occurs $f_i$ times contributes its distance $f_i$ times. For values given only as class intervals we do not know the individual observations, so โ€” as in Class 10 โ€” we let the class mark stand for every observation in its class. The main new skill is organising the work in a table so that the arithmetic stays short and checkable.

Discrete Frequency Distributions

In a discrete frequency distribution the observations take separate values $x_1,x_2,\dots,x_n$, occurring $f_1,f_2,\dots,f_n$ times. The total number of observations is $N=\sum f_i$, and the mean is $\bar x=\dfrac{1}{N}\sum f_ix_i$ (Class 10). Listing the data in full would repeat $x_1$ exactly $f_1$ times, $x_2$ exactly $f_2$ times, and so on; adding the distances of that long list gives $\sum f_i|x_i-a|$.

๐Ÿ“˜ Definition 13.3 โ€” Mean deviation of a frequency distribution

For values (or class marks) $x_1,\dots,x_n$ with frequencies $f_1,\dots,f_n$ and $N=\sum_{i=1}^{n}f_i$, the mean deviation about $a$ is $$\text{M.D.}(a)=\frac{1}{N}\sum_{i=1}^{n}f_i\,|x_i-a|.$$ In particular $\text{M.D.}(\bar x)=\dfrac1N\sum f_i|x_i-\bar x|$ and $\text{M.D.}(M)=\dfrac1N\sum f_i|x_i-M|$. For a continuous (class-interval) distribution, $x_i$ is the class mark (mid-point) of the $i$th class, and the result is an estimate.

To find the median of a discrete distribution, put the values in increasing order and add up the frequencies as you go โ€” the cumulative frequencies (c.f.). The c.f. of a value is the number of observations less than or equal to it, so it tells you which value occupies any given position in the ordered list.

๐Ÿงญ Mean deviation of a discrete distribution
  1. Make a table with columns $x_i$, $f_i$ and then, as needed, $f_ix_i$, c.f., $|x_i-a|$ and $f_i|x_i-a|$.
  2. About the mean: $\bar x=\dfrac{\sum f_ix_i}{N}$.
  3. About the median: if $N$ is odd, $M$ is the $\tfrac{N+1}{2}$th observation; if $N$ is even, $M$ is the mean of the $\tfrac N2$th and $\left(\tfrac N2+1\right)$th observations. The $k$th observation is the first value whose c.f. is at least $k$.
  4. Compute $f_i|x_i-a|$ in each row, add, and divide by $N$ (not by the number of rows).
โœ๏ธ Example 1 โ€” About the mean, discrete data
The numbers of goals scored in $40$ matches of a school football league were:
Goals $x_i$012345
Matches $f_i$51012832
Find the mean deviation about the mean.
Mean $\sum f_i=40$ and $\sum f_ix_i=0+10+24+24+12+10=80$, so $\bar x=\dfrac{80}{40}=2$ goals.
Table
$x_i$$f_i$$|x_i-2|$$f_i|x_i-2|$
05210
110110
21200
3818
4326
5236
Total4040
Answer $\text{M.D.}(\bar x)=\dfrac{40}{40}=1$ goal.
Check Signed deviations weighted by frequency: $5(-2)+10(-1)+0+8(1)+3(2)+2(3)=-20+20=0$ โœ“ (Theorem 13.1 for the full list of $40$ scores).
โœ๏ธ Example 2 โ€” About the median, discrete data
The shoe sizes of $50$ students in a class were:
Size $x_i$45678910
Students $f_i$461013953
Find the mean deviation about the median.
c.f. $4,\ 10,\ 20,\ 33,\ 42,\ 47,\ 50$.
Median $N=50$ is even, so $M$ is the mean of the $25$th and $26$th observations. The first c.f. that reaches $25$ is $33$, for size $7$; the $26$th is also size $7$. So $M=7$.
Distances $|x_i-7|=3,2,1,0,1,2,3$, so $f_i|x_i-7|=12,12,10,0,9,10,9$, with sum $62$.
Answer $\text{M.D.}(M)=\dfrac{62}{50}=1.24$.
Interactive 1 โ€” Frequencies as Weights

The bars show a discrete frequency distribution of $x=0,1,\dots,8$. Drag the top of any bar up or down to change its frequency (or press Play to morph through four shapes). The small numbers above the bars are the cumulative frequencies; the green line marks the median, found where the c.f. passes $\tfrac N2$, and the purple line the mean. Below the axis, each value gets a strip running from the centre $a$ to $x_i$ (red to the left, blue to the right) whose thickness is its frequency, so its area is $f_i|x_i-a|$. The total area, divided by $N$, is the mean deviation.

$N=\sum f_i$โ€”
$\bar x$ ยท $M$โ€”
$\sum f_i|x_i-a|$โ€”
mean deviationโ€”

Continuous Frequency Distributions

In a continuous frequency distribution the data are grouped into class intervals such as $10$โ€“$20$, $20$โ€“$30$, โ€ฆ with no gaps between them (by convention $20$ belongs to the class $20$โ€“$30$, not $10$โ€“$20$). We no longer know the individual observations, so we assume that every observation in a class sits at its class mark, $$x_i=\frac{\text{lower limit}+\text{upper limit}}{2},$$ and then apply Definition 13.3 exactly as for discrete data. With many classes and large numbers the products $f_ix_i$ become unpleasant; the step-deviation method from Class 10 keeps them small.

๐Ÿ“ Theorem 13.3 โ€” Step-deviation method for the mean

Let the class marks $x_i$ be equally spaced with common class width $h$, let $A$ be any one of them (the assumed mean), and put $u_i=\dfrac{x_i-A}{h}$. Then $$\bar x=A+h\cdot\frac{\sum f_iu_i}{N}.$$

Proof. From the definition of $u_i$, $x_i=A+hu_i$. Multiply by $f_i$ and add: $\sum f_ix_i=A\sum f_i+h\sum f_iu_i=AN+h\sum f_iu_i$. Divide by $N$. $\blacksquare$

Choose $A$ to be a class mark near the middle of the table: then the $u_i$ are small integers such as $-3,-2,\dots,3$ and all the arithmetic can be done in your head. The formula is exact; it is only a shortcut for $\tfrac{\sum f_ix_i}{N}$.

โœ๏ธ Example 3 โ€” About the mean, continuous data (step-deviation method)
The marks (out of $70$) of $50$ students in a test were:
Marks0โ€“1010โ€“2020โ€“3030โ€“4040โ€“5050โ€“6060โ€“70
Students361114853
Find the mean deviation about the mean.
Set up Class marks $5,15,\dots,65$; take $A=35$, $h=10$, $u_i=\dfrac{x_i-35}{10}$.
Table
Class$f_i$$x_i$$u_i$$f_iu_i$$|x_i-34|$$f_i|x_i-34|$
0โ€“1035โˆ’3โˆ’92987
10โ€“20615โˆ’2โˆ’1219114
20โ€“301125โˆ’1โˆ’11999
30โ€“40143500114
40โ€“50845181188
50โ€“6055521021105
60โ€“70365393193
Total50โˆ’5600
Mean $\bar x=35+10\times\dfrac{-5}{50}=35-1=34$ marks. (The last two columns can only be filled in after this.)
Answer $\text{M.D.}(\bar x)=\dfrac{600}{50}=12$ marks.

Mean Deviation about the Median for Grouped Data

For class-interval data the median is found with the Class 10 formula. It locates the median class from the cumulative frequencies, then assumes that the observations in that class are spread evenly across it and moves the right fraction of the way through.

๐Ÿ“ Theorem 13.4 โ€” Median of a continuous frequency distribution (recall)

Let $N=\sum f_i$. The median class is the first class whose cumulative frequency is at least $\tfrac N2$. If its lower limit is $l$, its frequency $f$, its width $h$, and the cumulative frequency of the class before it is $\text{c.f.}$, then (assuming the observations are spread evenly across the median class) $$M=l+\frac{\frac N2-\text{c.f.}}{f}\times h.$$

Why. $\text{c.f.}$ observations lie below $l$; we need $\tfrac N2-\text{c.f.}$ more of the median class's $f$ observations, that is the fraction $\tfrac{N/2-\text{c.f.}}{f}$ of the way across a class of width $h$.

โœ๏ธ Example 4 โ€” About the median, continuous data
The ages (in years) of $60$ people at a health camp were:
Age20โ€“3030โ€“4040โ€“5050โ€“6060โ€“7070โ€“80
People48142086
Find the mean deviation about the median.
c.f. $4,\ 12,\ 26,\ 46,\ 54,\ 60$. $\tfrac N2=30$; the first c.f. $\ge30$ is $46$, so the median class is $50$โ€“$60$.
Median $l=50$, $\text{c.f.}=26$, $f=20$, $h=10$: $M=50+\dfrac{30-26}{20}\times10=50+2=52$ years.
Distances Class marks $25,35,45,55,65,75$; $|x_i-52|=27,17,7,3,13,23$; $f_i|x_i-52|=108,136,98,60,104,138$, with sum $644$.
Answer $\text{M.D.}(M)=\dfrac{644}{60}=10.73$ years (to $2$ d.p.).
โœ๏ธ Example 5 โ€” Classes with gaps (inclusive classes)
A table of marks uses the classes $10$โ€“$19$, $20$โ€“$29$, โ€ฆ, $60$โ€“$69$ with frequencies $3, 5, 8, 10, 9, 5$. Find the mean deviation about the median.
Make continuous There is a gap of $1$ between $19$ and $20$. Move every lower limit down by $0.5$ and every upper limit up by $0.5$: $9.5$โ€“$19.5$, $19.5$โ€“$29.5$, โ€ฆ, $59.5$โ€“$69.5$. Now $h=10$ and the class marks $14.5, 24.5, \dots, 64.5$ are unchanged.
Median $N=40$, $\tfrac N2=20$; c.f. $3, 8, 16, 26, 35, 40$, so the median class is $39.5$โ€“$49.5$ with $\text{c.f.}=16$, $f=10$: $M=39.5+\dfrac{20-16}{10}\times10=43.5$.
Distances $|x_i-43.5|=29,19,9,1,11,21$; $f_i|x_i-43.5|=87,95,72,10,99,105$; sum $468$.
Answer $\text{M.D.}(M)=\dfrac{468}{40}=11.7$ marks. (Using the gapped limits, $l=40$ instead of $39.5$, would give the wrong median $44$.)
โœ๏ธ Example 6 โ€” A missing frequency
The distribution below has mean $25$. Find $p$ and the mean deviation about the mean.
Class0โ€“1010โ€“2020โ€“3030โ€“4040โ€“50
Frequency5$p$1285
Equation Class marks $5,15,25,35,45$: $\sum f_ix_i=25+15p+300+280+225=830+15p$ and $N=30+p$. So $\dfrac{830+15p}{30+p}=25$, i.e. $830+15p=750+25p$, giving $p=8$ and $N=38$.
Distances $|x_i-25|=20,10,0,10,20$; $f_i|x_i-25|=100,80,0,80,100$; sum $360$.
Answer $\text{M.D.}(\bar x)=\dfrac{360}{38}=9.47$ (to $2$ d.p.).
Check With $p=8$: $\sum f_ix_i=950$ and $\tfrac{950}{38}=25$ โœ“.
Interactive 2 โ€” What Grouping Costs: Raw Data versus Class Marks

The dots are $40$ actual times (in seconds) for a $200\ \text{m}$ run. Grouping them into classes of width $h$ gives the histogram. Press Play: every dot slides to its class mark and back โ€” that slide is exactly the assumption we make when we use class marks. The readouts compare the mean and the mean deviation about the mean worked out from the raw times with the values from the frequency table. Try different widths: with $h=2$ the estimates are very close, but the error does not simply grow with $h$ โ€” it depends on where the observations happen to sit inside their classes.

mean: raw ยท groupedโ€”
M.D.$(\bar x)$ rawโ€”
M.D.$(\bar x)$ groupedโ€”
errorโ€”
โš ๏ธ Common mistakes with grouped data

1. Dividing by the number of classes. Divide $\sum f_i|x_i-a|$ by $N=\sum f_i$, the number of observations.

2. Forgetting the frequencies. $\sum|x_i-\bar x|$ (without the $f_i$) treats every value as if it occurred once.

3. Using the class limit instead of the class mark. The distance of the class $30$โ€“$40$ from $\bar x$ is $|35-\bar x|$.

4. Taking c.f. of the median class itself. In $M=l+\dfrac{N/2-\text{c.f.}}{f}h$, c.f. belongs to the class before the median class, and $f$ to the median class.

5. Gapped classes. For $10$โ€“$19$, $20$โ€“$29$, โ€ฆ convert to $9.5$โ€“$19.5$, โ€ฆ before using $l$ in the median formula.

6. Discrete median between two values. When $N$ is even and the $\tfrac N2$th and $\left(\tfrac N2+1\right)$th observations are different values, the median is their mean (Exam corner E2).

Exercises

I
Discrete frequency distributions. (Give answers to $2$ decimal places where needed.)
  • 1 Mean deviation about the mean:
    $x_i$123456
    $f_i$6912742
  • 2 Mean deviation about the mean:
    $x_i$1020304050
    $f_i$4101565
  • 3 Mean deviation about the median:
    $x_i$369121518
    $f_i$3812953
  • 4 Mean deviation about the median of the shirt collar sizes (cm) sold by a shop in a day:
    Size363840424446
    Shirts49151172
  • 5 Mean deviation about the median of the numbers of spelling mistakes in $35$ essays:
    Mistakes01234
    Essays912743
  • 6 The distribution $x_i: 2, 4, 6, 8, 10$ with $f_i: 5, p, 10, 6, 4$ has mean $6$. Find $p$ and the mean deviation about the mean.
  • 7 Every frequency in a discrete distribution is doubled (the values stay the same). What happens to the mean, the median and the mean deviation about the mean? Explain.
1 $N=40$, $\sum f_ix_i=6+18+36+28+20+12=120$, $\bar x=3$. $f_i|x_i-3|=12,9,0,7,8,6$; sum $42$; M.D. $=\tfrac{42}{40}=1.05$.
2 $N=40$, $\sum f_ix_i=40+200+450+240+250=1180$, $\bar x=29.5$. $f_i|x_i-29.5|=78,95,7.5,63,102.5$; sum $346$; M.D. $=\tfrac{346}{40}=8.65$.
3 $N=40$; c.f. $3,11,23,\dots$; the $20$th and $21$st observations are both $9$, so $M=9$. $f_i|x_i-9|=18,24,0,27,30,27$; sum $126$; M.D. $=\tfrac{126}{40}=3.15$.
4 $N=48$; c.f. $4,13,28,\dots$; the $24$th and $25$th are both $40$, so $M=40$. $f_i|x_i-40|=16,18,0,22,28,12$; sum $96$; M.D. $=\tfrac{96}{48}=2$ cm.
5 $N=35$ (odd): $M$ is the $18$th observation; c.f. $9,21,\dots$, so $M=1$. $f_i|x_i-1|=9,0,7,8,9$; sum $33$; M.D. $=\tfrac{33}{35}=0.94$.
6 $\sum f_ix_i=158+4p$, $N=25+p$; $158+4p=6(25+p)$ gives $p=4$, $N=29$. $f_i|x_i-6|=20,8,0,12,16$; sum $56$; M.D. $=\tfrac{56}{29}=1.93$.
7 All three are unchanged. $N$ and every $\sum f_i(\dots)$ double, so the quotients $\tfrac{\sum f_ix_i}{N}$ and $\tfrac{\sum f_i|x_i-\bar x|}{N}$ stay the same; and the median, which depends only on the proportion of the data at each value, stays put too.
II
Continuous distributions: mean deviation about the mean (use class marks; the step-deviation method is recommended).
  • 1
    Class0โ€“1010โ€“2020โ€“3030โ€“4040โ€“50
    $f_i$6816155
  • 2 Daily wages of $50$ workers:
    Wage (โ‚น)100โ€“200200โ€“300300โ€“400400โ€“500500โ€“600
    Workers8122064
  • 3 Times of $40$ students for a $100\ \text{m}$ run:
    Time (s)12โ€“1414โ€“1616โ€“1818โ€“2020โ€“22
    Students4101484
  • 4 Ages of $100$ residents of a housing society:
    Age0โ€“2020โ€“4040โ€“6060โ€“80
    Residents15253525
  • 5 The distribution below has mean $8$. Find $k$ and the mean deviation about the mean.
    Class0โ€“44โ€“88โ€“1212โ€“16
    $f_i$3$k$74
  • 6
    Class0โ€“88โ€“1616โ€“2424โ€“3232โ€“40
    $f_i$591385
1 $x_i=5,\dots,45$; $A=25$, $h=10$, $u_i=-2,\dots,2$: $\sum f_iu_i=-12-8+0+15+10=5$, $\bar x=25+10\cdot\tfrac{5}{50}=26$. $f_i|x_i-26|=126,88,16,135,95$; sum $460$; M.D. $=9.2$.
2 $x_i=150,\dots,550$; $A=350$, $h=100$: $\sum f_iu_i=-16-12+0+6+8=-14$, $\bar x=350-100\cdot\tfrac{14}{50}=\text{โ‚น}\,322$. $f_i|x_i-322|=1376,864,560,768,912$; sum $4480$; M.D. $=\text{โ‚น}\,89.60$.
3 $x_i=13,\dots,21$; $A=17$, $h=2$: $\sum f_iu_i=-8-10+0+8+8=-2$, $\bar x=17-2\cdot\tfrac{2}{40}=16.9$ s. $f_i|x_i-16.9|=15.6,19,1.4,16.8,16.4$; sum $69.2$; M.D. $=1.73$ s.
4 $x_i=10,30,50,70$: $\sum f_ix_i=4400$, $\bar x=44$ years. $f_i|x_i-44|=510,350,210,650$; sum $1720$; M.D. $=17.2$ years.
5 $x_i=2,6,10,14$: $\sum f_ix_i=132+6k$, $N=14+k$; $132+6k=8(14+k)$ gives $k=10$, $N=24$. $f_i|x_i-8|=18,20,14,24$; sum $76$; M.D. $=\tfrac{76}{24}=3.17$.
6 $x_i=4,12,20,28,36$; $A=20$, $h=8$: $\sum f_iu_i=-10-9+0+8+10=-1$, $\bar x=20-\tfrac{8}{40}=19.8$. $f_i|x_i-19.8|=79,70.2,2.6,65.6,81$; sum $298.4$; M.D. $=7.46$.
III
Continuous distributions: mean deviation about the median.
  • 1
    Class0โ€“1010โ€“2020โ€“3030โ€“4040โ€“5050โ€“60
    $f_i$48102053
  • 2 Weekly hours of self-study of $50$ students:
    Hours0โ€“55โ€“1010โ€“1515โ€“2020โ€“25
    Students6920105
  • 3 Marks (inclusive classes):
    Marks1โ€“1011โ€“2021โ€“3031โ€“4041โ€“50
    Students571684
  • 4 Ages of $80$ members of a public library:
    Age10โ€“2020โ€“3030โ€“4040โ€“5050โ€“6060โ€“70
    Members6122025125
  • 5 For the self-study data of part 2, find the mean and the mean deviation about the mean, and compare with your answer to part 2.
  • 6 For the classes $0$โ€“$10$, โ€ฆ, $40$โ€“$50$ with frequencies $5, 10, 10, 15, 10$, the cumulative frequency reaches $\tfrac N2$ exactly at the end of a class. Find the median using the class $20$โ€“$30$, and again using the class $30$โ€“$40$. Then find the mean deviation about the median.
1 $N=50$, c.f. $4,12,22,42,\dots$; median class $30$โ€“$40$: $M=30+\tfrac{25-22}{20}\times10=31.5$. $f_i|x_i-31.5|=106,132,65,70,67.5,70.5$; sum $511$; M.D. $=10.22$.
2 c.f. $6,15,35,\dots$; median class $10$โ€“$15$: $M=10+\tfrac{25-15}{20}\times5=12.5$ h. $f_i|x_i-12.5|=60,45,0,50,50$; sum $205$; M.D. $=4.1$ h.
3 Classes $0.5$โ€“$10.5$, โ€ฆ; c.f. $5,12,28,\dots$; $\tfrac N2=20$; median class $20.5$โ€“$30.5$: $M=20.5+\tfrac{20-12}{16}\times10=25.5$. Class marks $5.5,15.5,\dots$; $f_i|x_i-25.5|=100,70,0,80,80$; sum $330$; M.D. $=8.25$.
4 $N=80$, c.f. $6,18,38,63,\dots$; median class $40$โ€“$50$: $M=40+\tfrac{40-38}{25}\times10=40.8$ years. $f_i|x_i-40.8|=154.8,189.6,116,105,170.4,121$; sum $856.8$; M.D. $=10.71$ years.
5 $\sum f_ix_i=15+67.5+250+175+112.5=620$, $\bar x=12.4$ h. $f_i|x_i-12.4|=59.4,44.1,2,51,50.5$; sum $207$; M.D.$(\bar x)=4.14$ h โ€” slightly more than M.D.$(M)=4.1$ h, as Theorem 13.2 leads us to expect.
6 c.f. $5,15,25,40,50$, $\tfrac N2=25$. Class $20$โ€“$30$: $20+\tfrac{25-15}{10}\times10=30$; class $30$โ€“$40$: $30+\tfrac{25-25}{15}\times10=30$. Both give $M=30$. $f_i|x_i-30|=125,150,50,75,150$; sum $550$; M.D. $=11$.
IV
Applications and reasoning.
  • 1 A pizza outlet recorded the delivery times of $40$ orders: $10$โ€“$20$ min: $6$; $20$โ€“$30$ min: $18$; $30$โ€“$40$ min: $12$; $40$โ€“$50$ min: $4$. Find the mean delivery time and the mean deviation about it.
  • 2 A bowler's wickets in $30$ matches: $0$ wickets in $5$ matches, $1$ in $7$, $2$ in $9$, $3$ in $5$, $4$ in $3$ and $5$ in $1$. Find the mean deviation about the mean and about the median. Which is smaller?
  • 3 The lifetimes of $50$ LED bulbs in a test were: $600$โ€“$700$ h: $5$; $700$โ€“$800$ h: $10$; $800$โ€“$900$ h: $18$; $900$โ€“$1000$ h: $12$; $1000$โ€“$1100$ h: $5$. Find the mean lifetime and the mean deviation about the mean.
  • 4 Explain why a mean deviation computed from a class-interval table with class marks is only an estimate. When would it be exact?
  • 5 The marks of $30$ students were: $0$โ€“$10$: $2$; $10$โ€“$20$: $5$; $20$โ€“$30$: $10$; $30$โ€“$40$: $8$; $40$โ€“$50$: $5$. Find the median and the mean deviation about the median.
  • 6 In a survey, $40$ students reported their numbers of siblings: $0$ siblings: $8$; $1$: $16$; $2$: $10$; $3$: $4$; $4$: $2$. Find both mean deviations (about the mean and about the median).
  • 7 A government report on household incomes gives a median income and the mean deviation about the median, rather than the mean and the mean deviation about the mean. Give two reasons why this is sensible.
1 $x_i=15,25,35,45$: $\sum f_ix_i=90+450+420+180=1140$, $\bar x=28.5$ min. $f_i|x_i-28.5|=81,63,78,66$; sum $288$; M.D. $=7.2$ min.
2 $\sum f_ix_i=0+7+18+15+12+5=57$, $\bar x=1.9$; $\sum f_i|x_i-1.9|=9.5+6.3+0.9+5.5+6.3+3.1=31.6$, M.D.$(\bar x)=\tfrac{31.6}{30}=1.05$. c.f. $5,12,21,\dots$: the $15$th and $16$th observations are $2$, so $M=2$; $\sum f_i|x_i-2|=10+7+0+5+6+3=31$, M.D.$(M)=\tfrac{31}{30}=1.03$ โ€” smaller.
3 $A=850$, $h=100$: $\sum f_iu_i=-10-10+0+12+10=2$, $\bar x=850+100\cdot\tfrac{2}{50}=854$ h. $f_i|x_i-854|=1020,1040,72,1152,980$; sum $4264$; M.D. $=85.28$ h.
4 We replace every observation by its class mark, so each true distance $|x-\bar x|$ is replaced by $|\text{class mark}-\bar x|$, which may be larger or smaller. The result is exact only if every observation in each class actually equals the class mark (Interactive 2 shows how big the error can be).
5 c.f. $2,7,17,\dots$; median class $20$โ€“$30$: $M=20+\tfrac{15-7}{10}\times10=28$. $f_i|x_i-28|=46,65,30,56,85$; sum $282$; M.D. $=\tfrac{282}{30}=9.4$.
6 $\bar x=\tfrac{56}{40}=1.4$; $\sum f_i|x_i-1.4|=11.2+6.4+6+6.4+5.2=35.2$, M.D.$(\bar x)=0.88$. c.f. $8,24,\dots$, so the $20$th and $21$st are $1$ and $M=1$; $\sum f_i|x_i-1|=8+0+10+8+6=32$, M.D.$(M)=0.8$.
7 (i) Incomes have a long tail of a few very high values; these pull the mean far above what a typical household earns, but hardly move the median. (ii) The mean deviation is smallest about the median (Theorem 13.2), so about the median it gives the most honest "typical distance" from the centre.
๐ŸŽฏ Exam corner Board ยท 1 markBoard ยท 3 marksBoard ยท 5 marksBoard ยท Case studyJEE Main

How this is examined: Board papers set a frequency table (discrete, or with class intervals) and ask for the mean deviation about the mean or the median, set out in columns; 1-mark items test whether you divide by $N$ and weight by $f_i$. Case studies often use inclusive classes. JEE Main uses distributions with a pattern (binomial-looking frequencies, "value $k$ occurs $k$ times") so the sums can be done quickly.

E1. Board ยท 1 mark For the distribution $x_i: 1, 2, 3$ with $f_i: 2, 6, 2$, the mean deviation about the mean is (A) $0.4$   (B) $0.67$   (C) $4$   (D) $2$

Idea $N=10$, $\bar x=\tfrac{2+12+6}{10}=2$; $\sum f_i|x_i-2|=2+0+2=4$; M.D. $=\tfrac4{10}=0.4$.
Trap (B) ignores the frequencies ($\tfrac{1+0+1}{3}$); (C) forgets to divide by $N$; (D) is the mean.
Answer (A).

E2. Board ยท 3 marks Find the mean deviation about the median of the distribution below.

$x_i$51015202530
$f_i$4791163
Median $N=40$; c.f. $4,11,20,31,37,40$. The $20$th observation is $15$ (c.f. of $15$ is exactly $20$) and the $21$st is $20$. So $M=\dfrac{15+20}{2}=17.5$. (1 mark)
Distances $|x_i-17.5|=12.5,7.5,2.5,2.5,7.5,12.5$; $f_i|x_i-17.5|=50,52.5,22.5,27.5,45,37.5$; sum $235$. (1 mark)
Answer $\text{M.D.}(M)=\dfrac{235}{40}=5.875$. (1 mark)
Trap Taking $M=15$ ("the first c.f. reaching $20$") misses that the $21$st observation is already $20$.

E3. Board ยท 5 marks Find the mean deviation about the mean for the ages of $60$ people given below.

Age0โ€“1010โ€“2020โ€“3030โ€“4040โ€“5050โ€“6060โ€“70
People4712161164
Set up Class marks $5,15,\dots,65$; $A=35$, $h=10$, $u_i=-3,\dots,3$. (1 mark)
Mean $f_iu_i=-12,-14,-12,0,11,12,12$; $\sum f_iu_i=-3$; $\bar x=35+10\cdot\tfrac{-3}{60}=34.5$ years. (1 mark)
Distances $|x_i-34.5|=29.5,19.5,9.5,0.5,10.5,20.5,30.5$. (1 mark)
Products $f_i|x_i-34.5|=118,136.5,114,8,115.5,123,122$; sum $737$. (1 mark)
Answer $\text{M.D.}(\bar x)=\dfrac{737}{60}=12.28$ years (to $2$ d.p.). (1 mark)

E4. Board ยท Case study A metro company surveyed $50$ commuters about their journey times (in minutes): $1$โ€“$10$: $6$; $11$โ€“$20$: $14$; $21$โ€“$30$: $20$; $31$โ€“$40$: $6$; $41$โ€“$50$: $4$. (i) Rewrite the classes so that they are continuous. (1 mark) (ii) Find the median journey time. (1 mark) (iii) Find the mean deviation about the median. (2 marks)

(i) $0.5$โ€“$10.5$, $10.5$โ€“$20.5$, $20.5$โ€“$30.5$, $30.5$โ€“$40.5$, $40.5$โ€“$50.5$. (1 mark)
(ii) c.f. $6,20,40,\dots$; $\tfrac N2=25$; median class $20.5$โ€“$30.5$: $M=20.5+\dfrac{25-20}{20}\times10=23$ min. (1 mark)
(iii) set-up Class marks $5.5,15.5,25.5,35.5,45.5$; $|x_i-23|=17.5,7.5,2.5,12.5,22.5$. (1 mark)
(iii) answer $f_i|x_i-23|=105,105,50,75,90$; sum $425$; $\text{M.D.}(M)=\dfrac{425}{50}=8.5$ min. (1 mark)

E5. JEE Main The values $2, 4, 6, 8, 10$ occur with frequencies $1, 4, 6, 4, 1$. The mean deviation about the mean is (A) $1.5$   (B) $2.4$   (C) $1.2$   (D) $3$

Idea The frequencies are symmetric about the middle value, so $\bar x=6$ (and $M=6$). $N=16$.
Sum $\sum f_i|x_i-6|=1(4)+4(2)+6(0)+4(2)+1(4)=24$; M.D. $=\tfrac{24}{16}=1.5$.
Trap (B) $=\tfrac{4+2+0+2+4}{5}$ ignores the frequencies.
Answer (A). (The frequencies are the binomial coefficients ${}^4C_r$ of Chapter 7.)

E6. JEE Main Numerical answer. In a data set the value $k$ occurs exactly $k$ times, for $k=1,2,3,4$. If $m$ is the mean deviation about the mean, find $10m$.

Mean $N=1+2+3+4=10$, $\sum f_ix_i=1+4+9+16=30$, $\bar x=3$.
Sum $\sum f_i|x_i-3|=1(2)+2(1)+3(0)+4(1)=8$, so $m=\tfrac{8}{10}=0.8$.
Answer $10m=8$.
๐Ÿ”ฌ Researchโ€“Teaching NexusMini project ยท about 1 hour

Research question. How spread out are the journey times of students in your school โ€” and how much information is lost when the data are put into a frequency table?

Why it matters. City transport planners in Delhi, London or Singapore decide bus routes and school timings from surveys of journey times, and they almost always publish them as grouped tables. Knowing how much a grouped mean deviation can differ from the true one tells you how far to trust such reports.

What to do.

  1. Ask at least $40$ students (several classes) for their usual journey time to school in minutes. Keep the raw list.
  2. Compute the mean, the median, $\text{M.D.}(\bar x)$ and $\text{M.D.}(M)$ from the raw list (a spreadsheet's AVERAGE, MEDIAN and ABS functions help).
  3. Group the data in classes of width $5$ min, then of width $10$ min and $15$ min. For each table compute the same four statistics using class marks and Theorem 13.4.
  4. Tabulate the errors (grouped minus raw). Which statistic is most affected by grouping? Does the error grow steadily with the class width?

Tools: A class survey sheet, a spreadsheet or calculator

Hand in: The raw data, the three frequency tables, a table of all the statistics and their errors, a histogram for width $5$, and a paragraph recommending a class width for reporting such data.

Going further. Repeat step 3 with the same width but the classes shifted (e.g. $2.5$โ€“$7.5$, $7.5$โ€“$12.5$, โ€ฆ instead of $0$โ€“$5$, $5$โ€“$10$, โ€ฆ). Does the choice of class boundaries matter as much as the width?

Instructor note: journey-time data are usually skewed to the right (a few long journeys), so the mean exceeds the median and $\text{M.D.}(\bar x)\gt\text{M.D.}(M)$ โ€” a good link to Theorem 13.2. With $40$โ€“$100$ observations the grouping errors for width $5$ are typically well under a minute, and they need not grow steadily with the width; shifting the class boundaries can change them as much as changing the width, which Interactive 2 also shows.

๐Ÿงช Self-check quiz

0/5 correct

Q1. In $\text{M.D.}(\bar x)=\dfrac1N\sum f_i|x_i-\bar x|$ for a frequency table, $N$ is

Q2. For $x_i: 2, 4, 6$ with $f_i: 1, 2, 1$, the mean deviation about the mean is

Q3. Before using the median formula, the inclusive class $11$โ€“$20$ (in a table with classes $1$โ€“$10$, $11$โ€“$20$, โ€ฆ) should be written as

Q4. For a distribution with $N=40$, the median class is $30$โ€“$40$, the cumulative frequency before it is $14$ and its frequency is $12$. The median is

Q5. In the step-deviation method, $A=35$, $h=10$, $N=50$ and $\sum f_iu_i=-5$. The mean is