I want to delete some rows in a pandas DataFrame.
id marks
1 123 45
2 124 67
3 127 89
4 257 10
5 345 34
delRows = [123,127]
output should be -
id marks
2 124 67
4 257 10
5 345 34
Can anyone tell how to do it?
df = df[df.id != delRows]
Is it the right way to do it???