Skip to content

Day 03 — Part 1: Pandas Advanced

Knowing how to load a DataFrame and filter rows is the entry fee. The real work — grouping sales by region, merging customer tables, cleaning a dataset full of nulls and typos — requires the techniques in this session. These are the operations that appear in every data analyst's day-to-day workflow, and they are the ones interviewers test.

Session Overview

Difficulty: Intermediate Reading time: ~2 hours | Exercises: ~1.5 hours Prerequisites: Pandas basics · Series and DataFrames · filtering (Day 02 Part 2)


What You Will Learn

By the end of this session you will be able to:

  • Group data and apply multiple aggregations in a single step
  • Merge two DataFrames on a key column using inner and left joins
  • Apply custom functions row-wise and column-wise with .apply()
  • Choose the right missing-value strategy for a given scenario
  • Clean a messy real-world dataset end to end

Session Roadmap

# Topic File Time
1 GroupBy — split-apply-combine, multiple aggregations 01-groupby.md 25 min
2 Merge & Join — inner/left/right/outer, on= and how= 02-merge-and-join.md 25 min
3 Apply Functions — .apply(), lambda, .map() 03-apply-functions.md 20 min
4 Missing Values — isnull(), fillna(), dropna(), imputation 04-missing-values.md 20 min
5 Real-World Data Cleaning — duplicates, type casting, strings 05-real-world-data-cleaning.md 20 min
6 Exercises — 3 levels of difficulty 06-exercises.md 45 min

Total active learning time: ~2.5 hours


How to Use This Session

Read files 01–05 in order — each topic builds on the previous. For groupby and merge, run every code snippet yourself rather than just reading it: the edge cases only become visible when you see the output. The exercises in file 06 cover all five topics, so complete those before moving to Part 2.

If you are already comfortable with groupby and merge, skim those files and spend more time on missing-value strategies — that is the section most students underestimate until they hit a real messy dataset.


Before You Start

Have a DataFrame loaded from a CSV you care about — a Kaggle dataset, your own data, anything. Running the techniques on data that is meaningful to you makes the patterns stick far faster than running them on toy examples.


01-groupby