public class NumericCleaner extends SimpleStreamFilter implements WeightedAttributesHandler, WeightedInstancesHandler
-output-debug-info Turns on output of debugging information.
-min <double> The minimum threshold. (default -Double.MAX_VALUE)
-min-default <double> The minimum threshold below which values are replaced by the corresponding default. (default -Double.MAX_VALUE)
-max <double> The maximum threshold above which values are replaced by the corresponding default. (default Double.MAX_VALUE)
-max-default <double> The replacement for values larger than the maximum threshold. (default Double.MAX_VALUE)
-closeto <double> The value with respect to which closeness is determined. (default 0)
-closeto-default <double> The replacement for values that are too close to '-closeto'. (default 0)
-closeto-tolerance <double> The tolerance for testing whether a value is too close. (default 1E-6)
-decimals <int> The number of decimals to round to, -1 means no rounding at all. (default -1)
-R <col1,col2,...> The list of columns to cleanse, e.g., first-last or first-3,5-last. (default first-last)
-V Inverts the matching sense.
-include-class Whether to include the class in the cleansing. The class column will always be skipped if this flag is not present. (default no)
| Constructor and Description |
|---|
NumericCleaner() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
attributeIndicesTipText()
Returns the tip text for this property
|
java.lang.String |
closeToDefaultTipText()
Returns the tip text for this property
|
java.lang.String |
closeToTipText()
Returns the tip text for this property
|
java.lang.String |
closeToToleranceTipText()
Returns the tip text for this property
|
java.lang.String |
decimalsTipText()
Returns the tip text for this property
|
java.lang.String |
getAttributeIndices()
Gets the selection of the columns, e.g., first-last or first-3,5-last
|
Capabilities |
getCapabilities()
Returns the Capabilities of this filter.
|
double |
getCloseTo()
Get the "close to" number.
|
double |
getCloseToDefault()
Get the "close to" default.
|
double |
getCloseToTolerance()
Get the "close to" Tolerance.
|
int |
getDecimals()
Get the number of decimals to round to.
|
boolean |
getIncludeClass()
Gets whether the class is included in the cleaning process or always
skipped.
|
boolean |
getInvertSelection()
Gets whether the selection of the columns is inverted
|
double |
getMaxDefault()
Get the maximum default.
|
double |
getMaxThreshold()
Get the maximum threshold.
|
double |
getMinDefault()
Get the minimum default.
|
double |
getMinThreshold()
Get the minimum threshold.
|
java.lang.String[] |
getOptions()
Gets the current settings of the filter.
|
java.lang.String |
getRevision()
Returns the revision string.
|
java.lang.String |
globalInfo()
Returns a string describing this filter.
|
java.lang.String |
includeClassTipText()
Returns the tip text for this property
|
java.lang.String |
invertSelectionTipText()
Returns the tip text for this property
|
java.util.Enumeration<Option> |
listOptions()
Returns an enumeration describing the available options.
|
static void |
main(java.lang.String[] args)
Runs the filter from commandline, use "-h" to see all options.
|
java.lang.String |
maxDefaultTipText()
Returns the tip text for this property
|
java.lang.String |
maxThresholdTipText()
Returns the tip text for this property
|
java.lang.String |
minDefaultTipText()
Returns the tip text for this property
|
java.lang.String |
minThresholdTipText()
Returns the tip text for this property
|
void |
setAttributeIndices(java.lang.String value)
Sets the columns to use, e.g., first-last or first-3,5-last
|
void |
setCloseTo(double value)
Set the "close to" number.
|
void |
setCloseToDefault(double value)
Set the "close to" default.
|
void |
setCloseToTolerance(double value)
Set the "close to" Tolerance.
|
void |
setDecimals(int value)
Set the number of decimals to round to.
|
void |
setIncludeClass(boolean value)
Sets whether the class can be cleaned, too.
|
void |
setInvertSelection(boolean value)
Sets whether the selection of the indices is inverted or not
|
void |
setMaxDefault(double value)
Set the naximum default.
|
void |
setMaxThreshold(double value)
Set the maximum threshold.
|
void |
setMinDefault(double value)
Set the minimum default.
|
void |
setMinThreshold(double value)
Set the minimum threshold.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
batchFinished, inputsetInputFormatbatchFilterFile, debugTipText, doNotCheckCapabilitiesTipText, filterFile, getCapabilities, getCopyOfInputFormat, getDebug, getDoNotCheckCapabilities, getOutputFormat, isFirstBatchDone, isNewBatch, isOutputFormatDefined, makeCopies, makeCopy, mayRemoveInstanceAfterFirstBatchDone, numPendingOutput, output, outputPeek, postExecution, preExecution, run, runFilter, setDebug, setDoNotCheckCapabilities, toString, useFilter, wekaStaticWrapperequals, getClass, hashCode, notify, notifyAll, wait, wait, waitmakeCopypublic java.lang.String globalInfo()
globalInfo in class SimpleFilterpublic java.util.Enumeration<Option> listOptions()
listOptions in interface OptionHandlerlistOptions in class Filterpublic java.lang.String[] getOptions()
getOptions in interface OptionHandlergetOptions in class Filterpublic void setOptions(java.lang.String[] options)
throws java.lang.Exception
-output-debug-info Turns on output of debugging information.
-min <double> The minimum threshold. (default -Double.MAX_VALUE)
-min-default <double> The minimum threshold below which values are replaced by the corresponding default. (default -Double.MAX_VALUE)
-max <double> The maximum threshold above which values are replaced by the corresponding default. (default Double.MAX_VALUE)
-max-default <double> The replacement for values larger than the maximum threshold. (default Double.MAX_VALUE)
-closeto <double> The value with respect to which closeness is determined. (default 0)
-closeto-default <double> The replacement for values that are too close to '-closeto'. (default 0)
-closeto-tolerance <double> The tolerance for testing whether a value is too close. (default 1E-6)
-decimals <int> The number of decimals to round to, -1 means no rounding at all. (default -1)
-R <col1,col2,...> The list of columns to cleanse, e.g., first-last or first-3,5-last. (default first-last)
-V Inverts the matching sense.
-include-class Whether to include the class in the cleansing. The class column will always be skipped if this flag is not present. (default no)
setOptions in interface OptionHandlersetOptions in class Filteroptions - the list of options as an array of stringsjava.lang.Exception - if an option is not supportedpublic Capabilities getCapabilities()
getCapabilities in interface CapabilitiesHandlergetCapabilities in class FilterCapabilitiespublic java.lang.String minThresholdTipText()
public double getMinThreshold()
public void setMinThreshold(double value)
value - the minimum threshold to use.public java.lang.String minDefaultTipText()
public double getMinDefault()
public void setMinDefault(double value)
value - the minimum default to use.public java.lang.String maxThresholdTipText()
public double getMaxThreshold()
public void setMaxThreshold(double value)
value - the maximum threshold to use.public java.lang.String maxDefaultTipText()
public double getMaxDefault()
public void setMaxDefault(double value)
value - the maximum default to use.public java.lang.String closeToTipText()
public double getCloseTo()
public void setCloseTo(double value)
value - the number to use for checking closeness.public java.lang.String closeToDefaultTipText()
public double getCloseToDefault()
public void setCloseToDefault(double value)
value - the "close to" default to use.public java.lang.String closeToToleranceTipText()
public double getCloseToTolerance()
public void setCloseToTolerance(double value)
value - the "close to" Tolerance to use.public java.lang.String attributeIndicesTipText()
public java.lang.String getAttributeIndices()
public void setAttributeIndices(java.lang.String value)
value - the columns to usepublic java.lang.String invertSelectionTipText()
public boolean getInvertSelection()
public void setInvertSelection(boolean value)
value - the new invert settingpublic java.lang.String includeClassTipText()
public boolean getIncludeClass()
public void setIncludeClass(boolean value)
value - true if the class can be cleansed, toopublic java.lang.String decimalsTipText()
public int getDecimals()
public void setDecimals(int value)
value - the number of decimals.public java.lang.String getRevision()
getRevision in interface RevisionHandlergetRevision in class Filterpublic static void main(java.lang.String[] args)
args - the commandline options for the filter