Most mistakes in an analysis happen before it starts, when a file is read. This module reads the survey’s files the way they need to be read: area codes kept as text, so their leading zero survives; harvests written with thousands separators; an Excel workbook with title rows above each table. Then it selects, filters and sorts, and adds columns the way pandas 3 expects, with a note wherever pandas 2 behaved differently.
What you do
Section titled “What you do”- Series, the index and alignment
- Reading and writing with the right types: codes as text, thousands separators, Excel header rows and sheets, CSV, Excel, Parquet
- Selecting, filtering and sorting
- New columns under copy-on-write; what changed from pandas 2
The module’s notebooks
Section titled “The module’s notebooks”- 20_dataframes.pyDataFramesRead itCompanion · 9 exercises
The notebooks are in your course folder; here you can read them without running anything. For reference in any module: primer: marimo and the python this course assumes and primer: pandas 2 to 3 and glossary.