layer Labels
Configures annotations (for pie chart). Defines the content and format for displaying the value.
Examples
val data = mapOf("name" to listOf("a", "b", "c", "d", "b"), "value" to listOf(40, 90, 10, 50, 20))
letsPlot(data) +
geomPie(
size = 15, hole = 0.2,
labels = layerLabels("..proppct..").format("..proppct..", "{.1f}%").size(15)
) { fill = asDiscrete("name", orderBy = "..count.."); weight = "value" }
Content copied to clipboard
Parameters
variables
Variable names to place in the annotation with default formatting. Useful for specifying the annotation content quickly, instead of configuring it via the line()
method.
Functions
Link copied to clipboard
Defines the format for displaying the value. The format will be applied to the corresponding value specified in the line template.
Link copied to clipboard
Specifies the string template to use in the annotation.
Link copied to clipboard
Specifies a text size in the annotation.