- java.lang.Object
-
- eu.ess.xaos.ui.plot.data.ErrorSeries.ErrorData<X,Y>
-
- Enclosing class:
- ErrorSeries<X,Y>
public static final class ErrorSeries.ErrorData<X,Y> extends Object
-
-
Constructor Summary
Constructors Modifier Constructor Description ErrorData(ErrorSeries.ErrorData<X,Y> edata)Copy-constructor.protectedErrorData(XYChart.Data<X,Y> data)Initializes the data point and the 2Paths.ErrorData(XYChart.Data<X,Y> data, double yError)Creates an error data element without no X error data.ErrorData(XYChart.Data<X,Y> data, double xError, double yError)Creates an error data element.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description XYChart.Data<X,Y>getDataPoint()NodegetNode()doublegetXError()PathgetXErrorPath()XgetXValue()doublegetYError()PathgetYErrorPath()YgetYValue()booleanisXErrorValid()booleanisYErrorValid()booleanmatch(XYChart.Data<X,Y> dataPoint)voidsetDataPoint(XYChart.Data<X,Y> data)voidsetErrors(double xError, double yError)Sets the X and Y errors.voidsetXError(double xError)voidsetYErrorBar(double yError)voidshow(Axis<X> xAxis, Axis<Y> yAxis, double dataX, double dataY)Shows the error bar(s) at the given center point.
-
-
-
Constructor Detail
-
ErrorData
public ErrorData(XYChart.Data<X,Y> data, double yError)
Creates an error data element without no X error data.- Parameters:
data- The data point around which the error exists.yError- The Y error around the data point:--- | | y | | ---
Double.NaNis used to indicate no Y error value.
-
ErrorData
public ErrorData(XYChart.Data<X,Y> data, double xError, double yError)
Creates an error data element.- Parameters:
data- The data point around which the error exists.xError- The X error around the data point:|---x---|.Double.NaNis used to indicate no X error value.yError- The Y error around the data point:--- | | y | | ---
Double.NaNis used to indicate no Y error value.
-
ErrorData
public ErrorData(ErrorSeries.ErrorData<X,Y> edata)
Copy-constructor.- Parameters:
edata- TheErrorSeries.ErrorDatato be copied.
-
ErrorData
protected ErrorData(XYChart.Data<X,Y> data)
Initializes the data point and the 2Paths.- Parameters:
data- The data point.
-
-
Method Detail
-
getDataPoint
public XYChart.Data<X,Y> getDataPoint()
- Returns:
- The data point around which the error exists.
-
getXError
public double getXError()
- Returns:
- The X error around the data point:
|---x---|.Double.NaNis used to indicate no X error value.
-
getXValue
public X getXValue()
- Returns:
getDataPoint().getXValue().
-
getYError
public double getYError()
- Returns:
- The Y error around the data point:
--- | | y | | ---
Double.NaNis used to indicate no Y error value.
-
getYErrorPath
public Path getYErrorPath()
- Returns:
- The
Pathused to draw the Y error:--- | | y | | ---
-
getYValue
public Y getYValue()
- Returns:
getDataPoint().getYValue().
-
isXErrorValid
public boolean isXErrorValid()
- Returns:
- Return
trueif the X error around the data point is notDouble.NaN.
-
isYErrorValid
public boolean isYErrorValid()
- Returns:
- Return
trueif the Y error around the data point is notDouble.NaN.
-
match
public boolean match(XYChart.Data<X,Y> dataPoint)
- Parameters:
dataPoint- The data point to be compared with the one in this object.- Returns:
trueif the given data point matches the one stored in this object.
-
setDataPoint
public void setDataPoint(XYChart.Data<X,Y> data)
- Parameters:
data- The new data point around which the error exists.
-
setErrors
public void setErrors(double xError, double yError)Sets the X and Y errors.- Parameters:
xError- The X error around the data point:|---x---|.Double.NaNis used to indicate no X error value.yError- The Y error around the data point:--- | | y | | ---
Double.NaNis used to indicate no Y error value.
-
setXError
public void setXError(double xError)
- Parameters:
xError- The X error around the data point:|---x---|.Double.NaNis used to indicate no X error value.
-
setYErrorBar
public void setYErrorBar(double yError)
- Parameters:
yError- The Y error around the data point:--- | | y | | ---
Double.NaNis used to indicate no Y error value.
-
-