MODULE 02 · Junior · 90 minutes

Revenue grew, profit did not. We found out why without a model

EDA is not “looking at the data”, it is an investigation. One report over 50,000 orders turns up duplicates, missing values and the real cause of the margin collapse.

Open this module in the simulator All 23 lessons

This module is free — it only needs an account, no card.

🏢 The situation

Wednesday. A Slack message from Lena:

"First real task. Max wants to understand what's going on with sales in the 'Electronics' category — revenue is growing but profit isn't. Anya exported sales.csv for you covering the last 12 months (50,000 orders). I need an EDA report by Friday: what's in the data, what anomalies, what hypotheses. Not a model — an understanding of the data. And check data quality: Anya had complaints about duplicates caused by pipeline retries."

🎯 Your task

  1. Load the data and understand its structure.
  2. Find quality issues: missing values, duplicates, anomalies.
  3. Answer the business question: why is revenue growing while profit is flat?

📚 Theory

What EDA is and why it matters

EDA (Exploratory Data Analysis) is the first thing any ML engineer does with a new dataset. Goals:

  1. Understand the structure: which columns, types, how many rows.
  2. Find problems: missing values, duplicates, outliers, type errors.
  3. See patterns: distributions, correlations, trends.
  4. Form hypotheses before building any models.

A rule from practice: a model trained on unverified data is a bug you'll notice too late.

The essential Pandas toolkit

What to look for in describe()

Missing values: three strategies

Strategy When to use
Drop rows < 1–2% missing and they are random
Fill (median/mode/special value) noticeable share, the column matters
Keep as a feature the very fact of missingness is informative (e.g. "didn't provide a phone number")

Outliers

The classic method is the interquartile range (IQR): an outlier is a value outside [Q1 − 1.5·IQR, Q3 + 1.5·IQR], where IQR = Q3 − Q1. But remember: not every outlier is an error. A 900,000 order may be a real wholesale purchase. Investigate outliers first, then decide.

Skewed distribution of order value median $12 mean $45 "whales" — rare large orders pull the mean → order value →
The right "tail" pulls the mean far away from the typical order. For skewed data, report the median and quantiles.

What to remember

  1. shape, head, info, describe — always first.
  2. Duplicates — by the business key.
  3. Missing values — understand why they exist, then decide what to do.
  4. Outliers — investigate, don't blindly delete.
  5. Dates — convert to datetime, check the range and gaps.
  6. Conclusions — in business language, not "p-values and quartiles".

Next in this module: Practice

Open the module →

Nearby lessons

01 First day at Datacore 03 Marketing argues: did the discount help?

The whole program — 23 lessons