Overview | Package | Class | Tree | Deprecated | Index | Help | Weka's home
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## weka.classifiers.meta
Class Decorate

    java.lang.Object
      weka.classifiers.Classifier
          weka.classifiers.SingleClassifierEnhancer
              weka.classifiers.IteratedSingleClassifierEnhancer
                  weka.classifiers.RandomizableIteratedSingleClassifierEnhancer
                      weka.classifiers.meta.Decorate

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable, OptionHandler, Randomizable

    public class Decorate

extends RandomizableIteratedSingleClassifierEnhancer

DECORATE is a meta-learner for building diverse ensembles of classifiers by using specially constructed artificial training examples. Comprehensive experiments have demonstrated that this technique is consistently more accurate than the base classifier, Bagging and Random Forests. Decorate also obtains higher accuracy than Boosting on small training sets, and achieves comparable performance on larger training sets. For more details see:

Prem Melville and Raymond J. Mooney. Constructing diverse classifier ensembles using artificial training examples. Proceedings of the Seventeeth International Joint Conference on Artificial Intelligence 2003.

Prem Melville and Raymond J. Mooney. Creating diversity in ensembles using artificial data. Submitted.
Valid options are:

-D
Turn on debugging output.

-W classname
Specify the full class name of a weak classifier as the basis for Decorate (default weka.classifiers.trees.J48()).

-E num
Specify the desired size of the committee (default 10).

-I iterations
Set the maximum number of Decorate iterations (default 10).

-S seed
Seed for random number generator. (default 0).

-R factor
Factor that determines number of artificial examples to generate.

Options after -- are passed to the designated classifier.

Version:
  $Revision: 1.3.2.1 $
Author:
  Prem Melville (melville@cs.utexas.edu)
See Also:
  Serialized Form

Constructor Summary
`Decorate()` Constructor.

Method Summary
`java.lang.String` | `artificialSizeTipText()` Returns the tip text for this property
`void` | `buildClassifier(Instances data)` Build Decorate classifier
`java.lang.String` | `desiredSizeTipText()` Returns the tip text for this property
`double[]` | `distributionForInstance(Instance instance)` Calculates the class membership probabilities for the given test instance.
`double` | `getArtificialSize()` Factor that determines number of artificial examples to generate.
`int` | `getDesiredSize()` Gets the desired size of the committee.
`java.lang.String[]` | `getOptions()` Gets the current settings of the Classifier.
`java.lang.String` | `globalInfo()` Returns a string describing classifier
`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` | `numIterationsTipText()` Returns the tip text for this property
`void` | `setArtificialSize(double newArtSize)` Sets factor that determines number of artificial examples to generate.
`void` | `setDesiredSize(int newDesiredSize)` Sets the desired size of the committee.
`void` | `setOptions(java.lang.String[] options)` Parses a given list of options.
`java.lang.String` | `toString()` Returns description of the Decorate classifier.

Methods inherited from class weka.classifiers.RandomizableIteratedSingleClassifierEnhancer
`getSeed, seedTipText, setSeed`

Methods inherited from class weka.classifiers.IteratedSingleClassifierEnhancer
`getNumIterations, setNumIterations`

Methods inherited from class weka.classifiers.SingleClassifierEnhancer
`classifierTipText, getClassifier, setClassifier`

Methods inherited from class weka.classifiers.Classifier
`classifyInstance, debugTipText, forName, getDebug, makeCopies, makeCopy, setDebug`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### Decorate

    public Decorate()

  Constructor.

Method Detail

### listOptions

    public java.util.Enumeration listOptions()

  Returns an enumeration describing the available options

  Specified by:
    `listOptions` in interface `OptionHandler`
  Overrides:
    `listOptions` in class `RandomizableIteratedSingleClassifierEnhancer`
  Returns:
    an enumeration of all the available options

### setOptions

    public void setOptions(java.lang.String[] options)
                    throws java.lang.Exception

  Parses a given list of options. Valid options are:

  -D
  Turn on debugging output.

  -W classname
  Specify the full class name of a weak classifier as the basis for Decorate (required).

  -E num
  Specify the desired size of the committee (default 10).

  -I iterations
  Set the maximum number of Decorate iterations (default 10).

  -S seed
  Seed for random number generator. (default 0).

  -R factor
  Factor that determines number of artificial examples to generate.

  Options after -- are passed to the designated classifier.

  Specified by:
    `setOptions` in interface `OptionHandler`
  Overrides:
    `setOptions` in class `RandomizableIteratedSingleClassifierEnhancer`
  Parameters:
    `options` - the list of options as an array of strings
  Throws:
    `java.lang.Exception` - if an option is not supported

### getOptions

    public java.lang.String[] getOptions()

  Gets the current settings of the Classifier.

  Specified by:
    `getOptions` in interface `OptionHandler`
  Overrides:
    `getOptions` in class `RandomizableIteratedSingleClassifierEnhancer`
  Returns:
    an array of strings suitable for passing to setOptions

### desiredSizeTipText

    public java.lang.String desiredSizeTipText()

  Returns the tip text for this property

  Returns:
    tip text for this property suitable for displaying in the explorer/experimenter gui

### numIterationsTipText

    public java.lang.String numIterationsTipText()

  Returns the tip text for this property

  Overrides:
    `numIterationsTipText` in class `IteratedSingleClassifierEnhancer`
  Returns:
    tip text for this property suitable for displaying in the explorer/experimenter gui

### artificialSizeTipText

    public java.lang.String artificialSizeTipText()

  Returns the tip text for this property

  Returns:
    tip text for this property suitable for displaying in the explorer/experimenter gui

### globalInfo

    public java.lang.String globalInfo()

  Returns a string describing classifier

  Returns:
    a description suitable for displaying in the explorer/experimenter gui

### getArtificialSize

    public double getArtificialSize()

  Factor that determines number of artificial examples to generate.

  Returns:
    factor that determines number of artificial examples to generate

### setArtificialSize

    public void setArtificialSize(double newArtSize)

  Sets factor that determines number of artificial examples to generate.

  Parameters:
    `newwArtSize` - factor that determines number of artificial examples to generate

### getDesiredSize

    public int getDesiredSize()

  Gets the desired size of the committee.

  Returns:
    the desired size of the committee

### setDesiredSize

    public void setDesiredSize(int newDesiredSize)

  Sets the desired size of the committee.

  Parameters:
    `newDesiredSize` - the desired size of the committee

### buildClassifier

    public void buildClassifier(Instances data)
                         throws java.lang.Exception

  Build Decorate classifier

  Overrides:
    `buildClassifier` in class `IteratedSingleClassifierEnhancer`
  Parameters:
    `data` - the training data to be used for generating the classifier
  Throws:
    `java.lang.Exception` - if the classifier could not be built successfully

### distributionForInstance

    public double[] distributionForInstance(Instance instance)
                                     throws java.lang.Exception

  Calculates the class membership probabilities for the given test instance.

  Overrides:
    `distributionForInstance` in class `Classifier`
  Parameters:
    `instance` - the instance to be classified
  Returns:
    predicted class probability distribution
  Throws:
    `java.lang.Exception` - if distribution can't be computed successfully

### toString

    public java.lang.String toString()

  Returns description of the Decorate classifier.

  Overrides:
    `toString` in class `java.lang.Object`
  Returns:
    description of the Decorate classifier as a string

### main

    public static void main(java.lang.String[] argv)

  Main method for testing this class.

  Parameters:
    `argv` - the options

Overview | Package | Class | Tree | Deprecated | Index | Help | Weka's home
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD