def get_column_names_by_type(df, dtype): return [c for c in df.columns if np.issubdtype(df.dtypes[c], dtype)]