public class FloatVariableAxis extends Object implements FloatIAxis
Constructor and Description |
---|
FloatVariableAxis(float[] edges)
Constructs and returns an axis with the given bin edges.
|
Modifier and Type | Method and Description |
---|---|
float |
binCentre(int index)
Centre of the bin specified.
|
float |
binLowerEdge(int index)
Lower edge of the specified bin.
|
int |
bins()
The number of bins (excluding underflow and overflow) on the axis.
|
float |
binUpperEdge(int index)
Upper edge of the specified bin.
|
float |
binWidth(int index)
Width of the bin specified.
|
int |
coordToIndex(float coord)
Converts a coordinate on the axis to a bin number.
|
float |
lowerEdge()
Lower axis edge.
|
float |
upperEdge()
Upper axis edge.
|
public FloatVariableAxis(float[] edges)
edges
- the bin boundaries the partition shall have; must be sorted
ascending and must not contain multiple identical elements.IllegalArgumentException
- if edges.length < 1.public float binCentre(int index)
FloatIAxis
binCentre
in interface FloatIAxis
index
- Bin number (0...bins()-1) or OVERFLOW or UNDERFLOW.public float binLowerEdge(int index)
FloatIAxis
binLowerEdge
in interface FloatIAxis
index
- Bin number (0...bins()-1) or OVERFLOW or UNDERFLOW.public int bins()
FloatIAxis
bins
in interface FloatIAxis
public float binUpperEdge(int index)
FloatIAxis
binUpperEdge
in interface FloatIAxis
index
- Bin number (0...bins()-1) or OVERFLOW or UNDERFLOW.public float binWidth(int index)
FloatIAxis
binWidth
in interface FloatIAxis
index
- Bin number (0...bins()-1) or OVERFLOW or UNDERFLOW.public int coordToIndex(float coord)
FloatIAxis
coordToIndex
in interface FloatIAxis
public float lowerEdge()
FloatIAxis
lowerEdge
in interface FloatIAxis
public float upperEdge()
FloatIAxis
upperEdge
in interface FloatIAxis
Jump to the Parallel Colt Homepage