CPlotView:GetPtErrX
The GetPtErrX method returns the x errorbar value of a point in the class data matrix.
xErr = CPlotView:GetPtErrX( n ) |
This method returns the x errorbar value of the specified point at index n. If n is out of range, the value 0 is returned. To remove ambiguity about whether the point truly has an x errorbar value of 0 or is out of bounds, check the index before calling this method.
The following script fragment adds some points, then finds the nearest point and prints its x errorbar value:
|
-- create a new CPlotView |
|
-- add a point |
|
-- add a point |
|
-- get index of point nearest 4,72 |
|
-- result: n = 1, xerr = 10.25 |