Closed
Description
xref #22137
def is_datetimelike(arr):
""" [...] """
return (is_datetime64_dtype(arr) or is_datetime64tz_dtype(arr) or
is_timedelta64_dtype(arr) or
isinstance(arr, ABCPeriodIndex) or
is_datetimetz(arr))
is_datetimetz
is AFAICT redundant with is_datetime64tz_dtype
, so ignore that part for now. Shouldn't the ABCPeriodIndex
check be the more general is_period_dtype
? Or for that matter, is_period_arraylike
?
cc: @TomAugspurger