Package adams.flow.sink
Class WekaClassifierErrors.DataGenerator
- java.lang.Object
-
- adams.flow.sink.WekaClassifierErrors.DataGenerator
-
- Enclosing class:
- WekaClassifierErrors
public static class WekaClassifierErrors.DataGenerator extends Object
Helper class for generating visualization data.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
-
-
Field Summary
Fields Modifier and Type Field Description protected AbstractErrorScalerm_ErrorScalerthe scaler scheme to use.protected weka.classifiers.Evaluationm_Evaluationthe underlying Evaluation object.protected weka.core.Instancesm_PlotInstancesthe underlying data.protected ArrayListm_PlotShapesfor storing the plot shapes.protected ArrayListm_PlotSizesfor storing the plot sizes.protected booleanm_Processedwhether the data has already been processed.
-
Constructor Summary
Constructors Constructor Description DataGenerator(weka.classifiers.Evaluation eval, AbstractErrorScaler scaler)Initializes the generator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidcreateDataset(weka.classifiers.Evaluation eval)Generates a dataset, containing the predicted vs actual values.AbstractErrorScalergetErrorScaler()Returns the scaling scheme.weka.classifiers.EvaluationgetEvaluation()Returns the underlying Evaluation object.weka.gui.visualize.PlotData2DgetPlotData()Assembles and returns the plot.weka.core.InstancesgetPlotInstances()Returns the generated dataset that is plotted.protected voidprocess()Processes the data if necessary.
-
-
-
Field Detail
-
m_Evaluation
protected weka.classifiers.Evaluation m_Evaluation
the underlying Evaluation object.
-
m_PlotInstances
protected weka.core.Instances m_PlotInstances
the underlying data.
-
m_PlotShapes
protected ArrayList m_PlotShapes
for storing the plot shapes.
-
m_PlotSizes
protected ArrayList m_PlotSizes
for storing the plot sizes.
-
m_ErrorScaler
protected AbstractErrorScaler m_ErrorScaler
the scaler scheme to use.
-
m_Processed
protected boolean m_Processed
whether the data has already been processed.
-
-
Constructor Detail
-
DataGenerator
public DataGenerator(weka.classifiers.Evaluation eval, AbstractErrorScaler scaler)Initializes the generator.- Parameters:
eval- the Evaluation object to usescaler- the scaler scheme to use for the errors
-
-
Method Detail
-
process
protected void process()
Processes the data if necessary.
-
getEvaluation
public weka.classifiers.Evaluation getEvaluation()
Returns the underlying Evaluation object.- Returns:
- the Evaluation object
-
getErrorScaler
public AbstractErrorScaler getErrorScaler()
Returns the scaling scheme.- Returns:
- the scaler
-
getPlotInstances
public weka.core.Instances getPlotInstances()
Returns the generated dataset that is plotted.- Returns:
- the dataset
-
createDataset
protected void createDataset(weka.classifiers.Evaluation eval)
Generates a dataset, containing the predicted vs actual values.- Parameters:
eval- for obtaining the dataset information and predictions
-
-