Skip to content
Learn Python with BNHR

Module 3 · Beginner

DataFrames

Module 3 of Arrays & DataFrames: Series and the index, reading files with the right types, selecting and sorting, and new columns under pandas 3's copy-on-write. Its sections, its notebooks to read on the web, and the companion's solutions and explanations.

Module 3Level Beginner
On this page
  1. Overview
  2. What you do
  3. The module’s notebooks
  4. Certification and support

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.

  1. Series, the index and alignment
  2. Reading and writing with the right types: codes as text, thousands separators, Excel header rows and sheets, CSV, Excel, Parquet
  3. Selecting, filtering and sorting
  4. New columns under copy-on-write; what changed from pandas 2

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.

Saved in this browser only

Certification and support

We offer additional resources, certificates, ongoing support, and other perks to those who join our instructor-led training.

Join an upcoming training to take this as an instructor-led course, or contact us to arrange one for your team or organization.

Something new

Identify results
LayerExplore a debugging drill
Debugging drill D2Debugging drill: a report that goes wrong
AboutThe second debugging drill of Python Essentials, after module 6: a short script that reports on the barangay's files, stops with an error, then gives four wrong figures out of five, to trace and fix one function at a time.
CoursePython Essentials, free