Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script>
- var chart;
- $(document).ready(function() {
- chart = new Highcharts.Chart({
- chart: {
- renderTo: 'gender',
- plotBackgroundColor: null,
- plotBorderWidth: null,
- plotShadow: false
- },
- title: {
- text: 'Points Generated by Gender'
- },
- tooltip: {
- pointFormat: '{point.percentage}%',
- percentageDecimals: 1
- },
- plotOptions: {
- pie: {
- allowPointSelect: true,
- cursor: 'pointer',
- dataLabels: {
- enabled: true,
- color: '#000000',
- connectorColor: '#000000',
- formatter: function() {
- return '<b>'+ this.point.name +'</b>: '+ this.percentage +' %';
- }
- }
- }
- },
- series: [{
- type: 'pie',
- name: 'Gender',
- data: [
- ['Male', 55],
- ['Female', 45]
- ]
- }]
- });
- });
- </script>
Add Comment
Please, Sign In to add comment