-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added docstring for Expr.is_null #87
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, thanks @ugohuche ! Just got a suggestion
narwhals/expression.py
Outdated
|
||
>>> def func(df_any): | ||
... df = nw.from_native(df_any) | ||
... df = df.with_columns(nw.all().is_null()) # nan != null for polars |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about showing:
... df = df.with_columns(
... a_is_null = nw.col('a').is_null(),
... b_is_null = nw.col('b').is_null(),
... )
, so that the output is easier to reason about?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that makes more sense. I'll add it in the next pull request
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks! can you add it to this one please? if you make your change, add and commit them, and push them to this branch, then this pull request will be automatically updated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, I've updated the branch now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
awesome work @ugohuche !
No description provided.