How to display both Percentage and Values in Google Pie Chart ?
Asked
Active
Viewed 2.9k times
14
-
3You can't display both on the slice labels, but if you set the `pieSliceText` option to `'label'` and the `legend.position` option to `'labeled'`, you will see the value on the slice and the percent on the legend label. – asgallant Mar 12 '14 at 20:40
3 Answers
42
You can set pieSliceText
as value-and-percentage
to display both Value and Percentage.
var options = {
pieSliceText: 'value-and-percentage'
};
var chart = new google.visualization.PieChart(document.getElementById('chart_div'));
chart.draw(data, options);
Please note that this option is currently undocumented (see this), so please use at your own risk.

Ajay2707
- 5,690
- 6
- 40
- 58

user4756986
- 436
- 5
- 3
2
You can not display both on the chart labels. For reference use this

Lrrr
- 4,755
- 5
- 41
- 63

HRISHIKESH BARHATE
- 21
- 2
0
you can put isStacked: 'percent'
in the option of your chart.
when mouse hover it will showing like this 10 (100%)

Vinicius
- 133
- 5