-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
min()/max() behaves different with nan #328
Comments
FWIW pandas seems to ignore Nans while calculating min/max:
|
pandas use NaN to represent missing values. polars has None for this purpose, so I think both |
Consistency indeed, and the possibility to ignore / include NaNs. I can imagine this is completely use case dependent. I like for instance in numerical tools like numpy, pytorch etc. to have the option |
That is likely, though I can't think of any usecase for an aggregate function like
Sorting is a different story and you may be sorting on columns that have Nans in them but the other columns are non-null preserved |
The text was updated successfully, but these errors were encountered: