A plyr
/dplyr
-based solution:
library(dplyr)news <- data.frame(date=c("2016-05-20","2016-05-19","2016-05-19"), letters=c("x","y","z"), stringsAsFactors = FALSE)data <- data.frame(date=c("2016-05-20","2016-05-21","2016-05-22"), numbers=c(1,2,3), stringsAsFactors = FALSE)df <- plyr::rbind.fill(news,data)df.combined <- df %>% group_by(date) %>% summarize_each(funs(paste(na.omit(.), collapse="&& ")), letters:numbers)