Description Usage Arguments Value Examples
Flatten a list of length one to data frame by respecting data types (lists of greater length might not work as expexted)
1 | flatten(x)
|
x |
list |
data.frame of input
1 2 3 4 5 6 7 8 | flatten(list(list(a = 1, b = list(c = "c", d = TRUE)), list(a = 1, b = list(c = "c", d = TRUE))))
flatten(list(a = list(b = list(c = list(d = 1, e = FALSE), g = "tata")) ))
# if there is multi length vector inside the list --> multiple lines
flatten(list(a = list(b = list(c = list(d = 1, e = FALSE), g = "tata"), h = 1:2) ))
# what if no name
flatten(list(1, 2, 3))
# partial names
flatten(list(1, 2, c = 3))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.