pyvista.plotting.charts.PiePlot.update

Contents

pyvista.plotting.charts.PiePlot.update#

PiePlot.update(data) None[source]#

Update the size of the pie segments.

Parameters:
dataarray_like

The new relative size of each pie segment.

Examples

Create a pie plot with segments of increasing size.

>>> import pyvista as pv
>>> chart = pv.ChartPie([1, 2, 3, 4, 5])
>>> chart.show()
../../../../_images/pyvista-plotting-charts-PiePlot-update-2_00_00.png

Update the pie plot (segments of equal size).

>>> chart.plot.update([1, 1, 1, 1, 1])
>>> chart.show()
../../../../_images/pyvista-plotting-charts-PiePlot-update-2_01_00.png