diff --git a/pandas/core/algorithms.py b/pandas/core/algorithms.py index 974e15d926d75..0300bc7a5eb7a 100644 --- a/pandas/core/algorithms.py +++ b/pandas/core/algorithms.py @@ -1464,8 +1464,8 @@ def take(arr, indices, allow_fill=False, fill_value=None): allow_fill : bool, default False How to handle negative values in `indices`. - * False: negative values in `indices` indicate indexing from - the right (the default). This is similar to :func:`numpy.take`. + * False: negative values in `indices` indicate positional indicies + from the right (the default). This is similar to :func:`numpy.take`. * True: negative values in `indices` indicate missing values. These values are set to `fill_value`. Any other @@ -1506,7 +1506,7 @@ def take(arr, indices, allow_fill=False, fill_value=None): >>> from pandas.api.extensions import take With the default ``allow_fill=False``, negative numbers indicate - slices from the right. + positional indicies from the right. >>> take(np.array([10, 20, 30]), [0, 0, -1]) array([10, 10, 30]) diff --git a/pandas/core/arrays/base.py b/pandas/core/arrays/base.py index aa00ad2c0df9e..35906a1d08558 100644 --- a/pandas/core/arrays/base.py +++ b/pandas/core/arrays/base.py @@ -470,17 +470,17 @@ def take(self, indices, allow_fill=False, fill_value=None): Parameters ---------- indices : sequence of integers - Indices to be taken. See Notes for how negative indicies - are handled. + Indices to be taken. allow_fill : bool, default False How to handle negative values in `indices`. For False values (the default), negative values in `indices` - indiciate slices from the right. + indiciate positional indicies from the right. For True values, indicies where `indices` is ``-1`` indicate missing values. These values are set to `fill_value`. Any other other negative value should raise a ``ValueError``. + fill_value : any, optional Fill value to use for NA-indicies when `allow_fill` is True. This may be ``None``, in which case the default NA value for