| prediction.variable.balance {traineR} | R Documentation | 
prediction.variable.balance
Description
Function that graphs the balance of the different categories of a column of a data frame.
Usage
prediction.variable.balance(
  data,
  predict.variable,
  ylab = "Number of individuals",
  xlab = "",
  main = paste("Variable Distribution", predict.variable),
  col = NA
)
Arguments
data | 
 A data frame.  | 
predict.variable | 
 Character type. The name of the variable to predict. This name must be part of the columns of the data frame.  | 
ylab | 
 A character string that describes the y-axis on the graph.  | 
xlab | 
 A character string that describes the x-axis on the graph.  | 
main | 
 Character type. The main title of the chart.  | 
col | 
 A vector that specifies the colors of the categories represented by bars within the chart.  | 
Value
A ggplot object.
Note
With this function we can identify if the data is balanced or not, according to the variable to be predicted.
See Also
Examples
prediction.variable.balance(iris,"Species")
[Package traineR version 2.2.0 Index]