dataFrameToVariableIfAppropriate: #' Converts a factor into an indicator matrix. #' #' @param...

Description Usage Arguments

View source: R/transformations.R

Description

Converts an ordered factor into a numeric variable #' #' @param ordered.factor A variable in a DataSet or data.frame. #' @export OrderedToNumeric <- function(ordered.factor) return(unclass(ordered.factor)) #' Converts a an ordered factor into a numeric variable #' #' @param variable A variable in a DataSet or data.frame. #' @param variable.name The name of the variable. #' @export FactorToNumeric <- function(variable, variable.name = deparse(substitute(variable))) if (is.ordered(variable)) return(OrderedToNumeric(variable)) return(FactorToIndicators(variable, variable.name)) #' Converts a data frame into a vector if it only contains a single variable.

Usage

1

Arguments

data.frame.object

A data.frame.


Displayr/flipRegression documentation built on April 27, 2018, 4:48 a.m.