I have a dataframe df1:
site cell
T96976 V96976A
T96976 V96976B
T96976 V96976C
T96976 V96976O
T96980 D96980A
T96980 D96980B
T96980 U96980C
T97750 D97750N
T97750 D97750A
T97750 D97750B
T97750 V97750O
T97760 V97760A
T97760 V97760B
T97777 L97777A
T97777 U97777B
T97777 V97777C
T99989 G99989P
I want dataframe df2 such that if I find a cell ending with 'N' or 'O' or P' then I have to delete all the cells having the same site.
Hence my resultant dataframe df2 should have something like this:
site cell
T96980 D96980A
T96980 D96980B
T96980 U96980C
T97760 V97760A
T97760 V97760B
T97777 L97777A
T97777 U97777B
T97777 V97777C