nlist: Create a named list using an existing object or data frame

Description Usage Arguments Value Examples

View source: R/utils.R

Description

The name is short for: (n)amed (list)

Usage

1
nlist(x = NULL, values.col = NULL, names.col = NULL)

Arguments

x

object, can be vector, matrix, or data.frame

values.col

character, identifies source of values for the list

names.col

charcter, identifies source of names for the list

Value

named list

Examples

1
2
nlist(c("a", "b", "c"))
nlist(values=c(1,2,3), names=c("x", "y", "z"))

tkonopka/shrt documentation built on March 5, 2020, 2:51 p.m.