类 RotationForest
- 所有已实现的接口:
Serializable
,Cloneable
,CapabilitiesHandler
,OptionHandler
,Randomizable
,RevisionHandler
,TechnicalInformationHandler
,WeightedInstancesHandler
public class RotationForest
extends RandomizableIteratedSingleClassifierEnhancer
implements WeightedInstancesHandler, TechnicalInformationHandler
Class for construction a Rotation Forest. Can do classification and regression depending on the base learner.
For more information, see
Juan J. Rodriguez, Ludmila I. Kuncheva, Carlos J. Alonso (2006). Rotation Forest: A new classifier ensemble method. IEEE Transactions on Pattern Analysis and Machine Intelligence. 28(10):1619-1630. URL http://doi.ieeecomputersociety.org/10.1109/TPAMI.2006.211. BibTeX:
For more information, see
Juan J. Rodriguez, Ludmila I. Kuncheva, Carlos J. Alonso (2006). Rotation Forest: A new classifier ensemble method. IEEE Transactions on Pattern Analysis and Machine Intelligence. 28(10):1619-1630. URL http://doi.ieeecomputersociety.org/10.1109/TPAMI.2006.211. BibTeX:
@article{Rodriguez2006, author = {Juan J. Rodriguez and Ludmila I. Kuncheva and Carlos J. Alonso}, journal = {IEEE Transactions on Pattern Analysis and Machine Intelligence}, number = {10}, pages = {1619-1630}, title = {Rotation Forest: A new classifier ensemble method}, volume = {28}, year = {2006}, ISSN = {0162-8828}, URL = {http://doi.ieeecomputersociety.org/10.1109/TPAMI.2006.211} }Valid options are:
-N Whether minGroup (-G) and maxGroup (-H) refer to the number of groups or their size. (default: false)
-G <num> Minimum size of a group of attributes: if numberOfGroups is true, the minimum number of groups. (default: 3)
-H <num> Maximum size of a group of attributes: if numberOfGroups is true, the maximum number of groups. (default: 3)
-P <num> Percentage of instances to be removed. (default: 50)
-F <filter specification> Full class name of filter to use, followed by filter options. eg: "weka.filters.unsupervised.attribute.PrincipalComponents-R 1.0"
-S <num> Random number seed. (default 1)
-I <num> Number of iterations. (default 10)
-D If set, classifier is run in debug mode and may output additional info to the console
-W Full name of base classifier. (default: weka.classifiers.trees.J48)
Options specific to classifier weka.classifiers.trees.J48:
-U Use unpruned tree.
-C <pruning confidence> Set confidence threshold for pruning. (default 0.25)
-M <minimum number of instances> Set minimum number of instances per leaf. (default 2)
-R Use reduced error pruning.
-N <number of folds> Set number of folds for reduced error pruning. One fold is used as pruning set. (default 3)
-B Use binary splits only.
-S Don't perform subtree raising.
-L Do not clean up after the tree has been built.
-A Laplace smoothing for predicted probabilities.
-Q <seed> Seed for random data shuffling (default 1).
- 版本:
- $Revision: 7012 $
- 作者:
- Juan Jose Rodriguez (jjrodriguez@ubu.es)
- 另请参阅:
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明void
buildClassifier
(Instances data) builds the classifier.double[]
distributionForInstance
(Instance instance) Calculates the class membership probabilities for the given test instance.int
Gets the maximum size of a group.int
Gets the minimum size of a group.boolean
Get whether minGroup and maxGroup refer to the number of groups or their sizeString[]
Gets the current settings of the Classifier.Gets the filter used to project the data.int
Gets the percentage of instances to be removedReturns the revision string.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.Returns a string describing classifierReturns an enumeration describing the available options.static void
Main method for testing this class.Returns the tip text for this propertyReturns the tip text for this propertyReturns the tip text for this propertyReturns the tip text for this propertyReturns the tip text for this propertyvoid
setMaxGroup
(int maxGroup) Sets the maximum size of a group.void
setMinGroup
(int minGroup) Sets the minimum size of a group.void
setNumberOfGroups
(boolean numberOfGroups) Set whether minGroup and maxGroup refer to the number of groups or their sizevoid
setOptions
(String[] options) Parses a given list of options.void
setProjectionFilter
(Filter projectionFilter) Sets the filter used to project the data.void
setRemovedPercentage
(int removedPercentage) Sets the percentage of instance to be removedtoString()
Returns description of the Rotation Forest classifier.从类继承的方法 weka.classifiers.RandomizableIteratedSingleClassifierEnhancer
getSeed, seedTipText, setSeed
从类继承的方法 weka.classifiers.IteratedSingleClassifierEnhancer
getNumIterations, numIterationsTipText, setNumIterations
从类继承的方法 weka.classifiers.SingleClassifierEnhancer
classifierTipText, getCapabilities, getClassifier, setClassifier
从类继承的方法 weka.classifiers.Classifier
classifyInstance, debugTipText, forName, getDebug, makeCopies, makeCopy, setDebug
-
构造器详细资料
-
RotationForest
public RotationForest()Constructor.
-
-
方法详细资料
-
globalInfo
Returns a string describing classifier- 返回:
- a description 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
- 覆盖:
listOptions
在类中RandomizableIteratedSingleClassifierEnhancer
- 返回:
- an enumeration of all the available options.
-
setOptions
Parses a given list of options. Valid options are:-N Whether minGroup (-G) and maxGroup (-H) refer to the number of groups or their size. (default: false)
-G <num> Minimum size of a group of attributes: if numberOfGroups is true, the minimum number of groups. (default: 3)
-H <num> Maximum size of a group of attributes: if numberOfGroups is true, the maximum number of groups. (default: 3)
-P <num> Percentage of instances to be removed. (default: 50)
-F <filter specification> Full class name of filter to use, followed by filter options. eg: "weka.filters.unsupervised.attribute.PrincipalComponents-R 1.0"
-S <num> Random number seed. (default 1)
-I <num> Number of iterations. (default 10)
-D If set, classifier is run in debug mode and may output additional info to the console
-W Full name of base classifier. (default: weka.classifiers.trees.J48)
Options specific to classifier weka.classifiers.trees.J48:
-U Use unpruned tree.
-C <pruning confidence> Set confidence threshold for pruning. (default 0.25)
-M <minimum number of instances> Set minimum number of instances per leaf. (default 2)
-R Use reduced error pruning.
-N <number of folds> Set number of folds for reduced error pruning. One fold is used as pruning set. (default 3)
-B Use binary splits only.
-S Don't perform subtree raising.
-L Do not clean up after the tree has been built.
-A Laplace smoothing for predicted probabilities.
-Q <seed> Seed for random data shuffling (default 1).
- 指定者:
setOptions
在接口中OptionHandler
- 覆盖:
setOptions
在类中RandomizableIteratedSingleClassifierEnhancer
- 参数:
options
- the list of options as an array of strings- 抛出:
Exception
- if an option is not supported
-
getOptions
Gets the current settings of the Classifier.- 指定者:
getOptions
在接口中OptionHandler
- 覆盖:
getOptions
在类中RandomizableIteratedSingleClassifierEnhancer
- 返回:
- an array of strings suitable for passing to setOptions
-
numberOfGroupsTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setNumberOfGroups
public void setNumberOfGroups(boolean numberOfGroups) Set whether minGroup and maxGroup refer to the number of groups or their size- 参数:
numberOfGroups
- whether minGroup and maxGroup refer to the number of groups or their size
-
getNumberOfGroups
public boolean getNumberOfGroups()Get whether minGroup and maxGroup refer to the number of groups or their size- 返回:
- whether minGroup and maxGroup refer to the number of groups or their size
-
minGroupTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setMinGroup
Sets the minimum size of a group.- 参数:
minGroup
- the minimum value. of attributes.- 抛出:
IllegalArgumentException
-
getMinGroup
public int getMinGroup()Gets the minimum size of a group.- 返回:
- the minimum value.
-
maxGroupTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setMaxGroup
Sets the maximum size of a group.- 参数:
maxGroup
- the maximum value. of attributes.- 抛出:
IllegalArgumentException
-
getMaxGroup
public int getMaxGroup()Gets the maximum size of a group.- 返回:
- the maximum value.
-
removedPercentageTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setRemovedPercentage
Sets the percentage of instance to be removed- 参数:
removedPercentage
- the percentage.- 抛出:
IllegalArgumentException
-
getRemovedPercentage
public int getRemovedPercentage()Gets the percentage of instances to be removed- 返回:
- the percentage.
-
projectionFilterTipText
Returns the tip text for this property- 返回:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setProjectionFilter
Sets the filter used to project the data.- 参数:
projectionFilter
- the filter.
-
getProjectionFilter
Gets the filter used to project the data.- 返回:
- the filter.
-
toString
Returns description of the Rotation Forest classifier. -
getRevision
Returns the revision string.- 指定者:
getRevision
在接口中RevisionHandler
- 覆盖:
getRevision
在类中Classifier
- 返回:
- the revision
-
buildClassifier
builds the classifier.- 覆盖:
buildClassifier
在类中IteratedSingleClassifierEnhancer
- 参数:
data
- the training data to be used for generating the classifier.- 抛出:
Exception
- if the classifier could not be built successfully
-
distributionForInstance
Calculates the class membership probabilities for the given test instance.- 覆盖:
distributionForInstance
在类中Classifier
- 参数:
instance
- the instance to be classified- 返回:
- preedicted class probability distribution
- 抛出:
Exception
- if distribution can't be computed successfully
-
main
Main method for testing this class.- 参数:
argv
- the options
-