Skip to content

Commit 363865b

Browse files
committed
Silence deprecation warning.
1 parent fb6e4b0 commit 363865b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/core/frame.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5677,7 +5677,7 @@ def value_counts(
56775677
if subset is None:
56785678
subset = self.columns.tolist()
56795679

5680-
counts = self.groupby(subset).grouper.size()
5680+
counts = self.groupby(subset, observed=True).grouper.size()
56815681

56825682
if sort:
56835683
counts = counts.sort_values(ascending=ascending)

0 commit comments

Comments
 (0)