Learning Objectives

Terminology:

·       Range

·       Interquartile range (IQR)

·       Variance, standard deviation

·       Outliers (atypical values), box plot (box-and-whisker plot)

Knowledge and Skills:

·       Calculate measures of dispersion (variability) for sample datasets: range, interquartile range, variance, and standard deviation.

·       Understand and explain the practical significance of dispersion measures in evaluating data stability, variability, and uniformity.

·       Detect and process outliers in a dataset using mathematical criteria and box plots.

Range and Interquartile Range

a) Range

Definition: The range of a dataset, denoted by RR, is the difference between the maximum value (x_max⁡x\_{\max}) and the minimum value (x_min⁡x\_{\min}): R=x_max⁡−x_min⁡R = x\_{\max} - x\_{\min}

Statistical Meaning: The range measures the total spread of a dataset. A larger range indicates that the data are more dispersed (less consistent, less uniform).

Remarks: The advantage of the range is its computational simplicity and intuitive appeal; however, it only takes into account the two extreme values (minimum and maximum) and completely ignores all other data points. Consequently, it is highly sensitive to outliers.

Example 1: Math semester exam scores for Group 1 and Group 2 in class 10A are recorded as follows: Group 1: 7, 8, 8, 9, 8, 8, 8. Group 2: 10, 6, 8, 9, 9, 7, 8, 7. a) Do the two groups have the same mean score? b) Compute the range for each group. Based on this measure, which group displays more consistent academic performance?

Solution for Example 1: • a) Mean score of Group 1: x‾_1=7+8⋅5+97=567=8\overline{x}\_1 = \frac{7 + 8 \cdot 5 + 9}{7} = \frac{56}{7} = 8.   Mean score of Group 2: x‾_2=10+6+8⋅2+9⋅2+7⋅28=648=8\overline{x}\_2 = \frac{10 + 6 + 8 \cdot 2 + 9 \cdot 2 + 7 \cdot 2}{8} = \frac{64}{8} = 8.   Thus, both groups have the same mean score (equal to 8). • b) Range of Group 1: R1=9−7=2R_1 = 9 - 7 = 2.   Range of Group 2: R2=10−6=4R_2 = 10 - 6 = 4.   Since R1<R2R_1 < R_2, Group 1 demonstrates more consistent and uniform academic performance than Group 2.

Practice 1: The following dataset shows the heights (in cm) of students in a study group: 163, 159, 172, 167, 165, 168, 170, 161. Compute the range of this dataset.

Solution for Practice 1: • The maximum value is x_max⁡=172 cmx\_{\max} = 172\text{ cm}, and the minimum value is x_min⁡=159 cmx\_{\min} = 159\text{ cm}. • The range is: R=x_max⁡−x_min⁡=172−159=13 (cm).R = x\_{\max} - x\_{\min} = 172 - 159 = 13\text{ (cm)}.

b) Interquartile Range

Definition: The interquartile range (IQR), denoted by ΔQ\Delta_Q, is the difference between the third quartile (Q3Q_3) and the first quartile (Q1Q_1): ΔQ=Q3−Q1\Delta_Q = Q_3 - Q_1

Nature and Statistical Meaning: • In essence, the interquartile range represents the range of the central 50%50\% of the ordered dataset. • The IQR measures the dispersion of the middle half of the distribution and is resistant (robust) to outliers at either extreme. • A larger value of ΔQ\Delta_Q indicates greater spread within the central portion of the data.

Example 2: The following data record the number of empty seats at a cinema across 9 days: 7, 8, 22, 20, 15, 18, 19, 13, 11. Find the interquartile range for this dataset.

Solution for Example 2: • Arrange the observations in non-decreasing order (n=9n = 9): 7, 8, 11, 13, 15, 18, 19, 20, 22. • The median is the 5th observation: Q2=15Q_2 = 15. • The lower half consists of 4 values: 7, 8, 11, 13. The first quartile is Q1=8+112=9.5Q_1 = \frac{8 + 11}{2} = 9.5. • The upper half consists of 4 values: 18, 19, 20, 22. The third quartile is Q3=19+202=19.5Q_3 = \frac{19 + 20}{2} = 19.5. • The interquartile range is: ΔQ=Q3−Q1=19.5−9.5=10.\Delta_Q = Q_3 - Q_1 = 19.5 - 9.5 = 10.

