T
- Used to enforce that this instance only accepts
AxisScalePolicyTransformation
and subtypes.IAxis<T>
, java.io.Serializable
public class AxisLogE<T extends AxisScalePolicyTransformation> extends AAxisTransformation<T>
AAxis
with log scaled display of
values.
This will even not work with values < 1.0 as the log transformation turns
negative for values < 1.0 and becomes Double.NEGATIVE_INFINITY
with
lim -> 0.0 with more and more turns to a 100 % CPU load.
AAxis.AChart2DDataAccessor
AAxisTransformation.XDataAccessor, AAxisTransformation.YDataAccessor
IAxis.AxisTitle
DEBUG, m_accessor, m_formatter, m_majorTickSpacing, m_max, m_min, m_minorTickSpacing, m_needsFullRescale, m_rangePolicy
m_outputErrorTstamp
PROPERTY_ADD_REMOVE_TRACE, PROPERTY_AXIS_SCALE_POLICY_CHANGED, PROPERTY_LABELFORMATTER, PROPERTY_PAINTGRID, PROPERTY_PAINTSCALE, PROPERTY_RANGEPOLICY
Constructor | Description |
---|---|
AxisLogE() |
Creates an instance that uses a
LabelFormatterSimple for formatting
numbers and a AxisScalePolicyAutomaticBestFit for controlling the scale. |
AxisLogE(IAxisLabelFormatter formatter,
T scalePolicy) |
Creates an instance that will the given label formatter for formatting
labels.
|
Modifier and Type | Method | Description |
---|---|---|
double |
transform(double in) |
Performs
Math.log10(double) with a check for reaching infinity. |
double |
untransform(double in) |
Template method for performing the reverse axis transformation.
|
addPropertyChangeListener, addTrace, ensureInitialized, equals, findMax, findMin, getAccessor, getAxisPosition, getAxisScalePolicy, getAxisTitle, getDimension, getDimensionString, getFormatter, getHeight, getMajorTickSpacing, getMax, getMaxValue, getMin, getMinorTickSpacing, getMinValue, getPixelXLeft, getPixelXRight, getPixelYBottom, getPixelYTop, getPropertyChangeListeners, getRange, getRangePolicy, getTitle, getTitlePainter, getTraces, getValueDistanceForPixel, getWidth, hashCode, hasTrace, initPaintIteration, isDirtyScaling, isPaintGrid, isPaintScale, isStartMajorTick, isVisible, paint, paintTitle, propertyChange, removeAllTraces, removeAxisTitle, removePropertyChangeListener, removeTrace, scale, scalePoint, setAccessor, setAxisPosition, setAxisScalePolicy, setAxisTitle, setChart, setFormatter, setMajorTickSpacing, setMinorTickSpacing, setPaintGrid, setPaintScale, setPixelXLeft, setPixelXRight, setPixelYBottom, setPixelYTop, setRange, setRangePolicy, setStartMajorTick, setTitle, setTitlePainter, setVisible, translateValueToPx
createAccessor, getMaxTransformed, getMinTransformed, getScaledValue, scaleTrace, translateMousePosition, translatePxToValue
public AxisLogE()
LabelFormatterSimple
for formatting
numbers and a AxisScalePolicyAutomaticBestFit
for controlling the scale.
public AxisLogE(IAxisLabelFormatter formatter, T scalePolicy)
formatter
- needed for formatting labels of this axis. Prefer using simple
implementations like LabelFormatterSimple
, a log axis is
complicated enough to understand.scalePolicy
- controls the ticks/labels and their distance.public double transform(double in)
Math.log10(double)
with a check for reaching infinity.
The argument should not be negative, so only normalized values (no chart values but their scaled values or pixel values) should be given here.
If the argument is close to zero, the result of log would be
Double.POSITIVE_INFINITY
which is transformed to
Double.MAX_VALUE
.
transform
in class AAxisTransformation<T extends AxisScalePolicyTransformation>
in
- the value to compute the log base 10 of.public double untransform(double in)
AAxisTransformation
This is the counterpart to AAxisTransformation.transform(double)
.
untransform
in class AAxisTransformation<T extends AxisScalePolicyTransformation>
in
- the transformed value.AAxisTransformation.untransform(double)
Copyright © 2001 - 2010 LGPL, All Rights Footloose.