labels

property BoxPlot.labels

Return or set the this plot’s labels, as shown in the chart’s legend.

Examples

Create a box plot.

>>> import pyvista
>>> chart = pyvista.ChartBox([[0, 1, 1, 2, 3, 4, 5], [0, 1, 2, 2, 3, 4, 5], [0, 1, 2, 3, 3, 4, 5], [0, 1, 2, 3, 4, 4, 5]])
>>> plot = chart.plot
>>> chart.show()
../../../../_images/pyvista-plotting-charts-BoxPlot-labels-1_00_00.png

Modify the labels.

>>> plot.labels = ["A", "B", "C", "D"]
>>> chart.show()
../../../../_images/pyvista-plotting-charts-BoxPlot-labels-1_01_00.png