0% complete

Probability & Statistics for Data Analytics · Lesson 1 of 3

Descriptive Statistics and Distribution Shape

Summarize center, spread, percentiles, and outliers without hiding distribution details.

Lesson

1. Introduction

A single average can hide important differences between records. Descriptive statistics provide compact summaries, but the right summary depends on how the data is distributed and what question is being asked.

2. Understand the concept

Mean uses every value and is sensitive to extremes; median is the middle ordered value. Range, variance, and standard deviation describe spread; percentiles describe thresholds. A histogram or box plot can reveal skew, multiple groups, and outliers that a summary number cannot.

3. Syntax and interpretation

from statistics import mean, median

wait_minutes = [2, 3, 4, 5, 60]
print(mean(wait_minutes), median(wait_minutes))

The extreme 60-minute value moves the mean more than the median; neither statistic is automatically correct for every operational question.

4. Apply it to an analysis

Summarize center, spread, percentiles, and outliers without hiding distribution details. Start with a small, known example and state what each row or value represents. After the transformation, check row counts, types, keys, and units against the original data. If an assumption fails, stop and investigate instead of presenting the output as a valid result.

5. Common mistakes

  • Removing an outlier only because it changes a result, without checking whether it is erroneous or meaningful.
  • Comparing averages from groups with very different sample sizes or distributions.

6. Practice task

Daily delivery times are usually 2–5 days, with a few values near 40 days. Which center statistic is less affected by those extremes?

7. One possible solution

The median is less affected by extreme values. Also inspect the long delays because they may be operationally important rather than errors.

8. Summary and next step

Summarize center, spread, percentiles, and outliers without hiding distribution details. Use the next lesson in this module to extend the idea with another technique and a more realistic analysis case.

Visual guide

Working through Descriptive Statistics and Distribution Shape

  1. Step 01 Define

    State the question, data grain, and expected output.

  2. Step 02 Apply

    Use the method and check its assumptions on a small example.

  3. Step 03 Verify

    Reconcile the result and communicate limitations.

Code examples

Calculate a percentile in pandas
PYTHON
import pandas as pd

latency = pd.Series([10, 12, 15, 20, 100])
print(latency.quantile(0.5))
Expected output
15.0
Compare spread with range
PYTHON
values = [4, 5, 6]
print(max(values) - min(values))
Expected output
2

Key points

  • Summarize center, spread, percentiles, and outliers without hiding distribution details.
  • Check the result against the stated data definition and a representative example.
  • Record assumptions and report data-quality limitations rather than hiding them.

Check your understanding

Practice

Which approach best applies the ideas in Descriptive Statistics and Distribution Shape?

Your learning progress

Finish this lesson