I would like to check if I have the same identification (ID) for the 2 groups. For example:
ID group
A1 1
A1 1
A1 1
A2 2
A2 2
A2 1
A3 3
A3 3
A3 3
Please, notice that I had one ID = A2 associated with group 1 and 2.
My question is: how can I identify this kind of situation in my database using an R code?
I'd like to filter if I have my unique ID contained in two groups.
Thank you!