类 RandomSearch
java.lang.Object
weka.attributeSelection.ASSearch
weka.attributeSelection.RandomSearch
- 所有已实现的接口:
Serializable
,StartSetHandler
,OptionHandler
,RevisionHandler
,TechnicalInformationHandler
public class RandomSearch
extends ASSearch
implements StartSetHandler, OptionHandler, TechnicalInformationHandler
RandomSearch :
Performs a Random search in the space of attribute subsets. If no start set is supplied, Random search starts from a random point and reports the best subset found. If a start set is supplied, Random searches randomly for subsets that are as good or better than the start point with the same or or fewer attributes. Using RandomSearch in conjunction with a start set containing all attributes equates to the LVF algorithm of Liu and Setiono (ICML-96).
For more information see:
H. Liu, R. Setiono: A probabilistic approach to feature selection - A filter solution. In: 13th International Conference on Machine Learning, 319-327, 1996. BibTeX:
Performs a Random search in the space of attribute subsets. If no start set is supplied, Random search starts from a random point and reports the best subset found. If a start set is supplied, Random searches randomly for subsets that are as good or better than the start point with the same or or fewer attributes. Using RandomSearch in conjunction with a start set containing all attributes equates to the LVF algorithm of Liu and Setiono (ICML-96).
For more information see:
H. Liu, R. Setiono: A probabilistic approach to feature selection - A filter solution. In: 13th International Conference on Machine Learning, 319-327, 1996. BibTeX:
@inproceedings{Liu1996, author = {H. Liu and R. Setiono}, booktitle = {13th International Conference on Machine Learning}, pages = {319-327}, title = {A probabilistic approach to feature selection - A filter solution}, year = {1996} }Valid options are:
-P <start set> Specify a starting set of attributes. Eg. 1,3,5-7. If a start point is supplied, random search evaluates the start point and then randomly looks for subsets that are as good as or better than the start point with the same or lower cardinality.
-F <percent> Percent of search space to consider. (default = 25%).
-V Output subsets as the search progresses. (default = false).
-seed <num> Random seed (default = 1)
- 版本:
- $Revision: 8949 $
- 作者:
- Mark Hall (mhall@cs.waikato.ac.nz)
- 另请参阅:
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明String[]
Gets the current settings of RandomSearch.Returns the revision string.double
get the percentage of the search space to considerint
getSeed()
Get the random seed to useReturns a list of attributes (and or attribute ranges) as a StringReturns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on.boolean
get whether or not output is verboseReturns a string describing this search methodReturns an enumeration describing the available options.int[]
search
(ASEvaluation ASEval, Instances data) Searches the attribute subset space randomly.Returns the tip text for this propertyReturns the tip text for this propertyvoid
setOptions
(String[] options) Parses a given list of options.void
setSearchPercent
(double p) set the percentage of the search space to considervoid
setSeed
(int seed) Set the random seed to usevoid
setStartSet
(String startSet) Sets a starting set of attributes for the search.void
setVerbose
(boolean v) set whether or not to output new best subsets as the search proceedsReturns the tip text for this propertytoString()
prints a description of the searchReturns the tip text for this property从类继承的方法 weka.attributeSelection.ASSearch
forName, makeCopies
-
构造器详细资料
-
RandomSearch
public RandomSearch()Constructor
-
-
方法详细资料
-
globalInfo
Returns a string describing this search method- 返回:
- a description of the search suitable for displaying in the explorer/experimenter gui
-
getTechnicalInformation
Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on.- 指定者:
getTechnicalInformation
在接口中TechnicalInformationHandler
- 返回:
- the technical information about this class
-
listOptions
Returns an enumeration describing the available options.- 指定者:
listOptions
在接口中OptionHandler
- 返回:
- an enumeration of all the available options.
-
setOptions
Parses a given list of options. Valid options are:-P <start set> Specify a starting set of attributes. Eg. 1,3,5-7. If a start point is supplied, random search evaluates the start point and then randomly looks for subsets that are as good as or better than the start point with the same or lower cardinality.
-F <percent> Percent of search space to consider. (default = 25%).
-V Output subsets as the search progresses. (default = false).
-seed <num> Random seed (default = 1)
- 指定者:
setOptions
在接口中OptionHandler
- 参数:
options
- the list of options as an array of strings- 抛出:
Exception
- if an option is not supported
-
getOptions
Gets the current settings of RandomSearch.- 指定者:
getOptions
在接口中OptionHandler
- 返回:
- an array of strings suitable for passing to setOptions()
-
startSetTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setStartSet
Sets a starting set of attributes for the search. It is the search method's responsibility to report this start set (if any) in its toString() method.- 指定者:
setStartSet
在接口中StartSetHandler
- 参数:
startSet
- a string containing a list of attributes (and or ranges), eg. 1,2,6,10-15. "" indicates no start point. If a start point is supplied, random search evaluates the start point and then looks for subsets that are as good as or better than the start point with the same or lower cardinality.- 抛出:
Exception
- if start set can't be set.
-
getStartSet
Returns a list of attributes (and or attribute ranges) as a String- 指定者:
getStartSet
在接口中StartSetHandler
- 返回:
- a list of attributes (and or attribute ranges)
-
verboseTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setVerbose
public void setVerbose(boolean v) set whether or not to output new best subsets as the search proceeds- 参数:
v
- true if output is to be verbose
-
getVerbose
public boolean getVerbose()get whether or not output is verbose- 返回:
- true if output is set to verbose
-
searchPercentTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setSearchPercent
public void setSearchPercent(double p) set the percentage of the search space to consider- 参数:
p
- percent of the search space ( 0 < p <= 100)
-
seedTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setSeed
public void setSeed(int seed) Set the random seed to use- 参数:
seed
- the seed to use
-
getSeed
public int getSeed()Get the random seed to use- 返回:
- the random seed
-
getSearchPercent
public double getSearchPercent()get the percentage of the search space to consider- 返回:
- the percent of the search space explored
-
toString
prints a description of the search -
search
Searches the attribute subset space randomly. -
getRevision
Returns the revision string.- 指定者:
getRevision
在接口中RevisionHandler
- 覆盖:
getRevision
在类中ASSearch
- 返回:
- the revision
-