I have a dataframe having two columns "Service" and "Value". I want to remove all the rows having "0" under value column.
service value
abc 10
def 0
ghi 0
xyz 5
I want my dataframe looks like
service value
abc 10
xyz 5
I tried the following
df = df[(df != 0).all(1)]
df = pd.DataFrame(list(result.items()),columns=['service', 'value'])
df = df[(df != 0).all(1)]
For small Dataframe having 6-7 rows it's working fine but in another Dataframe having 125 rows I am getting the following error.
Illegal instruction
PS: I checked all the values under "value" column and these are numbers.