Skip to content

Commit cb10e42

Browse files
dayorekeproost
authored andcommitted
DOC: Fixed PR08, PR09 doctring issues in pandas.core.groupby (pandas-dev#28709)
1 parent 1ba28be commit cb10e42

File tree

2 files changed

+19
-19
lines changed

2 files changed

+19
-19
lines changed

pandas/core/groupby/generic.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ def filter(self, func, dropna=True, *args, **kwargs):
709709
f : function
710710
Function to apply to each subframe. Should return True or False.
711711
dropna : Drop groups that do not pass the filter. True by default;
712-
if False, groups that evaluate False are filled with NaNs.
712+
If False, groups that evaluate False are filled with NaNs.
713713
714714
Returns
715715
-------

pandas/core/groupby/groupby.py

+18-18
Original file line numberDiff line numberDiff line change
@@ -212,9 +212,9 @@ class providing the base-class of operations.
212212
string indicating the keyword of `callable` that expects the
213213
%(klass)s object.
214214
args : iterable, optional
215-
positional arguments passed into `func`.
215+
Positional arguments passed into `func`.
216216
kwargs : dict, optional
217-
a dictionary of keyword arguments passed into `func`.
217+
A dictionary of keyword arguments passed into `func`.
218218
219219
Returns
220220
-------
@@ -664,11 +664,11 @@ def get_group(self, name, obj=None):
664664
Parameters
665665
----------
666666
name : object
667-
the name of the group to get as a DataFrame
667+
The name of the group to get as a DataFrame.
668668
obj : DataFrame, default None
669-
the DataFrame to take the DataFrame out of. If
669+
The DataFrame to take the DataFrame out of. If
670670
it is None, the object groupby was called on will
671-
be used
671+
be used.
672672
673673
Returns
674674
-------
@@ -1114,7 +1114,7 @@ def any(self, skipna=True):
11141114
Parameters
11151115
----------
11161116
skipna : bool, default True
1117-
Flag to ignore nan values during truth testing
1117+
Flag to ignore nan values during truth testing.
11181118
11191119
Returns
11201120
-------
@@ -1131,7 +1131,7 @@ def all(self, skipna=True):
11311131
Parameters
11321132
----------
11331133
skipna : bool, default True
1134-
Flag to ignore nan values during truth testing
1134+
Flag to ignore nan values during truth testing.
11351135
11361136
Returns
11371137
-------
@@ -1252,7 +1252,7 @@ def std(self, ddof=1, *args, **kwargs):
12521252
Parameters
12531253
----------
12541254
ddof : int, default 1
1255-
degrees of freedom
1255+
Degrees of freedom.
12561256
12571257
Returns
12581258
-------
@@ -1275,7 +1275,7 @@ def var(self, ddof=1, *args, **kwargs):
12751275
Parameters
12761276
----------
12771277
ddof : int, default 1
1278-
degrees of freedom
1278+
Degrees of freedom.
12791279
12801280
Returns
12811281
-------
@@ -1310,7 +1310,7 @@ def sem(self, ddof=1):
13101310
Parameters
13111311
----------
13121312
ddof : int, default 1
1313-
degrees of freedom
1313+
Degrees of freedom.
13141314
13151315
Returns
13161316
-------
@@ -1622,7 +1622,7 @@ def pad(self, limit=None):
16221622
Parameters
16231623
----------
16241624
limit : int, optional
1625-
limit of how many values to fill
1625+
Limit of how many values to fill.
16261626
16271627
Returns
16281628
-------
@@ -1648,7 +1648,7 @@ def backfill(self, limit=None):
16481648
Parameters
16491649
----------
16501650
limit : int, optional
1651-
limit of how many values to fill
1651+
Limit of how many values to fill.
16521652
16531653
Returns
16541654
-------
@@ -1680,10 +1680,10 @@ def nth(self, n: Union[int, List[int]], dropna: Optional[str] = None) -> DataFra
16801680
Parameters
16811681
----------
16821682
n : int or list of ints
1683-
a single nth value for the row or a list of nth values
1683+
A single nth value for the row or a list of nth values.
16841684
dropna : None or str, optional
1685-
apply the specified dropna operation before counting which row is
1686-
the nth row. Needs to be None, 'any' or 'all'
1685+
Apply the specified dropna operation before counting which row is
1686+
the nth row. Needs to be None, 'any' or 'all'.
16871687
16881688
Returns
16891689
-------
@@ -2098,13 +2098,13 @@ def rank(
20982098
* first: ranks assigned in order they appear in the array
20992099
* dense: like 'min', but rank always increases by 1 between groups
21002100
ascending : bool, default True
2101-
False for ranks by high (1) to low (N)
2101+
False for ranks by high (1) to low (N).
21022102
na_option : {'keep', 'top', 'bottom'}, default 'keep'
21032103
* keep: leave NA values where they are
21042104
* top: smallest rank if ascending
21052105
* bottom: smallest rank if descending
21062106
pct : bool, default False
2107-
Compute percentage rank of data within each group
2107+
Compute percentage rank of data within each group.
21082108
axis : int, default 0
21092109
The axis of the object over which to compute the rank.
21102110
@@ -2312,7 +2312,7 @@ def shift(self, periods=1, freq=None, axis=0, fill_value=None):
23122312
Parameters
23132313
----------
23142314
periods : int, default 1
2315-
number of periods to shift
2315+
Number of periods to shift.
23162316
freq : frequency string
23172317
axis : axis to shift, default 0
23182318
fill_value : optional

0 commit comments

Comments
 (0)