Skip to content

Commit 8a96cc4

Browse files
committed
fixing docstring tests
1 parent ac44127 commit 8a96cc4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pandas/core/base.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -1005,9 +1005,9 @@ def value_counts(
10051005
>>> index = pd.Index([3, 1, 2, 3, 4, np.nan])
10061006
>>> index.value_counts()
10071007
3.0 2
1008+
1.0 1
10081009
2.0 1
10091010
4.0 1
1010-
1.0 1
10111011
dtype: int64
10121012
10131013
With `normalize` set to `True`, returns the relative frequency by
@@ -1016,9 +1016,9 @@ def value_counts(
10161016
>>> s = pd.Series([3, 1, 2, 3, 4, np.nan])
10171017
>>> s.value_counts(normalize=True)
10181018
3.0 0.4
1019+
1.0 0.2
10191020
2.0 0.2
10201021
4.0 0.2
1021-
1.0 0.2
10221022
dtype: float64
10231023
10241024
**bins**
@@ -1040,10 +1040,10 @@ def value_counts(
10401040
10411041
>>> s.value_counts(dropna=False)
10421042
3.0 2
1043+
1.0 1
10431044
2.0 1
1044-
NaN 1
10451045
4.0 1
1046-
1.0 1
1046+
NaN 1
10471047
dtype: int64
10481048
"""
10491049
result = value_counts(

0 commit comments

Comments
 (0)