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

## org.encog.util.normalize.segregate
Class RangeSegregator

    java.lang.Object
      org.encog.util.normalize.segregate.RangeSegregator

All Implemented Interfaces:
  Serializable, Segregator

    public class RangeSegregator

extends Object
implements Segregator

Range segregators are used to segregate data and include or exclude if it is within a certain range.

See Also:
  Serialized Form

Constructor Summary
`RangeSegregator()` Default constructor for reflection.
`RangeSegregator(InputField sourceField, boolean include)` Construct a range segregator.

Method Summary
`void` | `addRange(double low, double high, boolean include)` Add a range.
`void` | `addRange(SegregationRange range)` Add a range.
`DataNormalization` | `getNormalization()`
`InputField` | `getSourceField()`
`void` | `init(DataNormalization normalization)` Init the object.
`void` | `passInit()` Nothing needs to be done to setup for a pass.
`boolean` | `shouldInclude()` Should this row be included, according to this segregator.

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

Constructor Detail

### RangeSegregator

    public RangeSegregator()

  Default constructor for reflection.

### RangeSegregator

    public RangeSegregator(InputField sourceField,
                           boolean include)

  Construct a range segregator.

  Parameters:
    `sourceField` - The source field.
    `include` - Default action, if the data is not in any of the ranges, should it be included.

Method Detail

### addRange

    public void addRange(double low,
                         double high,
                         boolean include)

  Add a range.

  Parameters:
    `low` - The low end of the range.
    `high` - The high end of the range.
    `include` - Should this range be included.

### addRange

    public void addRange(SegregationRange range)

  Add a range.

  Parameters:
    `range` - The range to add.

### getNormalization

    public DataNormalization getNormalization()

  Specified by:
    `getNormalization` in interface `Segregator`
  Returns:
    The normalization object used by this object.

### getSourceField

    public InputField getSourceField()

  Returns:
    The source field that the ranges are compared against.

### init

    public void init(DataNormalization normalization)

  Init the object.

  Specified by:
    `init` in interface `Segregator`
  Parameters:
    `normalization` - The normalization object that owns this range.

### shouldInclude

    public boolean shouldInclude()

  Description copied from interface: `Segregator`
  Should this row be included, according to this segregator.

  Specified by:
    `shouldInclude` in interface `Segregator`
  Returns:
    True if the current row should be included according to this segregator.

### passInit

    public void passInit()

  Nothing needs to be done to setup for a pass.

  Specified by:
    `passInit` in interface `Segregator`

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

Copyright © 2012. All Rights Reserved.