I have two dataframes with same format looking like this:
df1)
name value score
a 2 0.01
b 2 2.25
c 1 5.24
df2)
name value score
A 2 -8.01
B 2 -3.25
C 1 -2.24
I want to merge these two list according to the absolute value of "score" column
output)
name value score
A 2 -8.01
c 1 5.24
B 2 -3.25
b 2 2.25
C 1 -2.24
a 2 0.01
Would there be a simple r code for this? I would appreciate any help. Thanks