r merge columns into one code example
Example 1: combine columns in r
df.1 <- data.frame("Name" = c("Jill","Jack","John"))
df.2 <- data.frame("Age" = c(42,16,63))
df.comb <- cbind(df.1,df.2)
Example 2: how to combine all columns into one column in r
unite(data, col, ..., sep = "_", remove = TRUE, na.rm = FALSE)