Skip to content

Commit a720c69

Browse files
authored
DOC: updated docstring for deprecation of axis=1 in groupby (#54896)
* added deprecation for axis=1 * suggested changes
1 parent c74a071 commit a720c69

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

pandas/core/shared_docs.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,12 @@
113113
axis : {0 or 'index', 1 or 'columns'}, default 0
114114
Split along rows (0) or columns (1). For `Series` this parameter
115115
is unused and defaults to 0.
116+
117+
.. deprecated:: 2.1.0
118+
119+
Will be removed and behave like axis=0 in a future version.
120+
For ``axis=1``, do ``frame.T.groupby(...)`` instead.
121+
116122
level : int, level name, or sequence of such, default None
117123
If the axis is a MultiIndex (hierarchical), group by a particular
118124
level or levels. Do not specify both ``by`` and ``level``.

0 commit comments

Comments
 (0)