All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ngmf.util.cosu.luca.of.NS2LOG Maven / Gradle / Ivy

/*
 * $Id: NS2LOG.java a4500310d299 2013-03-13 [email protected] $
 * 
 * This file is part of the Object Modeling System (OMS),
 * 2007-2012, Olaf David and others, Colorado State University.
 *
 * OMS is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation, version 2.1.
 *
 * OMS is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with OMS.  If not, see .
 */
package ngmf.util.cosu.luca.of;

import oms3.ObjectiveFunction;
import oms3.util.Statistics;

/**
 *
 */
public class NS2LOG implements ObjectiveFunction {


    @Override
    public double calculate(double[] obs, double[] sim, double missing)  {
        return Statistics.nashSutcliffeLog(obs, sim, 2.0, missing);
    }
 
    @Override
    public boolean positiveDirection() {
        return true;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy