FusionCharts - Pie 2D Chart in Javascript

Created using FusionCharts Suite XT - www.fusioncharts.com

by Rayudu Ikkurthi

HTML

<script src="https://cdn.fusioncharts.com/fusioncharts/latest/fusioncharts.js"></script>
<script src="https://cdn.fusioncharts.com/fusioncharts/latest/themes/fusioncharts.theme.fusion.js"></script>
<!-- Basic samples for Pie 2D Chart showing split of revenue by product categories for last year.
-->
<div id="chart-container">FusionCharts will render here</div>

CSS

body div {
  float: left;
  padding: 0 10px;
}

JavaScript

FusionCharts.ready(function() {
  var revenueChart = new FusionCharts({
    type: 'pie2d',
    renderAt: 'chart-container',
    width: '550',
    height: '350',
    dataFormat: 'json',
    dataSource: {
      "chart": {
        "caption": '',
						"manageresize": '1',
						"subCaption": '',
						"baseFontSize": '16',
						"labelFontBold": '1',
						"enableSlicing": '0',
						// numberPrefix: '$',
						"showPercentValues": '0',
						"showPercentInTooltip": '0',
						"decimals": '1',
						"pieRadius": '72',
						"enableSmartLabels": '0',
						"showLabels": '0',
						"use3DLighting": '0',
						"showShadow": '0',
						"slicingDistance": '0',
						"startingAngle": '0',
						"showValues": '0',
						"showLegend": '0',
						"bgColor": "#F2F5F8",
						"chartLeftMargin": "2",
						"chartTopMargin": "2",
						"chartRightMargin": "2",
						"chartBottomMargin": "2",
						"theme": "fusion"
      },
      "data": [{
          "label": "Food",
          "value": "285040"
        },
        {
          "label": "Apparels",
          "value": "146330"
        },
        {
          "label": "Electronics",
          "value": "105070"
        },
        {
          "label": "Household",
          "value": "49100"
        }
      ]
    }
  }).render();

});