is.items: Get the types of all items in a list

Description Usage Arguments Value Examples

View source: R/utilities.R

Description

Get the types of all items in a list

Usage

1
is.items(list, ..., FUN = is)

Arguments

list

A ['list'] to get the types from

...

['pairlist'] Additional arguments to FUN

FUN

['function'] or ['character'] Either a function, or the name of a function which returns a single logical value. The default function uses 'is', specify the desired type in '...'. You can also use other type checking functions such as is.character, is.numeric, or is.data.frame.

Value

['logical'] A vector indicating if the list item is the specified type.

Examples

1
2
list <- list(c(1,2,3), c('a','b','c'))
is.items(list, 'character')

CoreGx documentation built on Nov. 8, 2020, 4:50 p.m.