From 7425c753615bdc6997053a0e3afe543ff8cd7fb9 Mon Sep 17 00:00:00 2001 From: Pranav Date: Sun, 19 Jan 2025 21:31:09 +0530 Subject: [PATCH] fix docs --- pandas/core/frame.py | 3 ++- pandas/core/generic.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pandas/core/frame.py b/pandas/core/frame.py index 863465ca1565c..af66bb54610f1 100644 --- a/pandas/core/frame.py +++ b/pandas/core/frame.py @@ -6890,7 +6890,8 @@ def sort_values( builtin :meth:`sorted` function, with the notable difference that this `key` function should be *vectorized*. It should expect a ``Series`` and return a Series with the same shape as the input. - It will be applied to each column in `by` independently. + It will be applied to each column in `by` independently. The values in the + returned Series will be used as the keys for sorting. Returns ------- diff --git a/pandas/core/generic.py b/pandas/core/generic.py index de7fb3682fb4f..e0a4f9d9c546a 100644 --- a/pandas/core/generic.py +++ b/pandas/core/generic.py @@ -4884,7 +4884,8 @@ def sort_values( builtin :meth:`sorted` function, with the notable difference that this `key` function should be *vectorized*. It should expect a ``Series`` and return a Series with the same shape as the input. - It will be applied to each column in `by` independently. + It will be applied to each column in `by` independently. The values in the + returned Series will be used as the keys for sorting. Returns -------