1. 학습
  2. /
  3. 강의
  4. /
  5. Scaling and Optimizing Data Pipelines with Polars

Connected

연습 문제

Creating a Categorical column

Back to the movie dataset from the streaming startup. Most rows in original_language use the same handful of codes (en, fr, es, …). Casting to Categorical encodes each unique label as an integer behind the scenes, saving memory on repeated strings.

지침

100 XP
  • Cast the original_language column to pl.Categorical.