R/I_mapVarClass.R

Defines functions .mapVarClass

# Extract class of variable
.mapVarClass <- function(.cl){
  if( "integer" %in% .cl ){ return("numeric") }
  if( "numeric" %in% .cl ){ return("numeric") }
  if( "logical" %in% .cl ){ return("logical") }
  if( "factor" %in% .cl || "character" %in% .cl ){ return("factor") }
  return(.cl) # Not covered by mgcViz
}

Try the mgcViz package in your browser

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

mgcViz documentation built on Oct. 6, 2023, 5:09 p.m.