Created
June 10, 2021 03:44
-
-
Save Nithilaa/5cc44b3dd86fbba83b9e114937aba0a3 to your computer and use it in GitHub Desktop.
drop numeric columns
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
df_tf_m_columns = df_tf_m.columns | |
df_tf_m_columns | |
res = [sub for sub in df_tf_m_columns if sub.isalpha()] | |
res.append('Flag_1') | |
df_tf_m = df_tf_m.drop(columns=[col for col in df_tf_m if col not in res]) | |
df_tf_m.head() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment