
Last chance! 50% off unlimited learning
Sale ends in
Unlists a column stored as a list
into a long form.
listCol_l(inDT, listcol, drop = TRUE)
The input dataset.
The name of the column stored as a list
.
Logical. Should the original column be dropped? Defaults to TRUE
.
A data.table
.
listCol_w
to flatten a list
column into a "wide" format.
# NOT RUN {
dat <- data.frame(A = 1:3, B = I(list(c(1, 2), c(1, 3, 5), c(4))))
listCol_l(dat, "B")
# }
Run the code above in your browser using DataLab