how to filter a dataframe pandas code example
Example 1: pandas column filter
filter = df['column']!= 0
df = df[filter]
Example 2: pandas filter
df[(df['year'] > 2012) & (df['reports'] < 30)]
filter = df['column']!= 0
df = df[filter]
df[(df['year'] > 2012) & (df['reports'] < 30)]