R/utils.R

Defines functions has_attr

# test if object has attribute
#
# @param x object
# @param which character; names of possible attributes
#
# @note not exported

has_attr <- function(x, which) {

  which %in% names( attributes(x) )

}

Try the sticky package in your browser

Any scripts or data that you put into this service are public.

sticky documentation built on April 14, 2020, 6:34 p.m.