Answers for "which column not contains string pandas"

11

dataframe column contains string

df[df['A'].str.contains("hello")]
Posted by: Guest on September-28-2020
0

pandas string does not contain

# simply use the invert operator '~' with 'str.contains'
new_df = df[~df["col"].str.contains(word)]
Posted by: Guest on November-05-2020

Code answers related to "which column not contains string pandas"

Python Answers by Framework

Browse Popular Code Answers by Language