Interface RegressionMetric

All Superinterfaces:
Serializable, ToDoubleBiFunction<double[],double[]>
All Known Implementing Classes:
MAD, MSE, R2, RMSE, RSS

public interface RegressionMetric extends ToDoubleBiFunction<double[],double[]>, Serializable
An abstract interface to measure the regression performance.
  • Method Summary

    Modifier and Type
    Method
    Description
    default double
    applyAsDouble(double[] truth, double[] prediction)
     
    double
    score(double[] truth, double[] prediction)
    Returns a score to measure the quality of regression.
  • Method Details

    • score

      double score(double[] truth, double[] prediction)
      Returns a score to measure the quality of regression.
      Parameters:
      truth - the true response values.
      prediction - the predicted response values.
      Returns:
      the metric.
    • applyAsDouble

      default double applyAsDouble(double[] truth, double[] prediction)
      Specified by:
      applyAsDouble in interface ToDoubleBiFunction<double[],double[]>