Skip to content

migrate: convert missing-values.ipynb from pandas to polars#11

Open
meshackamadi wants to merge 1 commit into
mainfrom
missing-values-conversion-to-polars
Open

migrate: convert missing-values.ipynb from pandas to polars#11
meshackamadi wants to merge 1 commit into
mainfrom
missing-values-conversion-to-polars

Conversation

@meshackamadi

Copy link
Copy Markdown
Collaborator

Summary

Converts the missing-values.ipynb chapter from pandas to polars, covering explicit and implicit missing value handling.

Changes

Code

  • .isna().is_null()
  • .notna().is_not_null()
  • .fillna().fill_null()
  • .dropna().drop_nulls()
  • method="ffill"strategy="forward"
  • method="bfill"strategy="backward"
  • .replace({-99: pd.NA}).with_columns(pl.col("*").replace(-99, None))

Text

  • Updated prerequisites to mention polars
  • Updated terminology: "NA" → "null"
  • Updated function names to polars equivalents

Testing

  • All code blocks execute successfully
  • Missing value handling produces expected results
  • Notebook renders without errors

Files Modified

  • missing-values.ipynb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant