Contours
public struct Contours : Encodable
Note
Used byHistogram2DContour<XData, YData, ZData>.contours
, Contour<ZData, XData,
YData>.contours
, ContourCarpet<ZData, AData, BData>.contours
.
-
Sets the starting contour level value.
Must be less than
contours.end
Declaration
Swift
public var start: Double?
-
Sets the end contour level value.
Must be more than
contours.start
Declaration
Swift
public var end: Double?
-
Sets the step between each contour level.
Must be positive.
Declaration
Swift
public var size: Double?
-
Determines the coloring method showing the contour values.
If fill, coloring is done evenly between each contour level If heatmap, a heatmap gradient coloring is applied between each contour level. If lines, coloring is done on the contour lines. If none, no coloring is applied on this trace.
See moreDeclaration
Swift
public enum Coloring : String, Encodable
-
Determines the coloring method showing the contour values.
If fill, coloring is done evenly between each contour level If heatmap, a heatmap gradient coloring is applied between each contour level. If lines, coloring is done on the contour lines. If none, no coloring is applied on this trace.
Declaration
Swift
public var coloring: Coloring?
-
Determines whether or not the contour lines are drawn.
Has an effect only if
contours.coloring
is set to fill.Declaration
Swift
public var showLines: Bool?
-
Determines whether to label the contour lines with their values.
Declaration
Swift
public var showLabels: Bool?
-
Sets the font used for labeling the contour levels.
The default color comes from the lines, if shown. The default family and size come from
layout.font
.Declaration
Swift
public var labelFont: Font?
-
Sets the contour label formatting rule using d3 formatting mini-language which is very similar to Python, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format
Declaration
Swift
public var labelFormat: String?
-
Sets the constraint operation.
= keeps regions equal to
value
< and <= keep regions less thanvalue
> and >= keep regions greater thanvalue
[], (), [), and (] keep regions insidevalue[0]
tovalue[1]
], *)(, *[ keep regions outsidevalue[0]
to value[1]` Open vs. closed intervals make no difference to constraint display, but all versions are allowed for consistency with filter transforms.Declaration
Swift
public var operation: Operation?
-
Sets the value or values of the constraint boundary.
When
operation
is set to one of the comparison values (=,<,>=,>,<=) value is expected to be a number. Whenoperation
is set to one of the interval values ([],(),[),(],],)(,[) value is expected to be an array of two numbers where the first is the lower bound and the second is the upper bound.Declaration
Swift
public var value: Anything?
-
Creates
Contours
object with specified properties.Declaration
Parameters
type
If
levels
, the data is represented as a contour plot with multiple levels displayed.start
Sets the starting contour level value.
end
Sets the end contour level value.
size
Sets the step between each contour level.
coloring
Determines the coloring method showing the contour values.
showLines
Determines whether or not the contour lines are drawn.
showLabels
Determines whether to label the contour lines with their values.
labelFont
Sets the font used for labeling the contour levels.
labelFormat
Sets the contour label formatting rule using d3 formatting mini-language which is very similar to Python, see: https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format
operation
Sets the constraint operation.
value
Sets the value or values of the constraint boundary.