Hi I have two data set where the first one is a set of index:
ind1<-rep(c(\"E\",\"W\"), times=20) ind2<-sample(100:150, 40) y<-c(1:40) index<-dat
you can use also left_join() from dplyr package:
left_join()
dplyr
require(dplyr) left_join(data, index, by = c("x1" = "ind1", "x2" = "ind2"))
read more here