Highcharts Demo
author(s): Torstein Hønsi
by dday515
HTML
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<script src="https://code.highcharts.com/modules/export-data.js"></script>
<div id="container" style="min-width: 310px; height: 400px; max-width: 600px; margin: 0 auto"></div>
JavaScript
Highcharts.chart('container', {
chart: {
plotBackgroundColor: null,
plotBorderWidth: null,
plotShadow: false,
type: 'pie'
},
title: {
text: 'Browser market shares in January, 2018'
},
tooltip: {
pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
},
plotOptions: {
pie: {
allowPointSelect: true,
cursor: 'pointer',
dataLabels: {
enabled: true,
format: '<b>{point.name}</b>: {point.percentage:.1f} %',
style: {
color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black'
}
}
}
},
series: [{
name: 'Brands',
colorByPoint: true,
animation: false,
data:[
{
"name": "All Others",
"y": .25,
"animation": false
},
{
"name": "Circulatory System",
"y": .25,
"animation": false
},
{
"name": "Digestive System",
"y": .10,
"animation": false
},
{
"name": "Infectious and Parasitic DDs",
"y": .10,
"animation": false
},
{
"name": "Newborn And Other Neonates (Perinatal Period)",
"y": .10,
"animation": false
},
{
"name": "Pregnancy, Childbirth And Puerperium",
"y": .10,
"animation": false
},
{
"name":...