Skip to content

Commit 8d38d4e

Browse files
phoflmeeseeksmachine
authored andcommitted
Backport PR pandas-dev#52949: DOC: Clean up for deprecations
1 parent 91757c5 commit 8d38d4e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/core/indexes/base.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -2521,7 +2521,7 @@ def is_categorical(self) -> bool:
25212521
Check if the Index holds categorical data.
25222522
25232523
.. deprecated:: 2.0.0
2524-
Use :meth:`pandas.api.types.is_categorical_dtype` instead.
2524+
Use `isinstance(index.dtype, pd.CategoricalDtype)` instead.
25252525
25262526
Returns
25272527
-------
@@ -2574,7 +2574,7 @@ def is_interval(self) -> bool:
25742574
Check if the Index holds Interval objects.
25752575
25762576
.. deprecated:: 2.0.0
2577-
Use `pandas.api.types.is_interval_dtype` instead.
2577+
Use `isinstance(index.dtype, pd.IntervalDtype)` instead.
25782578
25792579
Returns
25802580
-------

0 commit comments

Comments
 (0)