BinnedDatapublic class MapBinnedData extends java.lang.Object implements BinnedData
| Modifier and Type | Class | Description |
|---|---|---|
static interface |
MapBinnedData.BinMapper |
Defines the mapping of numerical values to map keys.
|
BinnedData.Bin| Constructor | Description |
|---|---|
MapBinnedData(int nset,
MapBinnedData.BinMapper mapper) |
Constructs a new BinnedData.
|
| Modifier and Type | Method | Description |
|---|---|---|
static MapBinnedData.BinMapper |
createBinMapper(boolean logFlag,
double binWidth,
double binBase) |
Constructs a new linear or logarithmic BinMapper object.
|
java.util.Iterator |
getBinIterator(boolean includeEmpty) |
Returns an iterator over the bins managed by this object.
|
MapBinnedData.BinMapper |
getMapper() |
Returns the BinMapper object used by this BinnedData.
|
int |
getSetCount() |
Returns the number of subsets for which this object maintains bins.
|
boolean |
isInteger() |
Indicates whether the count values in the bins are known to be
integers.
|
void |
submitDatum(double value,
double weight,
boolean[] setFlags) |
Submits a value for inclusion in this BinnedData object.
|
public MapBinnedData(int nset,
MapBinnedData.BinMapper mapper)
nset - the number of subsets that this BinnedData can deal withmapper - a BinMapper implementation that defines the bin rangespublic void submitDatum(double value,
double weight,
boolean[] setFlags)
BinnedDatasubmitDatum in interface BinnedDatavalue - value for inclusionweight - weightingsetFlags - array of flags, one for each subset;
true for inclusion, false for exclusionpublic java.util.Iterator getBinIterator(boolean includeEmpty)
BinnedDataIt is inadvisable to call BinnedData.submitDatum(double, double, boolean[]) during the
lifetime of this iterator.
getBinIterator in interface BinnedDataincludeEmpty - if true, then all bins between the lowest
and highest must be iterated over. If false, then empty
bins may be omittedBinnedData.Bin instancespublic int getSetCount()
BinnedDatagetSetCount in interface BinnedDatapublic boolean isInteger()
BinnedDataisInteger in interface BinnedDataBin.getWeightedCount returns
are integer valuespublic MapBinnedData.BinMapper getMapper()
public static MapBinnedData.BinMapper createBinMapper(boolean logFlag, double binWidth, double binBase)
logFlag - false for linear spacing, true for logarithmicbinWidth - bin spacing
(additive for linear, multiplicative for logarithmic)binBase - lower bound of one (any) bin; determines bin phaseCopyright © 2018 Central Laboratory of the Research Councils. All Rights Reserved.