Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

drop column pandas

df.drop(['Col_1', 'Col_2'], axis = 1) # to drop full colum more general way can visulize easily

df.drop(['Col_1', 'Col_2'], axis = 1, inplace = True) # advanced : to generate df without making copies inside memory
Source by pandas.pydata.org #
 
PREVIOUS NEXT
Tagged: #drop #column #pandas
ADD COMMENT
Topic
Name
4+8 =