All lessons
Python pandas for analysis: clean, group, join and reshape data
Learn pandas by doing: real Python runs in the page, so every example can be edited and run, and every exercise checks your answer. Cleaning, filtering, grouping, joins, reshaping, dates and the analyses employers ask for, ending with a retail analysis notebook for your portfolio.
What you will be able to do
- Load and explore any table: CSV and Excel files, a first look with head, info and describe, and picking out the rows and columns you need.
- Clean messy exports: missing values, duplicates, wrong types, untidy text and mixed date formats, with checks that prove the data is right.
- Summarise and combine: groupby, pivot tables, joins between tables, and reshaping between wide and long.
- Work with dates: weekly and monthly totals, rolling averages and year-over-year growth.
- Do the analyses employers ask for: KPI tables, Pareto, RFM segments, cohort retention and A/B tests.
Real Python runs in this page: every example can be changed and run, and every exercise has Run, Check, Hint and Show answer, with no sign-up and nothing to install. The first run downloads Python once (about 20 MB); after that it works offline. You finish with a retail analysis notebook for your GitHub portfolio. The statistics behind the analyses are in Statistics for analysts.
0 of 49 lessons done
Without the tick, your progress lasts until you close this tab. Either way it stays in this browser: there is no sign-up and nothing is sent to us.