hep.analysis.partition
Class SimpleBinner

java.lang.Object
  |
  +--hep.analysis.partition.SimpleBinner
All Implemented Interfaces:
BinType, OneDBinner, java.io.Serializable, SimpleOneDDataSource

public class SimpleBinner
extends java.lang.Object
implements BinType

Simple calculates the contents of each bin as the sum of the weights in each bin.

See Also:
Serialized Form

Field Summary
protected  int m_bins
           
protected  double[] m_error
           
protected  double[] m_hist
           
 
Constructor Summary
SimpleBinner(int bins)
           
 
Method Summary
 void clear()
           
 void fill(int bin)
           
 void fillW(int bin, double v)
           
 double[] getBins()
           
 double[] getMinusErrors()
           
 int getNumberOfBins()
           
 double[] getPlusErrors()
           
 boolean hasAsymmetricErrorBars()
           
 boolean hasSimpleQuadraticErrorBars()
           
 void setNumberOfBins(int bins)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_bins

protected int m_bins

m_hist

protected double[] m_hist

m_error

protected double[] m_error
Constructor Detail

SimpleBinner

public SimpleBinner(int bins)
Method Detail

clear

public void clear()
Specified by:
clear in interface OneDBinner

fill

public void fill(int bin)
Specified by:
fill in interface OneDBinner

fillW

public void fillW(int bin,
                  double v)
Specified by:
fillW in interface OneDBinner

getBins

public double[] getBins()
Specified by:
getBins in interface SimpleOneDDataSource

getPlusErrors

public double[] getPlusErrors()
Specified by:
getPlusErrors in interface SimpleOneDDataSource

getMinusErrors

public double[] getMinusErrors()
Specified by:
getMinusErrors in interface SimpleOneDDataSource

setNumberOfBins

public void setNumberOfBins(int bins)
Specified by:
setNumberOfBins in interface OneDBinner

getNumberOfBins

public int getNumberOfBins()
Specified by:
getNumberOfBins in interface OneDBinner

hasSimpleQuadraticErrorBars

public boolean hasSimpleQuadraticErrorBars()
Specified by:
hasSimpleQuadraticErrorBars in interface SimpleOneDDataSource

hasAsymmetricErrorBars

public boolean hasAsymmetricErrorBars()
Specified by:
hasAsymmetricErrorBars in interface SimpleOneDDataSource