Compare each element in same column with other set of records

Type Col1 Col2 Col3 Result
Object 1 A B F 1,0,1
Object 1 B D S 0,1,0
Object 1 C F R 0,0,0
Object 1 D D D 1,1,1
Object 2 A F F 1,0,1
Object 2 D D D 1,1,1

I have above data frame in which need to populate Result column based on the comparison between element to element in the same column from two different Types like object 1 and object 2 as mentioned above.

Can anyone help me in getting expected results. The exact requirement is find the unmatched element in the same column from second set of record ( here object 2 ).

Appreciate any solutions with package or without package.

Hi @Janakiram

I think it would help if you provided a minimal reprex with the example you gave along with the desired output. I am having a tough time trying to figure out what you want in your Result column.

1 Like