Contents

init(x:yStart:yEnd:domain:function:)

Creates a mark that fills the area between two functions (yStart, yEnd) = f(x).

Declaration

nonisolated init(x: LocalizedStringResource, yStart: LocalizedStringResource, yEnd: LocalizedStringResource, domain: ClosedRange<Double>? = nil, function: @escaping  @Sendable (Double) -> (yStart: Double, yEnd: Double))

Discussion

Parameters:

  • x: The localized string resource for the x label.

  • yStart: The localized string resource for the start label.

  • yEnd: The localized string resource for the end label.

  • domain: The domain of x. If set to nil, the domain of the chart’s x scale will be used.

  • function: The function to graph. Returns a tuple of (yStart: yStart, yEnd: yEnd).

See Also

Plotting functions