Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/_libs/lib.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -2712,7 +2712,7 @@ def maybe_convert_objects(ndarray[object] objects,
break
elif PyDateTime_Check(val) or cnp.is_datetime64_object(val):

# if we have an tz's attached then return the objects
# if we have a tz's attached then return the objects
if convert_non_numeric:
if getattr(val, "tzinfo", None) is not None:
seen.datetimetz_ = True
Expand Down
2 changes: 1 addition & 1 deletion pandas/_libs/tslibs/nattype.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1168,7 +1168,7 @@ class NaTType(_NaT):
fromordinal = _make_error_func(
"fromordinal",
"""
Construct a timestamp from a a proleptic Gregorian ordinal.
Construct a timestamp from a proleptic Gregorian ordinal.

This method creates a `Timestamp` object corresponding to the given
proleptic Gregorian ordinal, which is a count of days from January 1,
Expand Down
2 changes: 1 addition & 1 deletion pandas/_libs/tslibs/offsets.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1803,7 +1803,7 @@ class DateOffset(RelativeDeltaOffset, metaclass=OffsetMeta):
See Also
--------
dateutil.relativedelta.relativedelta : The relativedelta type is designed
to be applied to an existing datetime an can replace specific components of
to be applied to an existing datetime and can replace specific components of
that datetime, or represents an interval of time.

Examples
Expand Down
2 changes: 1 addition & 1 deletion pandas/_libs/tslibs/timestamps.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1869,7 +1869,7 @@ class Timestamp(_Timestamp):
@classmethod
def fromordinal(cls, ordinal, tz=None):
"""
Construct a timestamp from a a proleptic Gregorian ordinal.
Construct a timestamp from a proleptic Gregorian ordinal.

This method creates a `Timestamp` object corresponding to the given
proleptic Gregorian ordinal, which is a count of days from January 1,
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/algorithms.py
Original file line number Diff line number Diff line change
Expand Up @@ -1703,7 +1703,7 @@ def map_array(
]
else:
# Dictionary does not have a default. Thus it's safe to
# convert to an Series for efficiency.
# convert to a Series for efficiency.
# we specify the keys here to handle the
# possibility that they are tuples

Expand Down
2 changes: 1 addition & 1 deletion pandas/core/arrays/period.py
Original file line number Diff line number Diff line change
Expand Up @@ -1335,7 +1335,7 @@ def dt64arr_to_periodarr(
data, freq, tz=None
) -> tuple[npt.NDArray[np.int64], BaseOffset]:
"""
Convert an datetime-like array to values Period ordinals.
Convert a datetime-like array to values Period ordinals.

Parameters
----------
Expand Down
4 changes: 2 additions & 2 deletions pandas/core/arrays/string_arrow.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,10 @@ class ArrowStringArray(ObjectStringArrayMixin, ArrowExtensionArray, BaseStringAr
See Also
--------
:func:`array`
The recommended function for creating a ArrowStringArray.
The recommended function for creating an ArrowStringArray.
Series.str
The string methods are available on Series backed by
a ArrowStringArray.
an ArrowStringArray.

Notes
-----
Expand Down
4 changes: 2 additions & 2 deletions pandas/core/dtypes/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -882,7 +882,7 @@ def is_unsigned_integer_dtype(arr_or_dtype) -> bool:
See Also
--------
api.types.is_signed_integer_dtype : Check whether the provided array
or dtype is of an signed integer dtype.
or dtype is of a signed integer dtype.
api.types.is_integer_dtype : Check whether the provided array or dtype
is of an integer dtype.
api.types.is_numeric_dtype : Check whether the provided array or dtype
Expand Down Expand Up @@ -1264,7 +1264,7 @@ def is_numeric_dtype(arr_or_dtype) -> bool:
api.types.is_unsigned_integer_dtype: Check whether the provided array
or dtype is of an unsigned integer dtype.
api.types.is_signed_integer_dtype: Check whether the provided array
or dtype is of an signed integer dtype.
or dtype is of a signed integer dtype.

Examples
--------
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/groupby/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -2913,7 +2913,7 @@ def take(
Returns
-------
DataFrame
An DataFrame containing the elements taken from each group.
A DataFrame containing the elements taken from each group.

See Also
--------
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/indexers/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def check_setitem_lengths(indexer, value, values) -> bool:
"""
Validate that value and indexer are the same length.

An special-case is allowed for when the indexer is a boolean array
A special-case is allowed for when the indexer is a boolean array
and the number of true values equals the length of ``value``. In
this case, no exception is raised.

Expand Down
2 changes: 1 addition & 1 deletion pandas/core/indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -2024,7 +2024,7 @@ def _setitem_with_indexer_split_path(self, indexer, value, name: str):
)

elif lplane_indexer == 0 and len(value) == len(self.obj.index):
# We get here in one case via .loc with a all-False mask
# We get here in one case via .loc with an all-False mask
pass

elif self._is_scalar_access(indexer) and is_object_dtype(
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/reshape/reshape.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ def __init__(
# Bug fix GH 20601
# If the data frame is too big, the number of unique index combination
# will cause int32 overflow on windows environments.
# We want to check and raise an warning before this happens
# We want to check and raise a warning before this happens
num_rows = max(index_level.size for index_level in self.new_index_levels)
num_columns = self.removed_level.size

Expand Down
2 changes: 1 addition & 1 deletion pandas/core/series.py
Original file line number Diff line number Diff line change
Expand Up @@ -2142,7 +2142,7 @@ def unique(self) -> ArrayLike:
['2016-01-01 00:00:00-05:00']
Length: 1, dtype: datetime64[s, US/Eastern]

An Categorical will return categories in the order of
A Categorical will return categories in the order of
appearance and with the same dtype.

>>> pd.Series(pd.Categorical(list("baabc"))).unique()
Expand Down
2 changes: 1 addition & 1 deletion web/pandas/community/blog/extension-arrays.md
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ array(['a', 'b', 'a'], dtype=object)

To summarize:

- `.array` will *always* be a an ExtensionArray, and is always a zero-copy
- `.array` will *always* be an ExtensionArray, and is always a zero-copy
reference back to the data.
- `.to_numpy()` is *always* a NumPy array, so you can reliably call
ndarray-specific methods on it.
Expand Down
Loading