Package adams.data.weka.predictions
Class AutoScaler
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.data.weka.predictions.AbstractErrorScaler
-
- adams.data.weka.predictions.AutoScaler
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,SizeOfHandler
,Serializable
,weka.core.CapabilitiesHandler
public class AutoScaler extends AbstractErrorScaler
Applies the specified numeric scaler to the data in case of a numeric class attribute, otherwise just passes on the data.
Valid options are:
-scaler <adams.data.weka.predictions.AbstractErrorScaler [options]> (property: scaler) The scaler to use for numeric data. default: adams.data.weka.predictions.RelativeNumericErrorScaler
- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected AbstractErrorScaler
m_Scaler
the scaler to use for numeric classes.-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description AutoScaler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
defineOptions()
Adds options to the internal list of options.weka.core.Capabilities
getCapabilities()
Returns the capabilities of this object.AbstractErrorScaler
getScaler()
Returns the scaler for numeric data.String
globalInfo()
Returns a string describing the object.ArrayList<Integer>
scale(ArrayList data)
Scales the errors.String
scalerTipText()
Returns the tip text for this property.void
setScaler(AbstractErrorScaler value)
Sets the scaler to use for numeric data.-
Methods inherited from class adams.data.weka.predictions.AbstractErrorScaler
compareTo, equals, forCommandLine, forName, getErrorScalers, shallowCopy, shallowCopy, toString
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Scaler
protected AbstractErrorScaler m_Scaler
the scaler to use for numeric classes.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractOptionHandler
-
setScaler
public void setScaler(AbstractErrorScaler value)
Sets the scaler to use for numeric data.- Parameters:
value
- the scaler
-
getScaler
public AbstractErrorScaler getScaler()
Returns the scaler for numeric data.- Returns:
- the scaler
-
scalerTipText
public String scalerTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
getCapabilities
public weka.core.Capabilities getCapabilities()
Returns the capabilities of this object. Returns what types of classes the scaler can handle.- Specified by:
getCapabilities
in interfaceweka.core.CapabilitiesHandler
- Specified by:
getCapabilities
in classAbstractErrorScaler
- Returns:
- the capabilities of this object
- See Also:
Capabilities
-
scale
public ArrayList<Integer> scale(ArrayList data)
Scales the errors.- Specified by:
scale
in classAbstractErrorScaler
- Parameters:
data
- the data containing the errors to scale- Returns:
- the scaled errors
-
-