|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--weka.filters.Filter | +--weka.filters.supervised.attribute.AttributeSelection
Filter for doing attribute selection.
Valid options are:
-S <"Name of search class [search options]">
Set search method for subset evaluators.
eg. -S "weka.attributeSelection.BestFirst -S 8"
-E <"Name of attribute/subset evaluation class [evaluator options]">
Set the attribute/subset evaluator.
eg. -E "weka.attributeSelection.CfsSubsetEval -L"
Constructor Summary | |
AttributeSelection()
Constructor |
Method Summary | |
boolean |
batchFinished()
Signify that this batch of input to the filter is finished. |
java.lang.String |
evaluatorTipText()
Returns the tip text for this property |
ASEvaluation |
getEvaluator()
Get the name of the attribute/subset evaluator |
java.lang.String[] |
getOptions()
Gets the current settings for the attribute selection (search, evaluator) etc. |
ASSearch |
getSearch()
Get the name of the search method |
java.lang.String |
globalInfo()
Returns a string describing this filter |
boolean |
input(Instance instance)
Input an instance for filtering. |
java.util.Enumeration |
listOptions()
Returns an enumeration describing the available options. |
static void |
main(java.lang.String[] argv)
Main method for testing this class. |
java.lang.String |
searchTipText()
Returns the tip text for this property |
void |
setEvaluator(ASEvaluation evaluator)
set a string holding the name of a attribute/subset evaluator |
void |
setOptions(java.lang.String[] options)
Parses a given list of options. |
void |
setSearch(ASSearch search)
Set as string holding the name of a search class |
Methods inherited from class weka.filters.Filter |
batchFilterFile, filterFile, getOutputFormat, inputFormat, isOutputFormatDefined, numPendingOutput, output, outputFormat, outputPeek, setInputFormat, useFilter |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AttributeSelection()
Method Detail |
public java.lang.String globalInfo()
public java.util.Enumeration listOptions()
listOptions
in interface OptionHandler
public void setOptions(java.lang.String[] options) throws java.lang.Exception
-S <"Name of search class [search options]">
Set search method for subset evaluators.
eg. -S "weka.attributeSelection.BestFirst -S 8"
-E <"Name of attribute/subset evaluation class [evaluator options]">
Set the attribute/subset evaluator.
eg. -E "weka.attributeSelection.CfsSubsetEval -L"
setOptions
in interface OptionHandler
options
- the list of options as an array of strings
java.lang.Exception
- if an option is not supportedpublic java.lang.String[] getOptions()
getOptions
in interface OptionHandler
public java.lang.String evaluatorTipText()
public void setEvaluator(ASEvaluation evaluator)
public java.lang.String searchTipText()
public void setSearch(ASSearch search)
public ASEvaluation getEvaluator()
public ASSearch getSearch()
public boolean input(Instance instance) throws java.lang.Exception
input
in class Filter
instance
- the input instance
java.lang.IllegalStateException
- if no input format has been defined.
java.lang.Exception
- if the input instance was not of the correct format
or if there was a problem with the filtering.public boolean batchFinished() throws java.lang.Exception
batchFinished
in class Filter
java.lang.IllegalStateException
- if no input structure has been defined.
java.lang.Exception
- if there is a problem during the attribute selection.public static void main(java.lang.String[] argv)
argv
- should contain arguments to the filter: use -h for help
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright (c) 2003 David Lindsay, Computer Learning Research Centre, Dept. Computer Science, Royal Holloway, University of London