Doughnut and Pie Chart
The Doughnut and Pie Chart work in the same way.
Example
Pie Chart
```chart
type: pie
labels: [Monday,Tuesday,Wednesday,Thursday,Friday]
series:
- title: Title 1
data: [1,2,3,4,5]
- title: Title 2
data: [5,4,3,2,1]
width: 40%
labelColors: true
```
The above code will render a Pie Chart.
A width
Modifier is added to fix the width of the Chart.
The Property labelColors
is also set to true
, which is the desired behaviour most of the time.
Doughnut Chart
```chart
type: doughnut
labels: [Monday,Tuesday,Wednesday,Thursday,Friday]
series:
- title: Title 1
data: [1,2,3,4,5]
- title: Title 2
data: [5,4,3,2,1]
width: 40%
labelColors: true
```
Advanced
See Modifiers for advanced configuration.