You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 10, 2024. It is now read-only.
I've found it's valuable to be able to consistently compute statistics including the NA values, especially with multiple group keys. I haven't kept track of how pandas handles these now in all cases, but it would be nice to come up with a strategy to make NA behave like any other group in a group by setting.
The text was updated successfully, but these errors were encountered:
In the specific case of value_counts, there is the dropna keyword which does this:
In [15]: s.value_counts(dropna=False)
Out[15]:
1.0 3
NaN 2
2.0 2
dtype: int64
But of course that does not dismiss the bigger problem with groupby and others (and you could also argue whether dropna=False would be a better default value ..)
xref #9
Maybe we can collect a list of pandas issues that have happened in and around this.
I've found it's valuable to be able to consistently compute statistics including the NA values, especially with multiple group keys. I haven't kept track of how pandas handles these now in all cases, but it would be nice to come up with a strategy to make NA behave like any other group in a group by setting.
The text was updated successfully, but these errors were encountered: