<human>:  How do I filter a pandas DataFrame based on value counts?
<bot>: Here is some code to filter dataframe `df` by values in column `A` that appear more than once

df.groupby('A').filter(lambda x: len(x) > 1)

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.