Package oms3.ngmf.util.cosu
Class Efficiencies
- java.lang.Object
-
- oms3.ngmf.util.cosu.Efficiencies
-
public class Efficiencies extends Object
- Author:
- od
-
-
Field Summary
Fields Modifier and Type Field Description static intABSMAXIMIZATIONstatic intABSMINIMIZATIONstatic intMAXIMIZATIONstatic intMINIMIZATION
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static doubleabsDiff(double[] obs, double[] sim)static doubleabsDiffLog(double[] obs, double[] sim)static doubleabsVolumeError(double[] obs, double[] sim)static doubledsGrad(double[] obs, double[] sim)static doubleioa(double[] obs, double[] sim, double pow)Calculates the index of agreement (ioa) between a test data set and a verification data set after Willmot & Wicks (1980).static double[]linearReg(double[] xData, double[] yData)Calcs coefficients of linear regression between x, y datastatic doublenashSutcliffe(double[] obs, double[] sim, double pow)Calculates the efficiency between a test data set and a verification data set after Nash & Sutcliffe (1970).static doublenashSutcliffeLog(double[] obs, double[] sim, double pow)Calculates the efficiency between the log values of a test data set and a verification data set after Nash & Sutcliffe (1970).static doublepbias(double[] obs, double[] sim)static doublepearsonsCorrelatrion(double[] obs, double[] sim)static doublermse(double[] obs, double[] sim)static doublerunoffCoefficientError(double[] obs, double[] sim, double[] precip)Runoff coefficient error ROCEstatic doubletransformedRmse(double[] obs, double[] sim)transformedRootMeanSquareError TRMSE
-
-
-
Field Detail
-
MAXIMIZATION
public static final int MAXIMIZATION
- See Also:
- Constant Field Values
-
MINIMIZATION
public static final int MINIMIZATION
- See Also:
- Constant Field Values
-
ABSMAXIMIZATION
public static final int ABSMAXIMIZATION
- See Also:
- Constant Field Values
-
ABSMINIMIZATION
public static final int ABSMINIMIZATION
- See Also:
- Constant Field Values
-
-
Method Detail
-
nashSutcliffe
public static double nashSutcliffe(double[] obs, double[] sim, double pow)Calculates the efficiency between a test data set and a verification data set after Nash & Sutcliffe (1970). The efficiency is described as the proportion of the cumulated cubic deviation between both data sets and the cumulated cubic deviation between the verification data set and its mean value.- Parameters:
sim- the simulation data setobs- the validation (observed) data setpow- the power for the deviation terms- Returns:
- the calculated efficiency or -9999 if an error occurs
-
nashSutcliffeLog
public static double nashSutcliffeLog(double[] obs, double[] sim, double pow)Calculates the efficiency between the log values of a test data set and a verification data set after Nash & Sutcliffe (1970). The efficiency is described as the proportion of the cumulated cubic deviation between both data sets and the cumulated cubic deviation between the verification data set and its mean value. If either prediction or validation has a value of <= 0 then the pair is ommited from the calculation and a message is put to system out.- Parameters:
sim- the simulation data setobs- the validation (observed) data setpow- the power for the deviation terms- Returns:
- the calculated log_efficiency or -9999 if an error occurs
-
ioa
public static double ioa(double[] obs, double[] sim, double pow)Calculates the index of agreement (ioa) between a test data set and a verification data set after Willmot & Wicks (1980). The ioa is described as the proportion of the cumulated cubic deviation between both data sets and the squared sum of the absolute deviations between the verification data set and the test mean value and the test data set and its mean value.- Parameters:
sim- the test Data setobs- the verification data setpow- the power- Returns:
- the calculated ioa or -9999 if an error occurs
-
linearReg
public static double[] linearReg(double[] xData, double[] yData)Calcs coefficients of linear regression between x, y data- Parameters:
xData- the independent data array (x)yData- the dependent data array (y)- Returns:
- (intercept, gradient, r?)
-
dsGrad
public static double dsGrad(double[] obs, double[] sim)- Parameters:
prediction-validation-- Returns:
-
absVolumeError
public static double absVolumeError(double[] obs, double[] sim)- Parameters:
prediction-validation-- Returns:
-
pbias
public static double pbias(double[] obs, double[] sim)- Parameters:
prediction-validation-- Returns:
-
rmse
public static double rmse(double[] obs, double[] sim)- Parameters:
prediction-validation-- Returns:
-
absDiffLog
public static double absDiffLog(double[] obs, double[] sim)- Parameters:
validation-prediction-missVal-- Returns:
-
absDiff
public static double absDiff(double[] obs, double[] sim)- Parameters:
validation-prediction-missVal-- Returns:
-
pearsonsCorrelatrion
public static double pearsonsCorrelatrion(double[] obs, double[] sim)- Parameters:
validation-prediction-missVal-- Returns:
-
transformedRmse
public static double transformedRmse(double[] obs, double[] sim)transformedRootMeanSquareError TRMSE- Parameters:
obs-sim-- Returns:
-
runoffCoefficientError
public static double runoffCoefficientError(double[] obs, double[] sim, double[] precip)Runoff coefficient error ROCE- Parameters:
obs-sim-precip-- Returns:
-
-