Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

if a specific column name is present drop tyhe column

df.columns.str.startswith('Test')
# array([ True, False, False, False])

df.loc[:,~df.columns.str.startswith('Test')]

  toto test2 riri
0    x     x    x
1    x     x    x
 
PREVIOUS NEXT
Tagged: #specific #column #present #drop #tyhe #column
ADD COMMENT
Topic
Name
2+5 =