![]() |
slope 6.6.0
|
Area Under the ROC Curve (AUC-ROC) scoring metric. More...
#include <score.h>


Public Member Functions | |
| double | eval (const Eigen::MatrixXd &eta, const Eigen::MatrixXd &y, const std::unique_ptr< Loss > &loss) const override |
| double | eval (const Eigen::MatrixXd &eta, const Eigen::MatrixXd &y, const std::unique_ptr< Loss > &loss, const Eigen::VectorXd &observation_weights) const override |
| Public Member Functions inherited from slope::MaximizeScore | |
| bool | isWorse (double a, double b) const override |
| double | initValue () const override |
| Public Member Functions inherited from slope::Score | |
| std::function< bool(double, double)> | getComparator () const |
Additional Inherited Members | |
| Static Public Member Functions inherited from slope::Score | |
| static std::unique_ptr< Score > | create (const std::string &metric) |
Area Under the ROC Curve (AUC-ROC) scoring metric.
Computes the area under the Receiver Operating Characteristic curve, which plots the true positive rate against false positive rate at various classification thresholds. Inherits from MaximizeScore since higher AUC values indicate better discriminative ability.
For binary classification:
For multi-class problems:
|
overridevirtual |
Evaluates the AUC-ROC score for predictions.
| eta | Matrix of model predictions/probabilities |
| y | Matrix of true labels (one-hot encoded) |
| loss | Loss function used to transform predictions if needed |
Implements slope::Score.
|
overridevirtual |
Evaluates the metric with observation weights. Empty weights select the unweighted metric. Weights must be finite and nonnegative, and their sum must be positive. Multiplying every weight by a positive constant leaves the score unchanged. Custom metrics can override this overload; the default implementation accepts uniform weights only.
Reimplemented from slope::Score.