public interface Histogramming
Delimiters are the boundaries of the intervals that histogram values refer to. The intervals are assumed to be contiguous, so that a given delimiter is the right-hand boundary of one interval and the left-hand boundary of the next higher interval. Only the lowest and highest delimiters are boundaries of only one interval. Delimiter values are assumed to be monotonically increasing.
In each dimension there is one more delimiter value than the number of intervals, so the number of independent data values is one larger than the length of the corresponding dimension of the dependent data array (histogram values). The Histogramming interface provides methods to set and access the extra independent data. It allows for the possibility that the lowest or highest interval may be unbounded, so that the first delimiter could have the value $Double.NEGATIVE_INFINITY^ or the last could be $Double.POSITIVE_INFINITY^.
The Histogramming interface does not specify how a type should implement the storage of this data. This is up to the programmer. In the TrianaType called Histogram, which implements the Histogramming interface for one-dimensional histograms, the extra delimiter value is stored as a parameter.
Modifier and Type | Method and Description |
---|---|
double[] |
getDelimiterArray(int dim)
Returns the whole set of delimiters for the intervals of the histogram in the given dimension (independent
variable).
|
Triplet |
getDelimiterTriplet(int dim)
Returns a Triplet that describes the set of delimiters in the given dimension.
|
boolean |
isUnboundedIntervalAbove(int dim)
Returns $true^ if the last interval in the given dimension is unbounded above, i.e.
|
boolean |
isUnboundedIntervalBelow(int dim)
Returns $true^ if the first interval in the given dimension is unbounded below, $i.e.^ if the first delimiter is
$Double.NEGATIVE_INFINITY^, and $false^ otherwise.
|
boolean |
isUniformDelimiterSet(int dim)
Returns $true^ if the set of delimiters in the given dimension is uniform, $false^ otherwise.
|
void |
setDelimiters(double[] del,
int dim)
Sets the delimiters associated with the given dimension to the given double[] array.
|
void |
setDelimiters(Triplet del,
int dim)
Sets the delimiters associated with the given dimension to the given Triplet.
|
double[] getDelimiterArray(int dim)
dim
- The index of the independent variable being queriedTriplet getDelimiterTriplet(int dim)
dim
- The index of the independent variable being queriedboolean isUniformDelimiterSet(int dim)
dim
- The index of the independent variable being queriedvoid setDelimiters(double[] del, int dim)
del
- The array of delimitersdim
- The index of the independent variable being queriedvoid setDelimiters(Triplet del, int dim)
del
- The array of delimitersdim
- The index of the independent variable being queriedboolean isUnboundedIntervalBelow(int dim)
dim
- The index of the independent variable being queriedboolean isUnboundedIntervalAbove(int dim)
dim
- The index of the independent variable being queried