powered by
Weighted average of unit Bernoulli deviance, defined as twice logLoss.
deviance_bernoulli(actual, predicted, w = NULL, ...)
Observed values.
Predicted values.
Optional case weights.
Further arguments passed to logLoss.
logLoss
A numeric vector of length one.
logLoss.
# NOT RUN { deviance_bernoulli(c(0, 0, 1, 1), c(0.1, 0.1, 0.9, 0.8)) deviance_bernoulli(c(1, 0, 0, 1), c(0.1, 0.1, 0.9, 0.8)) deviance_bernoulli(c(0, 0, 1, 1), c(0.1, 0.1, 0.9, 0.8), w = 1:4) # }
Run the code above in your browser using DataLab