|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectweka.classifiers.AbstractClassifier
weka.classifiers.MultipleClassifiersCombiner
weka.classifiers.ParallelMultipleClassifiersCombiner
weka.classifiers.meta.PartitionedStacking
public class PartitionedStacking
Builds the base-classifiers on subsets of the data defined by ranges that correspond to the base-classifiers. The base-classifiers expect the class attribute to be the last attribute in the range of attributes that is defined for them.
The predictions of the base-classifiers and the original class attribute are used to generated a new meta-dataset that is used as input for the meta-level classifier.
-R <range> The attributes ranges to use for training the base-classifiers. Must be specified as often as there are base-classifiers. This is a comma separated list of attribute indices, with "first" and "last" valid values. Specify an inclusive range with "-". E.g: "first-3,5,6-10,last".
-M <classifier specification> Full class name of the classifier to use for the meta-level, followed by scheme options. (default: "weka.classifiers.trees.M5P")
-num-slots <num> Number of execution slots. (default 1 - i.e. no parallelism)
-B <classifier specification> Full class name of classifier to include, followed by scheme options. May be specified multiple times. (default: "weka.classifiers.rules.ZeroR")
-D If set, classifier is run in debug mode and may output additional info to the console
| Field Summary | |
|---|---|
protected weka.classifiers.Classifier |
m_MetaLevelClassifier
the meta-level classifier. |
protected weka.core.Instances |
m_MetaLevelData
the header for the meta-level data. |
protected weka.core.Range[] |
m_Ranges
the attribute ranges for the base-classifiers. |
protected weka.filters.unsupervised.attribute.Remove[] |
m_Remove
the filters for removing the unwanted attributes for the base classifiers. |
| Fields inherited from class weka.classifiers.ParallelMultipleClassifiersCombiner |
|---|
m_completed, m_executorPool, m_failed, m_numExecutionSlots |
| Fields inherited from class weka.classifiers.MultipleClassifiersCombiner |
|---|
m_Classifiers |
| Fields inherited from class weka.classifiers.AbstractClassifier |
|---|
m_Debug |
| Constructor Summary | |
|---|---|
PartitionedStacking()
|
|
| Method Summary | |
|---|---|
void |
buildClassifier(weka.core.Instances data)
Builds the classifier. |
protected void |
buildClassifiers(weka.core.Instances data)
Does the actual construction of the base-classifiers. |
double |
classifyInstance(weka.core.Instance instance)
Classifies the given test instance. |
weka.core.Capabilities |
getCapabilities()
Returns combined capabilities of the base classifiers, i.e., the capabilities all of them have in common. |
weka.classifiers.Classifier |
getMetaLevelClassifier()
Returns the meta-level classifier. |
String[] |
getOptions()
Gets the current settings of the Classifier. |
weka.core.Range[] |
getRanges()
Returns the attribute ranges for the base-classifiers. |
String |
getRevision()
Returns the revision string. |
String |
globalInfo()
Returns a string describing this classifier. |
Enumeration |
listOptions()
Returns an enumeration describing the available options. |
static void |
main(String[] args)
Main method for running this classifier. |
String |
metaLevelClassifierTipText()
Returns the tip text for this property. |
String |
rangesTipText()
Returns the tip text for this property. |
void |
setMetaLevelClassifier(weka.classifiers.Classifier value)
Sets the meta-level classifier. |
void |
setOptions(String[] options)
Parses a given list of options. |
void |
setRanges(weka.core.Range[] value)
Sets the attribute ranges for the base-classifiers. |
| Methods inherited from class weka.classifiers.ParallelMultipleClassifiersCombiner |
|---|
completedClassifier, getNumExecutionSlots, numExecutionSlotsTipText, setNumExecutionSlots, startExecutorPool |
| Methods inherited from class weka.classifiers.MultipleClassifiersCombiner |
|---|
classifiersTipText, getClassifier, getClassifiers, getClassifierSpec, setClassifiers |
| Methods inherited from class weka.classifiers.AbstractClassifier |
|---|
debugTipText, distributionForInstance, forName, getDebug, makeCopies, makeCopy, runClassifier, setDebug |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected weka.classifiers.Classifier m_MetaLevelClassifier
protected weka.core.Range[] m_Ranges
protected weka.filters.unsupervised.attribute.Remove[] m_Remove
protected weka.core.Instances m_MetaLevelData
| Constructor Detail |
|---|
public PartitionedStacking()
| Method Detail |
|---|
public String globalInfo()
public Enumeration listOptions()
listOptions in interface weka.core.OptionHandlerlistOptions in class weka.classifiers.ParallelMultipleClassifiersCombiner
public void setOptions(String[] options)
throws Exception
-R <range> The attributes ranges to use for training the base-classifiers. Must be specified as often as there are base-classifiers. This is a comma separated list of attribute indices, with "first" and "last" valid values. Specify an inclusive range with "-". E.g: "first-3,5,6-10,last".
-M <classifier specification> Full class name of the classifier to use for the meta-level, followed by scheme options. (default: "weka.classifiers.trees.M5P")
-num-slots <num> Number of execution slots. (default 1 - i.e. no parallelism)
-B <classifier specification> Full class name of classifier to include, followed by scheme options. May be specified multiple times. (default: "weka.classifiers.rules.ZeroR")
-D If set, classifier is run in debug mode and may output additional info to the console
setOptions in interface weka.core.OptionHandlersetOptions in class weka.classifiers.ParallelMultipleClassifiersCombineroptions - the list of options as an array of strings
Exception - if an option is not supportedpublic String[] getOptions()
getOptions in interface weka.core.OptionHandlergetOptions in class weka.classifiers.ParallelMultipleClassifiersCombinerpublic void setRanges(weka.core.Range[] value)
value - the rangespublic weka.core.Range[] getRanges()
public String rangesTipText()
public void setMetaLevelClassifier(weka.classifiers.Classifier value)
value - the meta-level classifierpublic weka.classifiers.Classifier getMetaLevelClassifier()
public String metaLevelClassifierTipText()
public weka.core.Capabilities getCapabilities()
getCapabilities in interface weka.classifiers.ClassifiergetCapabilities in interface weka.core.CapabilitiesHandlergetCapabilities in class weka.classifiers.MultipleClassifiersCombiner
protected void buildClassifiers(weka.core.Instances data)
throws Exception
buildClassifiers in class weka.classifiers.ParallelMultipleClassifiersCombinerdata - the data to use as basis for base-classifiers
Exception - if something goes wrong during the training process
public void buildClassifier(weka.core.Instances data)
throws Exception
buildClassifier in interface weka.classifiers.ClassifierbuildClassifier in class weka.classifiers.ParallelMultipleClassifiersCombinerdata - the training data to be used for generating the classifier
Exception - if the classifier could not be built successfully
public double classifyInstance(weka.core.Instance instance)
throws Exception
classifyInstance in interface weka.classifiers.ClassifierclassifyInstance in class weka.classifiers.AbstractClassifierinstance - the instance to be classified
Exception - if an error occurred during the predictionpublic String getRevision()
getRevision in interface weka.core.RevisionHandlergetRevision in class weka.classifiers.AbstractClassifierpublic static void main(String[] args)
args - the parameters, use -h to display them
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||