Stacked Pie study

by kzoon

HTML

<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="min-width: 310px; height: 400px; margin: 0 auto"></div>

JavaScript

$(function () {
    $('#container').highcharts({
        chart: {
            plotBackgroundColor: null,
            plotBorderWidth: null,
            plotShadow: false
        },
        title: {
            text: 'Browser market shares 2013 vs 2014'
        },
        tooltip: {
            pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
        },


        plotOptions: {
            pie: {
                allowPointSelect: true,
                cursor: 'pointer',
                center: ['50%', '50%'],
                dataLabels: {
                    enabled: true,
                    color: '#000000',
                    connectorColor: '#000000',
                    format: '<b>{point.name}</b>: {point.percentage:.1f} %'
                }
            }
        },
        series: [{
            type: 'pie',
            name: 'Browser share',
            size: '60%',
            dataLabels: {
                enabled: false
            },
            data: [
                ['Chrome', 45.0],
                ['IE', 36.8],
                ['Other', 10]
            ]
        }, {
            type: 'pie',
            name: 'Browser share',
            size: '80%',
            innerSize: '60%',

            data: [
                ['Chrome', 55.0],
                ['IE', 32.8],
                ['Other', 8]
            ]
        }]
    });
});