pandas.arrays.DatetimeArray.dtype

DatetimeArray.dtype

The dtype for the DatetimeArray.

Warning

A future version of pandas will change dtype to never be a numpy.dtype. Instead, DatetimeArray.dtype will always be an instance of an ExtensionDtype subclass.

Returns:
numpy.dtype or DatetimeTZDtype

If the values are tz-naive, then np.dtype('datetime64[ns]') is returned.

If the values are tz-aware, then the DatetimeTZDtype is returned.

Scroll To Top