Class RMSE


public class RMSE extends ErrorCalculationMethod
Methods for calculating the root mean squared error See D. Wallach, Working with Dynamic Crop Models, p. 22
Author:
Gunther Krauss
  • Constructor Details

    • RMSE

      public RMSE()
  • Method Details

    • addDataPair

      public void addDataPair(double observed, double calculated)
      Description copied from class: ErrorCalculationMethod
      Adds a pair of observed and calculated values.
      Specified by:
      addDataPair in class ErrorCalculationMethod
      Parameters:
      observed - the observed (measured) value
      calculated - the calculated (simulated) value
    • getValue

      public double getValue()
      Description copied from class: ErrorCalculationMethod
      Calculates the measure from the added pairs.
      Specified by:
      getValue in class ErrorCalculationMethod
      Returns:
      the value of the measure (the worst value if no pairs were added)
    • isBetter

      public boolean isBetter(double better, double worse)
      Description copied from class: ErrorCalculationMethod
      Checks if the first value is better than the second one with respect to the calculation method (e.g. smaller for errors, closer to 1 for model efficiency).
      Specified by:
      isBetter in class ErrorCalculationMethod
      Parameters:
      better - the value that is checked to be better
      worse - the value to compare with
      Returns:
      true if the first value is better than the second
    • getLabel

      public String getLabel()
      Specified by:
      getLabel in class ErrorCalculationMethod
      Returns:
      the label (abbreviation) of the calculation method, e.g. RMSE
    • getDescription

      public String getDescription()
      Overrides:
      getDescription in class ErrorCalculationMethod
      Returns:
      the full name or a short description of the method (empty by default)