Consider a dataframe like the following:
Key | Value
A | 1
A | 2
B | 2
C | 3
I want to filter this dataframe based on the condition that only get rows with the key where the key occurs more than once.
So the expected output is
Key | Value
A | 1
A | 2
What's the most succinct way of doing this in R? Looking for a generalized solution where count the count can be > n