BUG: aggregate(sum) returns wrong result for certain boolean input #7666
Labels
Bug
Dtype Conversions
Unexpected or buggy dtype conversions
Duplicate Report
Duplicate issue or pull request
Groupby
Milestone
I have a DataFrame that looks like the following format:
I want group this by foo and count the number of True values in the bar column. Counting the True values can be achieved with the sum command.
To group and count this:
This output is erroneous. Expected output is:
It works in the following case (changed so that not all cases for foo:2 are false).
Here are my installed versions:
The text was updated successfully, but these errors were encountered: