Implements a slightly modified version of the reweighter described in the Adaboost.M1 algorithm.
a vector of predictions.
a vector whose ith component is the true
response for the ith component of
a vector of weights. They don't necessarily need to sum to 1.
implemented to allow reweighter to accept its output as its input.
The modification of the reweighter comes in to play when
ε = 0. This is when the esimator correctly
classifies every observation in the learning set. Consequently, we're
supposed to define
α = log(1-ε) - log(ε)
However, this is +∞, which is not a number R is used
to working with. To work around this, we have to create a conditional statement
alpha <- log(.Machine$double.xmax) and let the algorithm
proceed as originally described. The effect of this modification is the following:
the update that's supposed to be made to
weights, which is a
alpha, effectively keeps
weights as they were
if you pair this reweighter with
the estimator associated to this very large
alpha now has tremendous
weight inside the weighted sum in the aggregator. This isn't, necessarily,
a bad thing – the estimator classified every observation in
For internal bookkeeping, this function is inherits from the
reweighter' class. It returns a named list with components
the updated weights calculated from the input weights,
performance measure of
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.