Skip to content

Commit 9432e3c

Browse files
aberresvictor
authored and
victor
committed
DOC: Do no use 'type' as first word when specifying a return type (pandas-dev#21622) (pandas-dev#21623)
1 parent ede2890 commit 9432e3c

File tree

8 files changed

+22
-22
lines changed

8 files changed

+22
-22
lines changed

pandas/core/frame.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -4675,7 +4675,7 @@ def swaplevel(self, i=-2, j=-1, axis=0):
46754675
46764676
Returns
46774677
-------
4678-
swapped : type of caller (new object)
4678+
swapped : same type as caller (new object)
46794679
46804680
.. versionchanged:: 0.18.1
46814681

pandas/core/generic.py

+14-14
Original file line numberDiff line numberDiff line change
@@ -800,7 +800,7 @@ def swaplevel(self, i=-2, j=-1, axis=0):
800800
801801
Returns
802802
-------
803-
swapped : type of caller (new object)
803+
swapped : same type as caller (new object)
804804
805805
.. versionchanged:: 0.18.1
806806
@@ -1073,7 +1073,7 @@ def _set_axis_name(self, name, axis=0, inplace=False):
10731073
10741074
Returns
10751075
-------
1076-
renamed : type of caller or None if inplace=True
1076+
renamed : same type as caller or None if inplace=True
10771077
10781078
See Also
10791079
--------
@@ -2468,7 +2468,7 @@ def get(self, key, default=None):
24682468
24692469
Returns
24702470
-------
2471-
value : type of items contained in object
2471+
value : same type as items contained in object
24722472
"""
24732473
try:
24742474
return self[key]
@@ -2768,7 +2768,7 @@ def __delitem__(self, key):
27682768
27692769
Returns
27702770
-------
2771-
taken : type of caller
2771+
taken : same type as caller
27722772
An array-like containing the elements taken from the object.
27732773
27742774
See Also
@@ -2824,7 +2824,7 @@ def _take(self, indices, axis=0, is_copy=True):
28242824
28252825
Returns
28262826
-------
2827-
taken : type of caller
2827+
taken : same type as caller
28282828
An array-like containing the elements taken from the object.
28292829
28302830
See Also
@@ -3033,7 +3033,7 @@ def select(self, crit, axis=0):
30333033
30343034
Returns
30353035
-------
3036-
selection : type of caller
3036+
selection : same type as caller
30373037
"""
30383038
warnings.warn("'select' is deprecated and will be removed in a "
30393039
"future release. You can use "
@@ -3924,7 +3924,7 @@ def head(self, n=5):
39243924
39253925
Returns
39263926
-------
3927-
obj_head : type of caller
3927+
obj_head : same type as caller
39283928
The first `n` rows of the caller object.
39293929
39303930
See Also
@@ -4447,7 +4447,7 @@ def _consolidate(self, inplace=False):
44474447
44484448
Returns
44494449
-------
4450-
consolidated : type of caller
4450+
consolidated : same type as caller
44514451
"""
44524452
inplace = validate_bool_kwarg(inplace, 'inplace')
44534453
if inplace:
@@ -4916,7 +4916,7 @@ def astype(self, dtype, copy=True, errors='raise', **kwargs):
49164916
49174917
Returns
49184918
-------
4919-
casted : type of caller
4919+
casted : same type as caller
49204920
49214921
Examples
49224922
--------
@@ -6691,7 +6691,7 @@ def asfreq(self, freq, method=None, how=None, normalize=False,
66916691
66926692
Returns
66936693
-------
6694-
converted : type of caller
6694+
converted : same type as caller
66956695
66966696
Examples
66976697
--------
@@ -6772,7 +6772,7 @@ def at_time(self, time, asof=False):
67726772
67736773
Returns
67746774
-------
6775-
values_at_time : type of caller
6775+
values_at_time : same type as caller
67766776
67776777
Examples
67786778
--------
@@ -6826,7 +6826,7 @@ def between_time(self, start_time, end_time, include_start=True,
68266826
68276827
Returns
68286828
-------
6829-
values_between_time : type of caller
6829+
values_between_time : same type as caller
68306830
68316831
Examples
68326832
--------
@@ -7145,7 +7145,7 @@ def first(self, offset):
71457145
71467146
Returns
71477147
-------
7148-
subset : type of caller
7148+
subset : same type as caller
71497149
71507150
See Also
71517151
--------
@@ -7209,7 +7209,7 @@ def last(self, offset):
72097209
72107210
Returns
72117211
-------
7212-
subset : type of caller
7212+
subset : same type as caller
72137213
72147214
See Also
72157215
--------

pandas/core/groupby/groupby.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ def get_group(self, name, obj=None):
867867
868868
Returns
869869
-------
870-
group : type of obj
870+
group : same type as obj
871871
"""
872872
if obj is None:
873873
obj = self._selected_obj

pandas/core/sparse/series.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ def abs(self):
398398
399399
Returns
400400
-------
401-
abs: type of caller
401+
abs: same type as caller
402402
"""
403403
return self._constructor(np.abs(self.values),
404404
index=self.index).__finalize__(self)

pandas/core/window.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,7 @@ def _apply_window(self, mean=True, **kwargs):
665665
666666
Returns
667667
-------
668-
y : type of input argument
668+
y : same type as input argument
669669
670670
"""
671671
window = self._prep_window(**kwargs)
@@ -2139,7 +2139,7 @@ def _apply(self, func, **kwargs):
21392139
21402140
Returns
21412141
-------
2142-
y : type of input argument
2142+
y : same type as input argument
21432143
21442144
"""
21452145
blocks, obj, index = self._create_blocks()

pandas/io/packers.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ def read_msgpack(path_or_buf, encoding='utf-8', iterator=False, **kwargs):
178178
179179
Returns
180180
-------
181-
obj : type of object stored in file
181+
obj : same type as object stored in file
182182
183183
"""
184184
path_or_buf, _, _, should_close = get_filepath_or_buffer(path_or_buf)

pandas/io/pickle.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def read_pickle(path, compression='infer'):
103103
104104
Returns
105105
-------
106-
unpickled : type of object stored in file
106+
unpickled : same type as object stored in file
107107
108108
See Also
109109
--------

pandas/io/pytables.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ def get(self, key):
687687
688688
Returns
689689
-------
690-
obj : type of object stored in file
690+
obj : same type as object stored in file
691691
"""
692692
group = self.get_node(key)
693693
if group is None:

0 commit comments

Comments
 (0)