adams.data.weka.columnfinder
Class AbstractTrainableColumnFinder

java.lang.Object
  extended by adams.core.ConsoleObject
      extended by adams.core.option.AbstractOptionHandler
          extended by adams.data.weka.columnfinder.AbstractColumnFinder
              extended by adams.data.weka.columnfinder.AbstractTrainableColumnFinder
All Implemented Interfaces:
Debuggable, Destroyable, OptionHandler, ShallowCopySupporter<ColumnFinder>, SizeOfHandler, ColumnFinder, TrainableColumnFinder, Serializable
Direct Known Subclasses:
AbstractFilteredColumnFinder, MultiColumnFinder

public abstract class AbstractTrainableColumnFinder
extends AbstractColumnFinder
implements TrainableColumnFinder

Ancestor for ColumnFinder algorithms that can be trained.

Version:
$Revision: 5747 $
Author:
fracpete (fracpete at waikato dot ac dot nz)
See Also:
Serialized Form

Field Summary
protected  boolean m_Trained
          whether the column finder was trained already.
 
Fields inherited from class adams.core.option.AbstractOptionHandler
m_DebugLevel, m_OptionManager
 
Constructor Summary
AbstractTrainableColumnFinder()
           
 
Method Summary
protected  void check(weka.core.Instances data)
          Checks the data.
protected abstract  boolean doTrainColumnFinder(weka.core.Instances data)
          Performs the actual training of the column finder with the specified dataset.
 boolean isColumnFinderTrained()
          Checks whether the column finder has been trained.
protected  void reset()
          Resets the object, including the trained state.
 boolean trainColumnFinder(weka.core.Instances data)
          Trains the column finder with the specified dataset.
 
Methods inherited from class adams.data.weka.columnfinder.AbstractColumnFinder
arrayToHashSet, compareTo, doFindColumns, equals, findColumns, forCommandLine, forName, getColumnFinders, shallowCopy, shallowCopy
 
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, debug, debug, debugLevelTipText, defineOptions, destroy, finishInit, getDebugLevel, getOptionManager, globalInfo, initialize, isDebugOn, newOptionManager, setDebugLevel, toCommandLine, toString
 
Methods inherited from class adams.core.ConsoleObject
getDebugging, getSystemErr, getSystemOut, sizeOf
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface adams.data.weka.columnfinder.ColumnFinder
findColumns
 

Field Detail

m_Trained

protected boolean m_Trained
whether the column finder was trained already.

Constructor Detail

AbstractTrainableColumnFinder

public AbstractTrainableColumnFinder()
Method Detail

reset

protected void reset()
Resets the object, including the trained state.

Overrides:
reset in class AbstractOptionHandler

doTrainColumnFinder

protected abstract boolean doTrainColumnFinder(weka.core.Instances data)
Performs the actual training of the column finder with the specified dataset.

Parameters:
data - the training data
Returns:
true if successfully trained

trainColumnFinder

public boolean trainColumnFinder(weka.core.Instances data)
Trains the column finder with the specified dataset.

Specified by:
trainColumnFinder in interface TrainableColumnFinder
Parameters:
data - the training data
Returns:
true if successfully trained

isColumnFinderTrained

public boolean isColumnFinderTrained()
Checks whether the column finder has been trained.

Specified by:
isColumnFinderTrained in interface TrainableColumnFinder
Returns:
true if the column finder has been trained already

check

protected void check(weka.core.Instances data)
Checks the data.

Trains the column finder with the given data if not yet trained.

Overrides:
check in class AbstractColumnFinder
Parameters:
data - the data to check


Copyright © 2012 University of Waikato, Hamilton, NZ. All Rights Reserved.