.information_gain | R Documentation |
Direct Interface to Information Gain.
.information_gain(
x,
y,
type = c("infogain", "gainratio", "symuncert"),
equal = FALSE,
discIntegers = TRUE,
nbins = 5,
threads = 1
)
x |
A data.frame, sparse matrix or formula with attributes. |
y |
A vector with response variable or data.frame if formula is used. |
type |
Method name. |
equal |
A logical. Whether to discretize dependent variable with the
|
discIntegers |
logical value. If true (default), then integers are treated as numeric vectors and they are discretized. If false integers are treated as factors and they are left as is. |
nbins |
Number of bins used for discretization. Only used if 'equal = TRUE' and the response is numeric. |
threads |
defunct. Number of threads for parallel backend - now turned off because of safety reasons. |
In principle using information_gain
is safer.
data.frame with the following columns:
attributes - variables names.
importance - worth of the attributes.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.