list.zip: Combine multiple lists element-wisely.

Description Usage Arguments See Also Examples

View source: R/list.zip.R

Description

Combine multiple lists element-wisely.

Usage

1
list.zip(..., use.argnames = TRUE, use.names = TRUE)

Arguments

...

lists

use.argnames

logical. Should the names of the arguments be used as the names of list items?

use.names

logical. Should the names of the first argument be used as the zipped list?

See Also

list.unzip

Examples

1
2
3
x <- list(1,2,3)
y <- list('x','y','z')
list.zip(num=x,sym=y)

Example output

[[1]]
[[1]]$num
[1] 1

[[1]]$sym
[1] "x"


[[2]]
[[2]]$num
[1] 2

[[2]]$sym
[1] "y"


[[3]]
[[3]]$num
[1] 3

[[3]]$sym
[1] "z"

rlist documentation built on Sept. 5, 2021, 5:30 p.m.