I have 2 data frames, df1 and df2 both having columns 'A', 'count'. I want to join these based on column A and then subtract count from those rows if column is same. So for example:
df1
A count
s1 10
s2 5
s3 3
s4 7
df2
A count
s1 2
s4 4
My final output should be
combined
A count1 count2 change
s1 10 2 8 // count1-count2
s2 5 none none
s3 3 none none
s4 7 4 3