Quantcast
Viewing latest article 2
Browse Latest Browse All 4

Answer by Onyambu for Match observations in two dataframes in R

using base R:

split(df2,df2[,1])[by(df2[2],df2[1],function(x)all(x==df1))] $`1`   setID    col1 1     1  apples 2     1 oranges 3     1  apples 4     1  banana

Viewing latest article 2
Browse Latest Browse All 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>