Class AbstractClassifierEvaluation
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.gui.tools.wekainvestigator.evaluation.AbstractEvaluation<ClassifyTab,ResultItem>
-
- adams.gui.tools.wekainvestigator.tab.classifytab.evaluation.AbstractClassifierEvaluation
-
- All Implemented Interfaces:
adams.core.GlobalInfoSupporter
,adams.core.logging.LoggingSupporter
,adams.core.SizeOfHandler
,adams.core.StatusMessageHandler
,Serializable
- Direct Known Subclasses:
BuildModel
,CrossValidation
,FromPredictions
,IndexedSplitsRunsEvaluation
,ReevaluateModel
,RepeatedCrossValidation
,TrainTestSet
,TrainTestSplit
,TrainValidateTestSet
public abstract class AbstractClassifierEvaluation extends AbstractEvaluation<ClassifyTab,ResultItem>
Ancestor for classifier evaluation setups.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class adams.gui.tools.wekainvestigator.evaluation.AbstractEvaluation
m_Owner, m_PanelOptions
-
-
Constructor Summary
Constructors Constructor Description AbstractClassifierEvaluation()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract String
canEvaluate(weka.classifiers.Classifier classifier)
Tests whether the classifier can be evaluated.protected abstract void
doEvaluate(weka.classifiers.Classifier classifier, ResultItem item)
Evaluates the classifier and updates the result item.void
evaluate(weka.classifiers.Classifier classifier, ResultItem item)
Evaluates the classifier and updates the result item.protected void
fillWithAttributeNames(adams.gui.chooser.SelectOptionPanel select, int index)
Fills the panel for selection options with the attributes from the specified data container.static Class[]
getEvaluations()
Returns the available actions.abstract ResultItem
init(weka.classifiers.Classifier classifier)
Initializes the result item.protected adams.data.spreadsheet.SpreadSheet
transferAdditionalAttributes(adams.gui.chooser.SelectOptionPanel select, weka.core.Instances data)
Transfers the additional attributes into a spreadsheet.-
Methods inherited from class adams.gui.tools.wekainvestigator.evaluation.AbstractEvaluation
activate, addObjectSize, addToHistory, deserialize, getName, getOwner, getPanel, getProperties, getTestingUpdateInterval, initGUI, initialize, isValidDataIndex, listOrArray, serialize, setOwner, showStatus, toString, update
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
canEvaluate
public abstract String canEvaluate(weka.classifiers.Classifier classifier)
Tests whether the classifier can be evaluated.- Returns:
- null if successful, otherwise error message
-
init
public abstract ResultItem init(weka.classifiers.Classifier classifier) throws Exception
Initializes the result item.- Parameters:
classifier
- the current classifier- Returns:
- the initialized history item
- Throws:
Exception
- if initialization fails
-
doEvaluate
protected abstract void doEvaluate(weka.classifiers.Classifier classifier, ResultItem item) throws Exception
Evaluates the classifier and updates the result item.- Parameters:
classifier
- the current classifieritem
- the item to update- Throws:
Exception
- if evaluation fails
-
evaluate
public void evaluate(weka.classifiers.Classifier classifier, ResultItem item) throws Exception
Evaluates the classifier and updates the result item.- Parameters:
classifier
- the current classifieritem
- the item to update- Throws:
Exception
- if evaluation fails
-
fillWithAttributeNames
protected void fillWithAttributeNames(adams.gui.chooser.SelectOptionPanel select, int index)
Fills the panel for selection options with the attributes from the specified data container.- Parameters:
select
- the panel to fillindex
- the index, ignored if -1
-
transferAdditionalAttributes
protected adams.data.spreadsheet.SpreadSheet transferAdditionalAttributes(adams.gui.chooser.SelectOptionPanel select, weka.core.Instances data)
Transfers the additional attributes into a spreadsheet.- Parameters:
select
- the selected attributesdata
- the data to transfer- Returns:
- the spreadsheet
-
getEvaluations
public static Class[] getEvaluations()
Returns the available actions.- Returns:
- the action classnames
-
-