Practice 2: The following dataset gives the number of tracks per album in An’s music collection: 12, 7, 10, 9, 12, 9, 10, 11, 10, 14. Find the interquartile range for this dataset.

Solution for Practice 2: • Arrange the data in non-decreasing order (n=10n = 10): 7, 9, 9, 10, 10, 10, 11, 12, 12, 14. • The median is the arithmetic mean of the 5th and 6th values: Q2=10+102=10Q_2 = \frac{10 + 10}{2} = 10. • The lower half contains 5 values (7, 9, 9, 10, 10); its median is the middle value, so Q1=9Q_1 = 9. • The upper half contains 5 values (10, 11, 12, 12, 14); its median is the middle value, so Q3=12Q_3 = 12. • The interquartile range is: ΔQ=Q3−Q1=12−9=3.\Delta_Q = Q_3 - Q_1 = 12 - 9 = 3.

Variance and Standard Deviation

a) Formulas for Variance and Standard Deviation

Concepts: For a dataset x1,x2,…,xnx_1, x_2, \dots, x_n with mean x‾\overline{x}: • The difference (xi−x‾)(x_i - \overline{x}) is called the deviation of the observation xix_i from the mean. • The sample variance, denoted by s2s^2, is the mean of the squared deviations: s2=(x1−x‾)2+(x2−x‾)2+⋯+(xn−x‾)2ns^2 = \frac{(x_1 - \overline{x})^2 + (x_2 - \overline{x})^2 + \dots + (x_n - \overline{x})^2}{n} When data are grouped in a frequency table with frequencies m1,m2,…,mkm_1, m_2, \dots, m_k: s2=m1(x1−x‾)2+m2(x2−x‾)2+⋯+mk(xk−x‾)2ns^2 = \frac{m_1(x_1 - \overline{x})^2 + m_2(x_2 - \overline{x})^2 + \dots + m_k(x_k - \overline{x})^2}{n} • The standard deviation, denoted by ss, is the non-negative square root of the variance: s=s2s = \sqrt{s^2}

Statistical Meaning: Variance and standard deviation quantify the degree of dispersion of all observations around the mean. A smaller variance or standard deviation indicates that data points are clustered closely around the mean (indicating greater consistency and stability). Standard deviation shares the same unit of measurement as the original data, providing direct physical and practical interpretability.

b) Examples and Practice on Variance and Standard Deviation

Example 3: The following dataset shows the class sizes of 5 tenth-grade classes at a high school: 43, 45, 46, 41, 40. Find the variance and standard deviation.

Solution for Example 3: • Mean: x‾=43+45+46+41+405=43\overline{x} = \frac{43 + 45 + 46 + 41 + 40}{5} = 43. • Calculation of squared deviations:   + (43−43)2=02=0(43 - 43)^2 = 0^2 = 0   + (45−43)2=22=4(45 - 43)^2 = 2^2 = 4   + (46−43)2=32=9(46 - 43)^2 = 3^2 = 9   + (41−43)2=(−2)2=4(41 - 43)^2 = (-2)^2 = 4   + (40−43)2=(−3)2=9(40 - 43)^2 = (-3)^2 = 9   Sum of squared deviations: 0+4+9+4+9=260 + 4 + 9 + 4 + 9 = 26. • Variance: s2=265=5.2s^2 = \frac{26}{5} = 5.2. • Standard deviation: s=5.2≈2.28s = \sqrt{5.2} \approx 2.28.

Practice 3: Using a digital timer with resolution of 0.001 s, the free-fall time of an object was measured 7 times: 0.398, 0.399, 0.408, 0.410, 0.406, 0.405, 0.402 (seconds). Compute the variance and standard deviation. What does this indicate about the precision of the experiment?

