Class ClassifierPerformanceEvaluator

  • All Implemented Interfaces:
    java.io.Serializable, BaseStepExtender, Step

    @KFStep(name="ClassifierPerformanceEvaluator",
            category="Evaluation",
            toolTipText="Evaluates batch classifiers",
            iconPath="weka/gui/knowledgeflow/icons/ClassifierPerformanceEvaluator.gif")
    public class ClassifierPerformanceEvaluator
    extends BaseStep
    Step that implements batch classifier evaluation
    Version:
    $Revision: $
    Author:
    Mark Hall (mhall{[at]}pentaho{[dot]}com)
    See Also:
    Serialized Form
    • Constructor Detail

      • ClassifierPerformanceEvaluator

        public ClassifierPerformanceEvaluator()
        Constructor
    • Method Detail

      • setOutputPerClassStats

        public void setOutputPerClassStats​(boolean perClassStats)
      • getOutputConfusionMatrix

        public boolean getOutputConfusionMatrix()
      • getOutputEntropyMetrics

        public boolean getOutputEntropyMetrics()
      • setCollectPredictionsForVisAndAUC

        @OptionMetadata(displayName="Collect test data and predictions for visualization",
                        description="Collect data and predictions in order to output visualizableError and thresholdData data",
                        displayOrder=4)
        public void setCollectPredictionsForVisAndAUC​(boolean collectPredictionsForVisAndAUC)
      • getCollectPredictionsForVisAndAUC

        public boolean getCollectPredictionsForVisAndAUC()
      • getErrorPlotPointSizeProportionalToMargin

        @OptionMetadata(displayName="Error plot point size proportional to margin",
                        description="Set the point size proportional to the prediction margin for classification error plots")
        public boolean getErrorPlotPointSizeProportionalToMargin()
        Get whether the size of plot data points will be proportional to the prediction margin
        Returns:
        true if plot data points will be rendered proportional to the size of the prediction margin
      • setErrorPlotPointSizeProportionalToMargin

        public void setErrorPlotPointSizeProportionalToMargin​(boolean e)
        Set whether the size of plot data points will be proportional to the prediction margin
        Parameters:
        e - true if plot data points will be rendered proportional to the size of the prediction margin
      • getEvaluationMetricsToOutput

        @ProgrammaticProperty
        public java.lang.String getEvaluationMetricsToOutput()
        Get the evaluation metrics to output (as a comma-separated list).
        Returns:
        the evaluation metrics to output
      • setEvaluationMetricsToOutput

        public void setEvaluationMetricsToOutput​(java.lang.String m)
        Set the evaluation metrics to output (as a comma-separated list).
        Parameters:
        m - the evaluation metrics to output
      • setEvaluateWithRespectToCosts

        @ProgrammaticProperty
        public void setEvaluateWithRespectToCosts​(boolean useCosts)
        Set whether to evaluate with respoect to costs
        Parameters:
        useCosts - true to use cost-sensitive evaluation
      • getEvaluateWithRespectToCosts

        public boolean getEvaluateWithRespectToCosts()
        Get whether to evaluate with respoect to costs
        Returns:
        true to use cost-sensitive evaluation
      • setCostMatrixString

        @ProgrammaticProperty
        public void setCostMatrixString​(java.lang.String cms)
        Set the cost matrix to use as a string
        Parameters:
        cms - the cost matrix to use
      • getCostMatrixString

        public java.lang.String getCostMatrixString()
        Get the cost matrix to use as a string
        Returns:
        the cost matrix
      • getIncomingConnectionTypes

        public java.util.List<java.lang.String> getIncomingConnectionTypes()
        Get a list of incoming connection types that this step can accept. Ideally (and if appropriate), this should take into account the state of the step and any existing incoming connections. E.g. a step might be able to accept one (and only one) incoming batch data connection.
        Returns:
        a list of incoming connections that this step can accept given its current state
      • getOutgoingConnectionTypes

        public java.util.List<java.lang.String> getOutgoingConnectionTypes()
        Get a list of outgoing connection types that this step can produce. Ideally (and if appropriate), this should take into account the state of the step and the incoming connections. E.g. depending on what incoming connection is present, a step might be able to produce a trainingSet output, a testSet output or neither, but not both.
        Returns:
        a list of outgoing connections that this step can produce
      • stepInit

        public void stepInit()
                      throws WekaException
        Description copied from interface: Step
        Initialize the step.
        Throws:
        WekaException - if a problem occurs during initialization
      • stop

        public void stop()
        Description copied from class: BaseStep
        Request that processing be stopped. Subclasses should call isStopRequested() periodically to see if they should stop processing.
        Specified by:
        stop in interface Step
        Overrides:
        stop in class BaseStep
      • getCustomEditorForStep

        public java.lang.String getCustomEditorForStep()
        Return the fully qualified name of a custom editor component (JComponent) to use for editing the properties of the step. This method can return null, in which case the system will dynamically generate an editor using the GenericObjectEditor
        Specified by:
        getCustomEditorForStep in interface Step
        Overrides:
        getCustomEditorForStep in class BaseStep
        Returns:
        the fully qualified name of a step editor component