I extracted a dataset (B) from another more bigger (A) like this:
B=A[A$var2 %in% as.vector(C$var),]
up to here no problem, I have what I want, bu