Skip to content

Commit b41e06a

Browse files
authored
Update base.py
normalize parameter updated.
1 parent 4fcee0e commit b41e06a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

pandas/core/base.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -969,7 +969,7 @@ def _map_values(self, mapper, na_action=None):
969969

970970
def value_counts(
971971
self,
972-
normalize: bool = False,
972+
normalize: Union[bool, str] = False,
973973
sort: bool = True,
974974
ascending: bool = False,
975975
bins=None,
@@ -984,9 +984,10 @@ def value_counts(
984984
985985
Parameters
986986
----------
987-
normalize : bool, default False
987+
normalize : bool and string, default False
988988
If True then the object returned will contain the relative
989989
frequencies of the unique values.
990+
If keep then both the count and relative count will be returned.
990991
sort : bool, default True
991992
Sort by frequencies when True. Preserve the order of the data when False.
992993
ascending : bool, default False

0 commit comments

Comments
 (0)