Chapter 1 · 7 levels
Describing data
Mean versus median, percentiles, standard deviation, IQR and outliers, on Harbor & Pine's order values. Which number describes a typical order, and which one misleads.
StartEvery analysis starts with a handful of numbers that describe a column: where the middle is, how spread out the values are, and which values sit far from the rest. They look simple, and they are where most reporting mistakes start.
Harbor & Pine’s order values are a perfect teacher. A few large business orders pull the average far above what a typical customer spends, so “average order value” on a slide describes almost nobody. In this chapter you compute the mean and the median and learn when each one is the honest answer, read percentiles, measure spread with the standard deviation and the IQR, and decide which extreme values are real customers and which are data errors.
Every code level gives you completed: one row per completed order with its order_value (what
the customer paid for the items, before shipping), built from orders and order_items in the
starter code. The boss puts it all together in a report your Head of Sales can show the CEO.
Levels
- Percentiles for the free-shipping threshold
from Daniel Brooks, Head of Operations
percentiles, quantile, distribution, threshold
- One raise, two averages
from Nicole Bennett, HR Business Partner
mean, median, outliers, robust statistics
- How spread out are our orders?
from Brian Mitchell, Finance Analyst
standard deviation, iqr, spread, outliers
- Outlier or error?
from Megan Collins, Head of Sales
outliers, data errors, data cleaning, robust statistics
- Which channel's sales are steadier?
from Kevin Brooks, Operations Manager
standard deviation, coefficient of variation, volatility, groupby
- Boss: the order value report, done right
from Megan Collins, Head of Sales
mean, median, iqr, data errors, groupby, reporting