I'm looking at a way to turn a named list into a data frame. I have not found similar examples in my search for named list to DF conversion.
My named list is akin to this:
namedList = list(
A = c("a", "b", "c", "d", "g"),
B = c("a", "c", "d", "e"))
> namedList
$A
[1] "a" "b" "c" "d" "g"
$B
[1] "a" "c" "d" "e"
I would like to obtain a data frame like this:
> dataFrame
item names
1 a A
2 b A
3 c A
4 d A
5 g A
6 a B
7 c B
8 d B
9 e B
Thank you.