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 doc/make.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def _process_single_doc(self, single_doc):
@staticmethod
def _run_os(*args) -> None:
"""
Execute a command as a OS terminal.
Execute a command as an OS terminal.

Parameters
----------
Expand Down
2 changes: 1 addition & 1 deletion pandas/_config/localization.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def can_set_locale(lc: str, lc_var: int = locale.LC_ALL) -> bool:
with set_locale(lc, lc_var=lc_var):
pass
except (ValueError, locale.Error):
# horrible name for a Exception subclass
# horrible name for an Exception subclass
return False
else:
return True
Expand Down
6 changes: 3 additions & 3 deletions pandas/core/arrays/categorical.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ class Categorical(NDArrayBackedExtensionArray, PandasObject, ObjectStringArrayMi
categories are assumed to be the unique values of `values` (sorted, if
possible, otherwise in the order in which they appear).
ordered : bool, default False
Whether or not this categorical is treated as a ordered categorical.
Whether or not this categorical is treated as an ordered categorical.
If True, the resulting categorical will be ordered.
An ordered categorical respects, when sorted, the order of its
`categories` attribute (which in turn is the `categories` argument, if
Expand Down Expand Up @@ -1103,7 +1103,7 @@ def set_categories(
new_categories : Index-like
The categories in new order.
ordered : bool, default None
Whether or not the categorical is treated as a ordered categorical.
Whether or not the categorical is treated as an ordered categorical.
If not given, do not change the ordered information.
rename : bool, default False
Whether or not the new_categories should be considered as a rename
Expand Down Expand Up @@ -1277,7 +1277,7 @@ def reorder_categories(self, new_categories, ordered=None) -> Self:
new_categories : Index-like
The categories in new order.
ordered : bool, optional
Whether or not the categorical is treated as a ordered categorical.
Whether or not the categorical is treated as an ordered categorical.
If not given, do not change the ordered information.

Returns
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/arrays/timedeltas.py
Original file line number Diff line number Diff line change
Expand Up @@ -1212,7 +1212,7 @@ def _objects_to_td64ns(
data, unit=None, errors: DateTimeErrorChoices = "raise"
) -> np.ndarray:
"""
Convert a object-dtyped or string-dtyped array into an
Convert an object-dtyped or string-dtyped array into a
timedelta64[ns]-dtyped array.

Parameters
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/dtypes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ class Registry:
"""
Registry for dtype inference.

The registry allows one to map a string repr of a extension
The registry allows one to map a string repr of an extension
dtype to an extension dtype. The string alias can be used in several
places, including

Expand Down
2 changes: 1 addition & 1 deletion pandas/core/dtypes/dtypes.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ class CategoricalDtype(PandasExtensionDtype, ExtensionDtype):
The categories are stored in an Index,
and if an index is provided the dtype of that index will be used.
ordered : bool or None, default False
Whether or not this categorical is treated as a ordered categorical.
Whether or not this categorical is treated as an ordered categorical.
None can be used to maintain the ordered value of existing categoricals when
used in operations that combine categoricals, e.g. astype, and will resolve to
False if there is no existing ordered to maintain.
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/internals/construction.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def ndarray_to_mgr(
# GH#19157

if isinstance(values, (np.ndarray, ExtensionArray)) and values.ndim > 1:
# GH#12513 a EA dtype passed with a 2D array, split into
# GH#12513 an EA dtype passed with a 2D array, split into
# multiple EAs that view the values
# error: No overload variant of "__getitem__" of "ExtensionArray"
# matches argument type "Tuple[slice, int]"
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/window/expanding.py
Original file line number Diff line number Diff line change
Expand Up @@ -1454,7 +1454,7 @@ def corr(

class ExpandingGroupby(BaseWindowGroupby, Expanding):
"""
Provide a expanding groupby implementation.
Provide an expanding groupby implementation.
"""

__module__ = "pandas.api.typing"
Expand Down
2 changes: 1 addition & 1 deletion pandas/core/window/numba_.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def generate_numba_table_func(
"""
Generate a numba jitted function to apply window calculations table-wise.

Func will be passed a M window size x N number of columns array, and
Func will be passed an M window size x N number of columns array, and
must return a 1 x N number of columns array.

1. jit the user's function
Expand Down
2 changes: 1 addition & 1 deletion pandas/io/excel/_odswriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ def _process_style(self, style: dict[str, Any]) -> str: ...
def _process_style(self, style: None) -> None: ...

def _process_style(self, style: dict[str, Any] | None) -> str | None:
"""Convert a style dictionary to a OpenDocument style sheet
"""Convert a style dictionary to an OpenDocument style sheet

Parameters
----------
Expand Down
2 changes: 1 addition & 1 deletion pandas/io/json/_normalize.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def _simple_json_normalize(
sep: str = ".",
) -> dict | list[dict] | Any:
"""
A optimized basic json_normalize
An optimized basic json_normalize

Converts a nested dict into a flat dict ("record"), unlike
json_normalize and nested_to_record it doesn't do anything clever.
Expand Down
4 changes: 2 additions & 2 deletions pandas/plotting/_misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,12 +282,12 @@ def radviz(
"""
Plot a multidimensional dataset in 2D.

Each Series in the DataFrame is represented as a evenly distributed
Each Series in the DataFrame is represented as an evenly distributed
slice on a circle. Each data point is rendered in the circle according to
the value on each Series. Highly correlated `Series` in the `DataFrame`
are placed closer on the unit circle.

RadViz allow to project a N-dimensional data set into a 2D space where the
RadViz allow to project an N-dimensional data set into a 2D space where the
influence of each dimension can be interpreted as a balance between the
influence of all dimensions.

Expand Down
2 changes: 1 addition & 1 deletion pandas/tests/indexes/datetimes/test_date_range.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def test_date_range_multiplication_overflow(self):
# check that overflows in calculating `addend = periods * stride`
# are caught
with tm.assert_produces_warning(None):
# we should _not_ be seeing a overflow RuntimeWarning
# we should _not_ be seeing an overflow RuntimeWarning
dti = date_range(start="1677-09-22", periods=213503, freq="D")

assert dti[0] == Timestamp("1677-09-22")
Expand Down
2 changes: 1 addition & 1 deletion pandas/tests/reshape/test_melt.py
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,7 @@ def test_character_overlap(self):
tm.assert_frame_equal(result.sort_index(axis=1), expected.sort_index(axis=1))

def test_invalid_separator(self):
# if an invalid separator is supplied a empty data frame is returned
# if an invalid separator is supplied an empty data frame is returned
sep = "nope!"
df = DataFrame(
{
Expand Down
2 changes: 1 addition & 1 deletion pandas/tests/scalar/timestamp/test_constructors.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def test_constructor_int_float_with_YM_unit(self, typ):

@pytest.mark.parametrize("typ", [int, float])
def test_construct_from_int_float_with_unit_out_of_bound_raises(self, typ):
# GH#50870 make sure we get a OutOfBoundsDatetime instead of OverflowError
# GH#50870 make sure we get an OutOfBoundsDatetime instead of OverflowError
val = typ(150000000000000)

msg = f"cannot convert input {val} with the unit 'D'"
Expand Down
Loading