Thanks @sparrow I used this to check datetime columns:
if len(df.select_dtypes(include='datetime').iloc[0].value_counts()) == 0:
print('DF DATETIME COLUMNS: ', len(df_dt.iloc[0].value_counts()))
None of the other methods (a.any (), a.empty () ...) worked. select returns with a non-empty index, but with empty columns, so I think it is. I think it really returns a series, hence a null character.
source
share