position(for:)
Returns the x and y positions as a CGPoint for the given data values, or nil if either the X or the y scale is unavailable or if any data value is invalid. The returned position is relative to the plot.
Declaration
func position<X, Y>(for point: (x: X, y: Y)) -> CGPoint? where X : Plottable, Y : PlottableParameters
- point:
A tuple of x and y data values.
Return Value
The position corresponding to the data values.