Solution for Practice 3: • Mean time: x‾=0.398+0.399+0.408+0.410+0.406+0.405+0.4027=2.8287=0.404 (seconds).\overline{x} = \frac{0.398 + 0.399 + 0.408 + 0.410 + 0.406 + 0.405 + 0.402}{7} = \frac{2.828}{7} = 0.404\text{ (seconds)}. • Sum of squared deviations: ∑(xi−x‾)2=(0.398−0.404)2+(0.399−0.404)2+(0.408−0.404)2+(0.410−0.404)2+(0.406−0.404)2+(0.405−0.404)2+(0.402−0.404)2\sum (x_i - \overline{x})^2 = (0.398 - 0.404)^2 + (0.399 - 0.404)^2 + (0.408 - 0.404)^2 + (0.410 - 0.404)^2 + (0.406 - 0.404)^2 + (0.405 - 0.404)^2 + (0.402 - 0.404)^2 =(−0.006)2+(−0.005)2+(0.004)2+(0.006)2+(0.002)2+(0.001)2+(−0.002)2= (-0.006)^2 + (-0.005)^2 + (0.004)^2 + (0.006)^2 + (0.002)^2 + (0.001)^2 + (-0.002)^2 =0.000036+0.000025+0.000016+0.000036+0.000004+0.000001+0.000004=0.000122.= 0.000036 + 0.000025 + 0.000016 + 0.000036 + 0.000004 + 0.000001 + 0.000004 = 0.000122. • Variance: s2=0.0001227≈0.00001743 (s2)s^2 = \frac{0.000122}{7} \approx 0.00001743\text{ (s}^2). • Standard deviation: s=s2≈0.00417 (seconds)s = \sqrt{s^2} \approx 0.00417\text{ (seconds)}. • Evaluation: The standard deviation is very small (s≈0.004 ss \approx 0.004\text{ s}), indicating that the measurements are tightly clustered around the mean value. This demonstrates high repeatability and excellent experimental precision.

Detecting Outliers Using Box Plots

a) Mathematical Criteria for Outlier Detection

IQR Criterion for Outlier Detection (Tukey’s Fences): In a dataset, an observation xx is classified as an outlier if it satisfies either of the following conditions: • x<Q1−1.5⋅ΔQx < Q_1 - 1.5 \cdot \Delta_Q (lower outlier) • x>Q3+1.5⋅ΔQx > Q_3 + 1.5 \cdot \Delta_Q (upper outlier) where ΔQ=Q3−Q1\Delta_Q = Q_3 - Q_1 is the interquartile range.

Statistical Significance: A box plot visually summarizes the five-number summary (Minimum, Q1,Q2,Q3Q_1, Q_2, Q_3, Maximum) and provides an effective tool for identifying recording errors, instrumentation anomalies, or genuine extreme phenomena.

b) Examples and Practice on Outlier Detection

Example 4: Sodium content (mg/100 g cereal) in a sample of breakfast cereals: 0, 340, 70, 140, 200, 180, 210, 150, 100, 130, 140, 180, 190, 160, 290, 50, 220, 180, 200, 210. Identify any outliers using the box plot criteria.

Solution for Example 4: • From the ordered dataset of 20 values, we have: Q1=135Q_1 = 135 and Q3=205Q_3 = 205. • Interquartile range: ΔQ=Q3−Q1=205−135=70\Delta_Q = Q_3 - Q_1 = 205 - 135 = 70. • Outlier boundaries (fences):   + Lower fence: Q1−1.5⋅ΔQ=135−1.5⋅70=135−105=30Q_1 - 1.5 \cdot \Delta_Q = 135 - 1.5 \cdot 70 = 135 - 105 = 30.   + Upper fence: Q3+1.5⋅ΔQ=205+1.5⋅70=205+105=310Q_3 + 1.5 \cdot \Delta_Q = 205 + 1.5 \cdot 70 = 205 + 105 = 310. • Conclusion: The dataset contains two outliers: 0 mg0\text{ mg} (since 0<300 < 30) and 340 mg340\text{ mg} (since 340>310340 > 310).

Practice 4: A dataset has a first quartile of 5656 and a third quartile of 8484. Determine whether either of the values 1010 or 100100 is considered an outlier.

Solution for Practice 4: • Given: Q1=56Q_1 = 56, Q3=84Q_3 = 84. • Interquartile range: ΔQ=Q3−Q1=84−56=28\Delta_Q = Q_3 - Q_1 = 84 - 56 = 28. • Lower fence: Q1−1.5⋅ΔQ=56−1.5⋅28=56−42=14Q_1 - 1.5 \cdot \Delta_Q = 56 - 1.5 \cdot 28 = 56 - 42 = 14. • Upper fence: Q3+1.5⋅ΔQ=84+1.5⋅28=84+42=126Q_3 + 1.5 \cdot \Delta_Q = 84 + 1.5 \cdot 28 = 84 + 42 = 126. • Comparison: The value 10<1410 < 14, so 1010 is an outlier. The value 100100 lies within [14;126][14; 126], so it is not an outlier.

