df1 <- data.table(x = c("a", "a", "b", "c"), y = 1:4)
df2 <- data.table(x = c("a", "b"), z = 5:6)
df1 %>% left_join.(df2)
df1 %>% inner_join.(df2)
df1 %>% right_join.(df2)
df1 %>% full_join.(df2)
df1 %>% anti_join.(df2)
Run the code above in your browser using DataLab