Package com.macrofocus.high_d.distributions

# Class FixedBinsHistogram<R>

java.lang.Object
com.macrofocus.high_d.distributions.FixedBinsHistogram<R>

All Implemented Interfaces:
  `Histogram<R>`

public class FixedBinsHistogram<R> extends Object implements Histogram<R>
A class that models a standard histogram. A histogram consists of a number of equally sized and contiguous bins that cover a certain interval. Values that are added to the histogram are classified into their corresponding bin, which means that the count of the bin is incremented. Values that fall outside the interval, are classified into the underflow resp. overflow bins.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `FixedBinsHistogram(int nbins, double min, double max, Filter<R> filter)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addValue(R row, double value)`
  `int`
  `getActiveDensity(int index)`
  `R`
  `getActiveRowAtBin(int j, int index)`
  `int`
  `getBin(double value)`
  `double`
  `getBinEndValue(int bin)`
  `double`
  `getBinStartValue(int bin)`
  `int`
  `getDensity(int index)`
  `int`
  `getMaxActiveDensity()`
  `int`
  `getMaxDensity()`
  `double`
  `getMaxValue()`
  `double`
  `getMinValue()`
  `int`
  `getNumberOfBins()`
  `int`
  `getOverflowBin()`
  `int`
  `getUnderflowBin()`
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### FixedBinsHistogram

    public FixedBinsHistogram(int nbins, double min, double max, Filter<R> filter)

- ## Method Details

  - ### addValue

    public void addValue(R row, double value)

  - ### getActiveDensity

    public int getActiveDensity(int index)
    Specified by:
      `getActiveDensity` in interface `Histogram<R>`

  - ### getActiveRowAtBin

    public R getActiveRowAtBin(int j, int index)
    Specified by:
      `getActiveRowAtBin` in interface `Histogram<R>`

  - ### getDensity

    public int getDensity(int index)
    Specified by:
      `getDensity` in interface `Histogram<R>`

  - ### getNumberOfBins

    public int getNumberOfBins()
    Specified by:
      `getNumberOfBins` in interface `Histogram<R>`

  - ### getMinValue

    public double getMinValue()
    Specified by:
      `getMinValue` in interface `Histogram<R>`

  - ### getMaxValue

    public double getMaxValue()
    Specified by:
      `getMaxValue` in interface `Histogram<R>`

  - ### getBinStartValue

    public double getBinStartValue(int bin)
    Specified by:
      `getBinStartValue` in interface `Histogram<R>`

  - ### getBinEndValue

    public double getBinEndValue(int bin)
    Specified by:
      `getBinEndValue` in interface `Histogram<R>`

  - ### getMaxActiveDensity

    public int getMaxActiveDensity()
    Specified by:
      `getMaxActiveDensity` in interface `Histogram<R>`

  - ### getMaxDensity

    public int getMaxDensity()
    Specified by:
      `getMaxDensity` in interface `Histogram<R>`

  - ### getUnderflowBin

    public int getUnderflowBin()

  - ### getOverflowBin

    public int getOverflowBin()

  - ### getBin

    public int getBin(double value)
    Specified by:
      `getBin` in interface `Histogram<R>`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`