Applications and Exercises

a) Conceptual and Theoretical Exercises

Exercise 5.11: State whether each of the following statements is True or False: (1) If data values are more concentrated around the mean, the standard deviation is larger. (2) The range uses only information from the maximum and minimum values, ignoring all other data points. (3) The interquartile range utilizes information from the maximum and minimum values. (4) The interquartile range is the range of the lower half of the ordered dataset. (5) All measures of dispersion are non-negative.

Solution for Exercise 5.11: • (1) FALSE. When data values cluster more tightly around the mean, deviations (xi−x‾)(x_i - \overline{x}) are smaller, resulting in a smaller standard deviation. • (2) TRUE. By definition R=x_max⁡−x_min⁡R = x\_{\max} - x\_{\min}, the range depends solely on the two extrema. • (3) FALSE. The interquartile range ΔQ=Q3−Q1\Delta_Q = Q_3 - Q_1 does not depend on x_max⁡x\_{\max} or x_min⁡x\_{\min}. • (4) FALSE. The interquartile range is the range of the middle 50%50\% of the ordered observations. • (5) TRUE. The range R≥0R \ge 0, interquartile range ΔQ≥0\Delta_Q \ge 0, variance s2≥0s^2 \ge 0, and standard deviation s≥0s \ge 0.

Exercise 5.12: Consider two dot plots representing datasets A and B on the number line from 3 to 9 (each dot represents one observation frequency). Without calculating: a) Do both datasets have the same range and mean? b) Which dataset has a larger variance?

Solution for Exercise 5.12: • a) YES. Both datasets have x_min⁡=3x\_{\min} = 3 and x_max⁡=9x\_{\max} = 9, giving the same range R=9−3=6R = 9 - 3 = 6. Both dot distributions are symmetric about 6, so both have a mean of x‾=6\overline{x} = 6. • b) Dataset B has a larger variance. In dataset B, observations are heavily distributed toward the extremes (3 and 9), far from the center, whereas in dataset A observations are densely concentrated around the mean 6.

Exercise 5.13: Consider a dataset of 10 positive numbers that are not all identical. How do the measures of dispersion (range, interquartile range, standard deviation) change if: a) Each value in the dataset is multiplied by 2? b) Each value in the dataset is increased by 2?

Solution for Exercise 5.13: • a) When multiplying each value by 2 (yi=2xiy_i = 2x_i):   + The range is multiplied by 2: Ry=2RxR_y = 2R_x.   + The interquartile range is multiplied by 2: Δ_Q(y)=2Δ_Q(x)\Delta\_{Q(y)} = 2\Delta\_{Q(x)}.   + The standard deviation is multiplied by 2: sy=2sxs_y = 2s_x (the variance is multiplied by 22=42^2 = 4). • b) When adding 2 to each value (yi=xi+2y_i = x_i + 2):   + The range is unchanged: Ry=(x_max⁡+2)−(x_min⁡+2)=RxR_y = (x\_{\max} + 2) - (x\_{\min} + 2) = R_x.   + The interquartile range is unchanged: Δ_Q(y)=(Q3+2)−(Q1+2)=Δ_Q(x)\Delta\_{Q(y)} = (Q_3 + 2) - (Q_1 + 2) = \Delta\_{Q(x)}.   + The standard deviation is unchanged: sy=sxs_y = s_x (since deviations yi−y‾=xi−x‾y_i - \overline{y} = x_i - \overline{x} are invariant under translation).

b) Computational and Outlier Detection Exercises

Exercise 5.14: From a sample of cigarette taxes across 51 cities in a country, the computed statistics are: Minimum = 2.5; Q1=36Q_1 = 36; Q2=60Q_2 = 60; Q3=100Q_3 = 100; Maximum = 205. a) What proportion of cities have a cigarette tax rate greater than 36? b) Identify two values such that 50%50\% of the observations in the dataset lie between them. c) Find the interquartile range of the dataset.

