Skip to main content
Loading page…
Python Mastery
Chapter 10
Lesson 4 of 4
CSV & Tabular Data
Contents
Notes
Tutor
Note
Bridge: csv, pathlib, and tempfile Imports
Loading activity…
Previous
1 / 9
Continue
Contents
Notes
Discussion
Tutor
30 min
9 activities
0 of 9 done
In this lesson
1
Bridge: csv, pathlib, and tempfile Imports
2
Why CSV Needs Special Handling
3
Reading CSV: reader vs DictReader
4
Writing CSV: writer and DictWriter
5
Pitfall: Forgetting newline="" Causes Blank Rows on Windows
6
A Tiny ETL: Filter and Transform a CSV
7
Practice: CSV Summary Statistics
8
CSV Module Quick Check
9
Pro Tip: Use pandas for Larger Datasets
Objectives
Learner can read CSV files with csv.reader and csv.DictReader
Learner can write CSV files with csv.writer and csv.DictWriter
Learner can explain why newline="" is required when opening CSV files
Learner can implement a small ETL pipeline: read CSV, filter rows, write a new CSV
Chapter 10 · Files, JSON & CSV
Reading & Writing Files
Paths Done Right with pathlib
JSON: Talking to the World
CSV & Tabular Data
Previous: JSON: Talking to the World
Next: Regex Foundations