Data Visualization › Box Plots: Summarizing Key Statistics
Machine Learning from ScratchAll chapters Data Visualization › Box Plots: Summarizing Key StatisticsOne section · Sections in this chapter4 / 10 ↓
Reading tools Definitions & inline links
Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.
Article links
Make inline references clickable
Box plots, also known as box-and-whisker plots, provide a concise visual summary of a distribution's key statistical properties. The rectangular box spans from the first quartile (25th percentile) to the third quartile (75th percentile), capturing the middle 50% of the data. A line inside the box marks the median (50th percentile). Whiskers extend from the box to show the range of typical values, while individual points beyond the whiskers flag potential outliers.
This compact representation makes box plots particularly valuable for comparing distributions across multiple groups. Arranging several box plots side by side immediately reveals differences in central tendency (median positions), spread (box heights), and outlier patterns. Such comparisons might show that one group has systematically higher values than another, or that some groups exhibit more variability, or that outliers occur predominantly in certain categories.
The definition of outliers in box plots typically follows the interquartile range (IQR) rule: values more than 1.5 times the IQR below the first quartile or above the third quartile are flagged as potential outliers. While this rule is somewhat arbitrary, it provides a useful starting point for identifying observations that warrant closer inspection. Some outliers are valid extreme values that carry important information about rare events or boundary conditions. Others indicate measurement errors, data entry mistakes, or observations from a different population that should be excluded or modeled separately.
Box plots sacrifice some information that histograms preserve, particularly about the detailed shape of the distribution between quartiles. A bimodal distribution with two distinct peaks might appear as a simple box plot with a large interquartile range. This limitation means box plots work best as complements to, rather than replacements for, histograms, with each visualization type highlighting different aspects of the data.
