Closed
Description
Series.value_counts()
also shows categories with count 0.
Thought this would be a bug but according to doc it is intentional.
This makes the output of value_counts inconsistent when switching between category and non-category dtype. Apart from that it blows up the value_counts output for series with many categories.
I would prefer to hide counts (i.e. zero) for non-occuring categories by default and rather consider a parameter dropzero=True
similar to dropna
(see also #5569).