positionRange(forY:)
Returns the range of y position for the given data value, or nil if the x scale is unavailable or if the value is invalid. The returned position range is relative to the plot.
Declaration
func positionRange<P>(forY value: P) -> ClosedRange<CGFloat>? where P : PlottableParameters
- value:
The data value.
Return Value
The position range corresponding to the data value.
Discussion
For a continuous data value, the returned range is a single point. For a categorical data value, the returned range is the range of positions that correspond to the given category.