R/r-utility-type.R

Defines functions attr.type

Documented in attr.type

## get character-encoded attribute type information ("c" -- continuous, "d" -- discrete)
attr.type <- function(...)
{
  attr.type1 <- function(a) ifelse(is.numeric(a), "c", "d")
  paste(sapply(data.frame(...), attr.type1), collapse="")
}


if (FALSE)
{

  # usage examples
attr.type(weatherr$outlook, weatherr$playability)
attr.type(weatherr)

}
42n4/dmr.util documentation built on May 20, 2019, 2:02 p.m.