Solution for Exercise 5.14: • a) Since Q1=36Q_1 = 36 represents the first quartile (25%25\% of cities have tax rates less than or equal to 36), approximately 100%−25%=75%100\% - 25\% = 75\% of cities have a cigarette tax greater than 36. • b) Approximately 50%50\% of the data values lie between the first quartile Q1=36Q_1 = 36 and the third quartile Q3=100Q_3 = 100. • c) The interquartile range is: ΔQ=Q3−Q1=100−36=64\Delta_Q = Q_3 - Q_1 = 100 - 36 = 64.

Exercise 5.15: The following data record the birth weights of 10 newborn infants (in kg): 2.977, 3.155, 3.920, 3.412, 4.236, 2.593, 3.270, 3.813, 4.042, 3.387. Compute the range, interquartile range, and standard deviation for this dataset.

Solution for Exercise 5.15: • Arrange the data in non-decreasing order (n=10n = 10): 2.593, 2.977, 3.155, 3.270, 3.387, 3.412, 3.813, 3.920, 4.042, 4.236. • Range: R=x_max⁡−x_min⁡=4.236−2.593=1.643 (kg).R = x\_{\max} - x\_{\min} = 4.236 - 2.593 = 1.643\text{ (kg)}. • Quartiles:   + Median Q2=3.387+3.4122=3.3995Q_2 = \frac{3.387 + 3.412}{2} = 3.3995.   + The lower half has 5 values; its middle value is Q1=3.155Q_1 = 3.155.   + The upper half has 5 values; its middle value is Q3=3.920Q_3 = 3.920.   + Interquartile range: ΔQ=Q3−Q1=3.920−3.155=0.765 (kg)\Delta_Q = Q_3 - Q_1 = 3.920 - 3.155 = 0.765\text{ (kg)}. • Mean: x‾=2.593+2.977+3.155+3.270+3.387+3.412+3.813+3.920+4.042+4.23610=34.80510=3.4805 (kg).\overline{x} = \frac{2.593 + 2.977 + 3.155 + 3.270 + 3.387 + 3.412 + 3.813 + 3.920 + 4.042 + 4.236}{10} = \frac{34.805}{10} = 3.4805\text{ (kg)}. • Variance: s2=∑(xi−x‾)210=2.453710≈0.24537 (kg2).s^2 = \frac{\sum (x_i - \overline{x})^2}{10} = \frac{2.4537}{10} \approx 0.24537\text{ (kg}^2). • Standard deviation: s=0.24537≈0.495 (kg)s = \sqrt{0.24537} \approx 0.495\text{ (kg)}.

Exercise 5.16: The unemployment rates in several countries in 2007 (in %) were recorded as follows: 7.8, 3.2, 7.7, 8.7, 8.6, 8.4, 7.2, 3.6, 5.0, 4.4, 6.7, 7.0, 4.5, 6.0, 5.4. Identify any outliers in the dataset.

Solution for Exercise 5.16: • Arrange the n=15n = 15 observations in non-decreasing order:   3.2, 3.6, 4.4, 4.5, 5.0, 5.4, 6.0, 6.7, 7.0, 7.2, 7.7, 7.8, 8.4, 8.6, 8.7. • Median (8th observation): Q2=6.7Q_2 = 6.7. • The lower half consists of the first 7 values (3.2 to 6.0); the middle value (4th position) is Q1=4.5Q_1 = 4.5. • The upper half consists of the last 7 values (7.0 to 8.7); the middle value (12th position) is Q3=7.8Q_3 = 7.8. • Interquartile range: ΔQ=Q3−Q1=7.8−4.5=3.3\Delta_Q = Q_3 - Q_1 = 7.8 - 4.5 = 3.3. • Outlier boundaries (fences):   + Lower fence: Q1−1.5⋅ΔQ=4.5−1.5⋅3.3=4.5−4.95=−0.45Q_1 - 1.5 \cdot \Delta_Q = 4.5 - 1.5 \cdot 3.3 = 4.5 - 4.95 = -0.45.   + Upper fence: Q3+1.5⋅ΔQ=7.8+1.5⋅3.3=7.8+4.95=12.75Q_3 + 1.5 \cdot \Delta_Q = 7.8 + 1.5 \cdot 3.3 = 7.8 + 4.95 = 12.75. • Comparison: All observations lie within [−0.45;12.75][-0.45; 12.75] (minimum 3.2>−0.453.2 > -0.45 and maximum 8.7<12.758.7 < 12.75). • Conclusion: The dataset contains no outliers.