Data Cleaning Exercises

Dataset pack

Garbled city names

Customer cities from a pipeline that once read UTF-8 as Windows-1252, and the list of accepted cities.

Fictional data · UTF-8 CSV, every value quoted so padding and leading zeros survive; empty fields are missing values · free for personal and classroom practice · practise it in Repair garbled text with an approved list.

customers 19 rows × 2 columns

Download customers.csv (Pro)

Data dictionary

id
Unique customer ID.
city
City as stored (possibly garbled).

cities 7 rows × 1 columns

Download cities.csv (Pro)

Data dictionary

city
Accepted city name.

Values are shown in quotes so leading and trailing spaces are visible. ∅ means the cell is missing. Exercises are also graded on hidden datasets that are never published.