Uses of Class
org.tribuo.evaluation.metrics.MetricTarget
Package
Description
Evaluation classes for anomaly detection.
Evaluation classes for multi-class classification.
Evaluation classes for clustering.
This package contains the infrastructure classes for building evaluation metrics.
Evaluation classes for multi-label classification using
MultiLabel
.Evaluation classes for single or multi-dimensional regression.
-
Uses of MetricTarget in org.tribuo.anomaly.evaluation
ModifierConstructorDescriptionAnomalyMetric
(MetricTarget<Event> target, String name, ToDoubleBiFunction<MetricTarget<Event>, org.tribuo.anomaly.evaluation.AnomalyMetric.Context> impl) Creates an anomaly detection metric, with a specific name, using the supplied evaluation function.ModifierConstructorDescriptionAnomalyMetric
(MetricTarget<Event> target, String name, ToDoubleBiFunction<MetricTarget<Event>, org.tribuo.anomaly.evaluation.AnomalyMetric.Context> impl) Creates an anomaly detection metric, with a specific name, using the supplied evaluation function. -
Uses of MetricTarget in org.tribuo.classification.evaluation
Modifier and TypeMethodDescriptionLabelMetrics.getImpl()
Returns the implementing function for this metric.Modifier and TypeMethodDescriptionstatic <T extends Classifiable<T>>
doubleConfusionMetrics.accuracy
(MetricTarget<T> target, ConfusionMatrix<T> cm) Calculates the accuracy given this confusion matrix.static double
LabelMetrics.AUCROC
(MetricTarget<Label> tgt, List<Prediction<Label>> predictions) Area under the ROC curve.static double
LabelMetrics.averagedPrecision
(MetricTarget<Label> tgt, List<Prediction<Label>> predictions) static <T extends Classifiable<T>>
doubleConfusionMetrics.f1
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Computes the F_1 score.static <T extends Classifiable<T>>
doubleConfusionMetrics.fn
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Returns the number of false negatives, possibly averaged depending on the metric target.LabelMetrics.forTarget
(MetricTarget<Label> tgt) Gets the LabelMetric wrapped around the supplied MetricTarget.static <T extends Classifiable<T>>
doubleConfusionMetrics.fp
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Returns the number of false positives, possibly averaged depending on the metric target.static <T extends Classifiable<T>>
doubleConfusionMetrics.fscore
(MetricTarget<T> tgt, ConfusionMatrix<T> cm, double beta) Computes the Fscore.static <T extends Classifiable<T>>
doubleConfusionMetrics.precision
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Calculates the precision for this metric target.static <T extends Classifiable<T>>
doubleConfusionMetrics.recall
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Calculates the recall for this metric target.static <T extends Classifiable<T>>
doubleConfusionMetrics.tn
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Returns the number of true negatives, possibly averaged depending on the metric target.static <T extends Classifiable<T>>
doubleConfusionMetrics.tp
(MetricTarget<T> tgt, ConfusionMatrix<T> cm) Returns the number of true positives, possibly averaged depending on the metric target.ModifierConstructorDescriptionLabelMetric
(MetricTarget<Label> tgt, String name, ToDoubleBiFunction<MetricTarget<Label>, LabelMetric.Context> impl) Construct a newLabelMetric
for the supplied metric target, using the supplied function.ModifierConstructorDescriptionLabelMetric
(MetricTarget<Label> tgt, String name, ToDoubleBiFunction<MetricTarget<Label>, LabelMetric.Context> impl) Construct a newLabelMetric
for the supplied metric target, using the supplied function. -
Uses of MetricTarget in org.tribuo.clustering.evaluation
Modifier and TypeMethodDescriptionBiFunction<MetricTarget<ClusterID>,
org.tribuo.clustering.evaluation.ClusteringMetric.Context, Double> ClusteringMetrics.getImpl()
Gets the implementing function for this metric.Modifier and TypeMethodDescriptionClusteringMetrics.forTarget
(MetricTarget<ClusterID> tgt) Constructs the metric for the specified metric target.ModifierConstructorDescriptionClusteringMetric
(MetricTarget<ClusterID> target, String name, BiFunction<MetricTarget<ClusterID>, org.tribuo.clustering.evaluation.ClusteringMetric.Context, Double> impl) Constructs a clustering metric using the supplied parameters.ModifierConstructorDescriptionClusteringMetric
(MetricTarget<ClusterID> target, String name, BiFunction<MetricTarget<ClusterID>, org.tribuo.clustering.evaluation.ClusteringMetric.Context, Double> impl) Constructs a clustering metric using the supplied parameters. -
Uses of MetricTarget in org.tribuo.evaluation.metrics
Modifier and TypeMethodDescriptionEvaluationMetric.getTarget()
The target for this metric instance.static <U extends Output<U>>
MetricTarget<U>MetricTarget.macroAverageTarget()
Get the singletonMetricTarget
which contains theEvaluationMetric.Average.MACRO
.static <U extends Output<U>>
MetricTarget<U>MetricTarget.microAverageTarget()
Get the singletonMetricTarget
which contains theEvaluationMetric.Average.MICRO
.ModifierConstructorDescriptionMetricID
(MetricTarget<T> target, String metricName) Constructs a metric id. -
Uses of MetricTarget in org.tribuo.multilabel.evaluation
Modifier and TypeMethodDescriptionBiFunction<MetricTarget<MultiLabel>,
org.tribuo.multilabel.evaluation.MultiLabelMetric.Context, Double> MultiLabelMetrics.getImpl()
Get the implementation function for this metric.Modifier and TypeMethodDescriptionMultiLabelMetrics.forTarget
(MetricTarget<MultiLabel> tgt) Get the metric for the supplied target.ModifierConstructorDescriptionMultiLabelMetric
(MetricTarget<MultiLabel> target, String name, BiFunction<MetricTarget<MultiLabel>, org.tribuo.multilabel.evaluation.MultiLabelMetric.Context, Double> impl) Constructs a multi-label metric.ModifierConstructorDescriptionMultiLabelMetric
(MetricTarget<MultiLabel> target, String name, BiFunction<MetricTarget<MultiLabel>, org.tribuo.multilabel.evaluation.MultiLabelMetric.Context, Double> impl) Constructs a multi-label metric. -
Uses of MetricTarget in org.tribuo.regression.evaluation
Modifier and TypeMethodDescriptionstatic double
RegressionMetrics.explainedVariance
(MetricTarget<Regressor> target, RegressionSufficientStatistics sufficientStats) Calculates the explained variance based on the supplied statistics.static double
RegressionMetrics.mae
(MetricTarget<Regressor> target, RegressionSufficientStatistics sufficientStats) Calculates the Mean Absolute Error based on the supplied statistics.static double
RegressionMetrics.r2
(MetricTarget<Regressor> target, RegressionSufficientStatistics sufficientStats) Calculates R^2 based on the supplied statistics.static double
RegressionMetrics.rmse
(MetricTarget<Regressor> target, RegressionSufficientStatistics sufficientStats) Calculates the RMSE based on the supplied statistics.ModifierConstructorDescriptionRegressionMetric
(MetricTarget<Regressor> tgt, String name, ToDoubleBiFunction<MetricTarget<Regressor>, org.tribuo.regression.evaluation.RegressionMetric.Context> impl) Construct a newRegressionMetric
for the supplied metric target, using the supplied function.RegressionMetric
(MetricTarget<Regressor> tgt, String name, ToDoubleBiFunction<MetricTarget<Regressor>, org.tribuo.regression.evaluation.RegressionMetric.Context> impl, boolean useExampleWeights) Construct a newRegressionMetric
for the supplied metric target, using the supplied function.ModifierConstructorDescriptionRegressionMetric
(MetricTarget<Regressor> tgt, String name, ToDoubleBiFunction<MetricTarget<Regressor>, org.tribuo.regression.evaluation.RegressionMetric.Context> impl) Construct a newRegressionMetric
for the supplied metric target, using the supplied function.RegressionMetric
(MetricTarget<Regressor> tgt, String name, ToDoubleBiFunction<MetricTarget<Regressor>, org.tribuo.regression.evaluation.RegressionMetric.Context> impl, boolean useExampleWeights) Construct a newRegressionMetric
for the supplied metric target, using the supplied function.