-
-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Closed
Labels
API - ConsistencyInternal Consistency of API/BehaviorInternal Consistency of API/BehaviorDeprecateFunctionality to remove in pandasFunctionality to remove in pandasIndexRelated to the Index class or subclassesRelated to the Index class or subclassesgood first issue
Description
Feature Type
-
Adding new functionality to pandas
-
Changing existing functionality in pandas
-
Removing existing functionality in pandas
Problem Description
I propose deprecating the mentioned methods on Index
.
I suggest dtype checking should be the same for indexes, series and arrays, so e.g. if users want to check the dtype of an index they should use the functions in pandas.api.types
, e.g. for numeric dtype checks, do pd.api.types.is_numeric_dtype(idx)
.
Feature Description
Deprecate the mentioned methods and make users use the functions they'd use for series, i.e. the dtype checking functions in pandas.api.types
.
Alternative Solutions
The alternative is not deprecating the methods...
Methods to deprecate:
- is_boolean (PR: DEPR: deprecate Index.is_boolean #50176)
- is_integer (PR: DEPR: deprecate Index.is_integer #50178)
- is_floating (PR: DEPR: deprecate Index.is_floating #50235)
- is_numeric (PR: DEPR: deprecate Index.is_numeric #50769)
- is_object (PR: DEPR: deprecate Index.is_object #50227)
- is_categorical (PR: DEPR: deprecate Index.is_categorical #50225)
- is_interval (PR: DEPR: deprecate Index.is_interval #50196)
Metadata
Metadata
Assignees
Labels
API - ConsistencyInternal Consistency of API/BehaviorInternal Consistency of API/BehaviorDeprecateFunctionality to remove in pandasFunctionality to remove in pandasIndexRelated to the Index class or subclassesRelated to the Index class or subclassesgood first issue