Skip to main content
PyPath
Home
Courses
Courses
See both
1
Python Foundations
10 units
2
Python for Data
10 units
Sandbox
Classroom
My class
Settings
Start learning
Sign in
My progress
My classroom
Account
Sign out
Courses
·
Python for Data
Unit 8 · Combining Tables
Joins, keys that do not match, and reshaping between wide and long.
1
Stacking Tables with concat
Two tables of the same shape, one after the other.
2
Merging on a Key
Bringing two tables together on the column they share.
3
When a Merge Goes Wrong
Duplicate keys multiply rows, and mismatched types match nothing.
4
Wide to Long with melt
Turning a column per month into a column that says which month.
5
Long to Wide with pivot
The other direction, for when a person should be one row.
6
Putting a Join to Work
Two files, one question, and the checks that keep the answer honest.