Highcharts Demo

author(s): Torstein Hønsi

by core972

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} %'
      }
    }
  },
  series: [{
    name: 'Brands',
    dataLabels: {
      padding: 0
    },
    data: [{
        name: "Nike",
        y: 91.6
      },
      {
        name: "Adidas",
        y: 0.2
      },
      {
        name: "Puma",
        y: 0.2
      },
      {
        name: "Skechers",
        y: 1.6
      },
      {
        name: "North face",
        y: 0.2
      },
      {
        name: "Asics",
        y: 0.2
      },
    ]
  }]
});