I have 2 data frames df1 and df2.
df1
df2
df1 <- data.frame(c1=c(\"a\",\"b\",\"c\",\"d\"),c2=c(1,2,3,4) ) df2 <- data.frame(c1=c(\"
You can check the values in both columns and subset like this (just adding another solution):
na.omit( df1[ sapply( 1:ncol(df1) , function(x) ! df1[,x] %in% df2[,x] ) , ] ) # c1 c2 #1 a 1 #2 b 2