What I mean is that let's say we have the following dataframe:
UID A
1 Yes
1 No
2 No
2 No
3 Yes
3 No
4 Yes
4 Yes
I want to produce a dataframe where any UID that has a yes is included, even the other instances of the UID is a "No".
UID A
1 Yes
1 No
3 Yes
3 No
4 Yes
4 Yes
Is there a way to do this using Pandas or any other library in python?