Class NoSplit

All Implemented Interfaces:
Serializable, Cloneable, RevisionHandler

public final class NoSplit extends ClassifierSplitModel
Class implementing a "no-split"-split.
$Revision: 8034 $
Eibe Frank (
See Also:
  • Constructor Details

    • NoSplit

      public NoSplit(Distribution distribution)
      Creates "no-split"-split for given distribution.
  • Method Details

    • buildClassifier

      public final void buildClassifier(Instances instances) throws Exception
      Creates a "no-split"-split for a given set of instances.
      Specified by:
      buildClassifier in class ClassifierSplitModel
      Exception - if split can't be built successfully
    • whichSubset

      public final int whichSubset(Instance instance)
      Always returns 0 because only there is only one subset.
      Specified by:
      whichSubset in class ClassifierSplitModel
    • weights

      public final double[] weights(Instance instance)
      Always returns null because there is only one subset.
      Specified by:
      weights in class ClassifierSplitModel
    • leftSide

      public final String leftSide(Instances instances)
      Does nothing because no condition has to be satisfied.
      Specified by:
      leftSide in class ClassifierSplitModel
      instances - the data.
    • rightSide

      public final String rightSide(int index, Instances instances)
      Does nothing because no condition has to be satisfied.
      Specified by:
      rightSide in class ClassifierSplitModel
    • sourceExpression

      public final String sourceExpression(int index, Instances data)
      Returns a string containing java source code equivalent to the test made at this node. The instance being tested is called "i".
      Specified by:
      sourceExpression in class ClassifierSplitModel
      index - index of the nominal value tested
      data - the data containing instance structure info
      a value of type 'String'
    • getRevision

      public String getRevision()
      Returns the revision string.
      the revision