类 CostCurve

java.lang.Object
weka.classifiers.evaluation.CostCurve
所有已实现的接口:
RevisionHandler

public class CostCurve extends Object implements RevisionHandler
Generates points illustrating probablity cost tradeoffs that can be obtained by varying the threshold value between classes. For example, the typical threshold value of 0.5 means the predicted probability of "positive" must be higher than 0.5 for the instance to be predicted as "positive".
版本:
$Revision: 1.9 $
作者:
Mark Hall (mhall@cs.waikato.ac.nz)
  • 字段详细资料

    • RELATION_NAME

      public static final String RELATION_NAME
      The name of the relation used in cost curve datasets
      另请参阅:
    • PROB_COST_FUNC_NAME

      public static final String PROB_COST_FUNC_NAME
      attribute name: Probability Cost Function
      另请参阅:
    • NORM_EXPECTED_COST_NAME

      public static final String NORM_EXPECTED_COST_NAME
      attribute name: Normalized Expected Cost
      另请参阅:
    • THRESHOLD_NAME

      public static final String THRESHOLD_NAME
      attribute name: Threshold
      另请参阅:
  • 构造器详细资料

    • CostCurve

      public CostCurve()
  • 方法详细资料

    • getCurve

      public Instances getCurve(FastVector predictions)
      Calculates the performance stats for the default class and return results as a set of Instances. The structure of these Instances is as follows:

      • Probability Cost Function
      • Normalized Expected Cost
      • Threshold contains the probability threshold that gives rise to the previous performance values.

      参数:
      predictions - the predictions to base the curve on
      返回:
      datapoints as a set of instances, null if no predictions have been made.
      另请参阅:
    • getCurve

      public Instances getCurve(FastVector predictions, int classIndex)
      Calculates the performance stats for the desired class and return results as a set of Instances.
      参数:
      predictions - the predictions to base the curve on
      classIndex - index of the class of interest.
      返回:
      datapoints as a set of instances.
    • getRevision

      public String getRevision()
      Returns the revision string.
      指定者:
      getRevision 在接口中 RevisionHandler
      返回:
      the revision
    • main

      public static void main(String[] args)
      Tests the CostCurve generation from the command line. The classifier is currently hardcoded. Pipe in an arff file.
      参数:
      args - currently ignored