pandas删除特定值的行

方法一、

# 取出列名score值不为1的行
df[df.score.isin([1]) == False]

方法二、

# 取出列名score列值不为1的行
df[(df.score != 1)]

猜你喜欢

转载自blog.csdn.net/qq236237606/article/details/129735852