powered by
Squash one column in a data.frame using other columns as id.
squash(df, column, split = ",")
data.frame
column name, not numeric position
split string
df <- data.frame(a = c(1:2, 1:2), b = letters[1:4]) squash(df, "b", ",")
Run the code above in your browser using DataLab