-
Notifications
You must be signed in to change notification settings - Fork 15
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
refactored CheckNumericMixin #339
Conversation
TODO - make new test run in polars/pandas once baseimputer PR completes |
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 @limlam96!
# check weight not inf, not currently a narwhals efficient way to do this | ||
if np.isinf(X[weights_column].to_numpy()).any(): |
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.
Hey everyone! I wanted to reach out to mention that we just added Series|Expr.is_finite()
method.
It is not fully consistent with nulls across different pandas dtype backends, but you check for null in the block above.
As we just made a release as well, it is available for narhwals>=1.14.
Have a good one 🎉
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.
Hey, ah amazing! will have a play with this soon + appreciate you letting us know :)
refactored for narwhals
spotted that this wasn't being used consistently across numeric file, so also addressed this
#336