Skip to content

Commit efb54f7

Browse files
committed
Hande min_count=0
1 parent 24dc7fd commit efb54f7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

flox/aggregations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,7 @@ def _initialize_aggregation(
562562
# absent in one block, but present in another block
563563
# We set it for numpy to get nansum, nanprod tests to pass
564564
# where the identity element is 0, 1
565-
if min_count is not None:
565+
if min_count is not None and min_count > 0:
566566
agg.min_count = min_count
567567
agg.chunk += ("nanlen",)
568568
agg.numpy += ("nanlen",)

0 commit comments

Comments
 (0)