icb-stats API icb-stats-31 (20120309094430)

edu.cornell.med.icb.stat
Class AccuracyCalculator

java.lang.Object
  extended by edu.cornell.med.icb.stat.PredictionStatisticCalculator
      extended by edu.cornell.med.icb.stat.AccuracyCalculator

public class AccuracyCalculator
extends PredictionStatisticCalculator

Calculates the accuracy of predictions.

Author:
Fabien Campagne Date: Apr 23, 2008 Time: 3:23:25 PM

Field Summary
 
Fields inherited from class edu.cornell.med.icb.stat.PredictionStatisticCalculator
highestStatisticIsBest, optimalThreshold, statistic, zero
 
Constructor Summary
AccuracyCalculator()
           
 
Method Summary
 double evaluateAccuracy(double threshold, double[] decisionValues, double[] labels)
          Evaluate the accuracy for a given decision function threshold.
 double evaluateStatisticAtThreshold(double threshold, double[] decisionValues, double[] labels)
          Evaluate the statistic for a given decision function threshold.
 String getMeasureName()
           
 
Methods inherited from class edu.cornell.med.icb.stat.PredictionStatisticCalculator
evaluateContingencyTable, evaluateStatisticAtThreshold, predictivePotential, thresholdIndependentStatistic, thresholdIndependentStatistic, thresholdIndependentStatisticStd, thresholdIndependentStatisticSte
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AccuracyCalculator

public AccuracyCalculator()
Method Detail

getMeasureName

public String getMeasureName()
Specified by:
getMeasureName in class PredictionStatisticCalculator

evaluateAccuracy

public double evaluateAccuracy(double threshold,
                               double[] decisionValues,
                               double[] labels)
Evaluate the accuracy for a given decision function threshold.

Parameters:
threshold -
decisionValues -
labels -
Returns:
Accuracy of the prediction at threshold.

evaluateStatisticAtThreshold

public double evaluateStatisticAtThreshold(double threshold,
                                           double[] decisionValues,
                                           double[] labels)
Description copied from class: PredictionStatisticCalculator
Evaluate the statistic for a given decision function threshold.

Specified by:
evaluateStatisticAtThreshold in class PredictionStatisticCalculator

icb-stats API icb-stats-31 (20120309094430)

Copyright © 2008-2012 Institute for Computational Biomedicine, All Rights Reserved.