Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

remove columns that contain certain names in pandas

df = df.drop(df.filter(regex='Test').columns, axis=1)
Comment

pandas delete column by name

df = df.drop('column_name', axis=1)
Comment

PREVIOUS NEXT
Code Example
Python :: python selenium implicit wait 
Python :: creating dictionary using the keys 
Python :: move mouse round in python 
Python :: send email with flask 
Python :: legend of colorbar python 
Python :: The operands of the logical operators should be boolean expressions, but Python is not very strict. Any nonzero number is interpreted as True. 
Python :: is vowel python 
Python :: python convert string to date 
Python :: Python - Count the Number of Keys in a Python Dictionary 
Python :: from random import choice 
Python :: request.body django 
Python :: How do you find the missing number in a given integer array of 1 to 100? 
Python :: python list of all characters 
Python :: hmac in python 
Python :: encrypt string python 
Python :: does np.random.randint have a seed 
Python :: pytest parametrize 
Python :: python timestamp 
Python :: print value of tensor 
Python :: 2d array pytho 
Python :: convert pandas column type 
Python :: python bash command 
Python :: how to get a dataframe column as a list 
Python :: python turn true or false into 0 or 1 
Python :: timeit jupyter 
Python :: with urllib.request.urlopen("https:// 
Python :: python transpose list of lists 
Python :: merge and join dataframes with pandas in python 
Python :: find order of characters python 
Python :: show multiple matplotlib images 
ADD CONTENT
Topic
Content
Source link
Name
7+6 =