org.apache.ignite.ml.selection.scoring.metric

## Interface Metric<L,C extends EvaluationContext<L,C>,A extends MetricStatsAggregator<L,C,A>>

- Type Parameters:
    `L` - Type of label.
    `C` - Type of evaluation context.
    `A` - Type of statistics aggregator.
  All Superinterfaces:
    Serializable
  All Known Implementing Classes:
    Accuracy, BalancedAccuracy, BinaryClassificationMetric, FallOut, FalseNegativeAbsoluteValue, FalsePositiveAbsoluteValue, Fdr, FMeasure, Mae, MissRate, Mse, Npv, Precision, R2, Recall, Rmse, Rss, Specificity, TrueNegativeAbsoluteValue, TruePositiveAbsoluteValue

      public interface Metric<L,C extends EvaluationContext<L,C>,A extends MetricStatsAggregator<L,C,A>>
      extends Serializable

  This class represents a container with computed value of metric and it provides a factory for metric statistics aggregation class.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `Metric<L,C,A>` | `initBy(A aggr)` Initializes metric value by statistics aggregator.
    `A` | `makeAggregator()` Creates statistics aggregator.
    `MetricName` | `name()` Returns metric name.
    `double` | `value()` Returns metric value.

- - ### Method Detail

    - #### makeAggregator

          A makeAggregator()

      Creates statistics aggregator.
      Returns:
        Statistics aggregator

    - #### initBy

          Metric<L,C,A> initBy(A aggr)

      Initializes metric value by statistics aggregator.
      Parameters:
        `aggr` - Aggregator.

    - #### value

          double value()

      Returns metric value.
      Returns:
        Metric value.

    - #### name

          MetricName name()

      Returns metric name.
      Returns:
        Metric name.

2022 Copyright © Apache Software Foundation
| Follow @ApacheIgnite
Ignite Database and Caching Platform | : ver. 2.12.0
Release Date | : January 10 2022