| gini_impurity | R Documentation |
Gini impurity
gini_impurity(x)
x |
A vector of values, usually character labels as raw instances or as class frequencies. |
Gini impurity is the probability of how often a randomly chosen element from a set x would be
incorrectly labeled if it was randomly labeled according to the distribution of labels in the set. So, impurity is
the probability of being incorrect if a label is randomly assigned to a sample of x.
The Gini impurity.
https://victorzhou.com/blog/gini-impurity/
Other Metrics:
accuracy(),
cross_entropy(),
dice(),
entropy(),
erf(),
erfc(),
erfcinv(),
erfinv(),
huber_loss(),
iou(),
log_cosh_loss(),
mae(),
mape(),
mse(),
msle(),
quantile_loss(),
rmse(),
rmsle(),
rmspe(),
sse(),
stderror(),
vc(),
wape(),
wmape()
gini_impurity(c("dog", "dog", "cat", "mouse"))
gini_impurity(c(dog = 2, cat = 1, mouse = 1))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.