delete column names pandas code example
Example 1: drop a column in pandas
note: df is your dataframe
df = df.drop('coloum_name',axis=1)
Example 2: delete a row in pandas dataframe
df.drop(df.index[2])
Example 3: removing features pandas
df.drop([‘feature_1’,’feature_2’], inplace = True, axis = 1)
Example 4: how to delete a column from a dataframe in python
del df['column']