Skip to content

Commit de4525b

Browse files
authored
DOC: fix some dosctring-RT02-errors in index and styler (pandas-dev#50181)
1 parent ba74fee commit de4525b

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

pandas/core/indexes/base.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -1116,7 +1116,7 @@ def _maybe_disallow_fill(self, allow_fill: bool, fill_value, indices) -> bool:
11161116
11171117
Returns
11181118
-------
1119-
repeated_index : %(klass)s
1119+
%(klass)s
11201120
Newly created %(klass)s with repeated elements.
11211121
11221122
See Also
@@ -2755,7 +2755,7 @@ def drop_duplicates(self: _IndexT, *, keep: DropKeep = "first") -> _IndexT:
27552755
27562756
Returns
27572757
-------
2758-
deduplicated : Index
2758+
Index
27592759
27602760
See Also
27612761
--------
@@ -3128,7 +3128,7 @@ def intersection(self, other, sort: bool = False):
31283128
31293129
Returns
31303130
-------
3131-
intersection : Index
3131+
Index
31323132
31333133
Examples
31343134
--------
@@ -5943,7 +5943,7 @@ def map(self, mapper, na_action=None):
59435943
59445944
Returns
59455945
-------
5946-
applied : Union[Index, MultiIndex], inferred
5946+
Union[Index, MultiIndex]
59475947
The output of the mapping function applied to the index.
59485948
If the function returns a tuple with more than one element
59495949
a MultiIndex will be returned.
@@ -6422,7 +6422,7 @@ def insert(self, loc: int, item) -> Index:
64226422
64236423
Returns
64246424
-------
6425-
new_index : Index
6425+
Index
64266426
"""
64276427
item = lib.item_from_zerodim(item)
64286428
if is_valid_na_for_dtype(item, self.dtype) and self.dtype != object:
@@ -6482,7 +6482,7 @@ def drop(
64826482
64836483
Returns
64846484
-------
6485-
dropped : Index
6485+
Index
64866486
Will be same type as self, except for RangeIndex.
64876487
64886488
Raises

pandas/io/formats/style_render.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -987,7 +987,7 @@ def format(
987987
988988
Returns
989989
-------
990-
self : Styler
990+
Styler
991991
992992
See Also
993993
--------
@@ -1202,7 +1202,7 @@ def format_index(
12021202
12031203
Returns
12041204
-------
1205-
self : Styler
1205+
Styler
12061206
12071207
See Also
12081208
--------
@@ -1365,7 +1365,7 @@ def relabel_index(
13651365
13661366
Returns
13671367
-------
1368-
self : Styler
1368+
Styler
13691369
13701370
See Also
13711371
--------

0 commit comments

Comments
 (0)