Skip to content

Commit e0d6ab1

Browse files
Apply suggestions from code review
Co-authored-by: Irv Lustig <[email protected]>
1 parent 4bae30f commit e0d6ab1

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
@@ -7689,15 +7689,15 @@ def nsorted(
76897689
Italy 59000000 1937894 IT
76907690
Malta 434000 12011 MT
76917691
7692-
When using ``keep='last'``, ties are resolved in reverse order:
7692+
When using ``keep="last"``, ties are resolved in reverse order:
76937693
76947694
>>> df.nsorted(3, "population", ascending=False, keep="last")
76957695
population GDP alpha-2
76967696
France 65000000 2583560 FR
76977697
Italy 59000000 1937894 IT
76987698
Brunei 434000 12128 BN
76997699
7700-
When using ``keep='all'``, the number of elements kept can go beyond ``n``
7700+
When using ``keep="all"``, the number of elements kept can go beyond ``n``
77017701
if there are duplicate values for the smallest element. All the
77027702
ties are kept:
77037703
@@ -7721,7 +7721,7 @@ def nsorted(
77217721
77227722
To order by the largest values in column "population" and break ties
77237723
according to the smallest values in column "GDP", we can specify
7724-
multiple columns and ascending orders like in the next example.
7724+
multiple columns and ascending orders as in the next example.
77257725
77267726
>>> df.nsorted(3, ["population", "GDP"], ascending=[False, True])
77277727
population GDP alpha-2

0 commit comments

Comments
 (0)