Skip to content

Commit e2bb42a

Browse files
committed
ENH: API change -- sort (columns=) instead of column=
to be more adequate and correspond to provided docstring
1 parent 13f5db0 commit e2bb42a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pandas/core/frame.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2149,10 +2149,10 @@ def duplicated(self, cols=None, take_last=False):
21492149
#----------------------------------------------------------------------
21502150
# Sorting
21512151

2152-
def sort(self, column=None, axis=0, ascending=True):
2152+
def sort(self, columns=None, axis=0, ascending=True):
21532153
"""
21542154
Sort DataFrame either by labels (along either axis) or by the values in
2155-
a column
2155+
column(s)
21562156
21572157
Parameters
21582158
----------
@@ -2168,7 +2168,7 @@ def sort(self, column=None, axis=0, ascending=True):
21682168
-------
21692169
sorted : DataFrame
21702170
"""
2171-
return self.sort_index(by=column, axis=axis, ascending=ascending)
2171+
return self.sort_index(by=columns, axis=axis, ascending=ascending)
21722172

21732173
def sort_index(self, axis=0, by=None, ascending=True):
21742174
"""

0 commit comments

Comments
 (0)