Linked Questions

Popular Questions

I am trying to search for a single criteria throughout multiple dataframe columns using Python. The script I am using is not giving me the output I would hope for. The code is the following:

df = df[df['Account Category' or 'Account Category 2' or 'Account Category 3'] == " and Pantry"]

The criteria I am searching for appears in multiple columns. However, with this code, it is only showing that criteria for the first column. Any help would be appreciated

Related Questions