nlist: Named lists

Description Usage Arguments Value Author(s) See Also Examples

Description

Create a named list using specified names or, if names are omitted, using the names of the objects in the list. The code list(a = a, b = b) becomes nlist(a,b) and list(a = a, b = 2) becomes nlist(a, b = 2), etc.

Usage

1

Arguments

...

Objects to include in the list.

Value

A named list.

Author(s)

Jonah Gabry

See Also

list

Examples

1
2
3
4
5
6
7
# All variables already defined
a <- rnorm(100)
b <- mat.or.vec(10, 3)
nlist(a,b)

# Define some variables in the call and take the rest from the environment
nlist(a, b, veggies = c("lettuce", "spinach"), fruits = c("banana", "papaya"))


Search within the loo package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.