I have two data frames with same column but different values, out of which some are same and some are different. I want to compare both columns and keep the common values.
df1
:
A B C
1 1 1
2 4 6
3 7 9
4 9 0
6 0 1
df2
:
A D E
1 5 7
5 6 9
2 3 5
7 6 8
3 7 0
This is what I am expecting after comparison
df2
:
A D E
1 5 7
2 3 5
3 7 0