all_are: all_are

Description Usage Arguments Value Examples

View source: R/utils.R

Description

Checks if all elements of a list or List are of a (single) particular type typechar

Usage

1
all_are(inplist, typechar)

Arguments

inplist

list or List to be checked

typechar

char of the type to check for

Value

boolean, for whether the elements of inplist are all typechar

Examples

1
2
3
4
5
6
7
x <- list(1,2)
all_are(x,'numeric')
all_are(x,'char')

y <- list(1,2,'c')
all_are(y,'numeric')
all_are(y,'char')

corral documentation built on Nov. 8, 2020, 8:25 p.m.