Skip to content

Instantly share code, notes, and snippets.

@shadowdoc
Created July 31, 2014 21:51
Show Gist options
  • Select an option

  • Save shadowdoc/2e9f27b9427f6d49aad2 to your computer and use it in GitHub Desktop.

Select an option

Save shadowdoc/2e9f27b9427f6d49aad2 to your computer and use it in GitHub Desktop.
Capricorn Trainee Highchart Code
$(function () {
$('#container').highcharts({
chart: {
type: 'column'
},
title: {
text: 'Total Volume By Trainee'
},
xAxis: {
categories: ['Trainee1',
'Trainee2',
'Trainee3',
'Trainee4',
'Trainee5',
'Trainee6',
'Trainee7',
'Trainee8',
'Trainee9',
'Trainee10',
'Trainee11',
'Trainee12',
'Trainee13',
'Trainee14',
'Trainee15'],
labels: {rotation: 90}
},
yAxis: {
allowDecimals: false,
min: 0,
title: {
text: 'Number of exams'
}
},
tooltip: {
formatter: function() {
return '<b>'+ this.x +'</b><br/>'+
this.series.name +': '+ this.y +'<br/>'+
'Total: '+ this.point.stackTotal;
}
},
plotOptions: {
column: {
stacking: 'normal'
}
},
series: [{
name: 'CT',
data: [5, 3, 4, 7, 2, 8, 5, 3, 4, 7, 2, 8, 5, 3, 4],
stack: 'Study'
}, {
name: 'IR',
data: [3, 4, 4, 2, 5, 9, 2, 5, 9, 7, 2, 8, 5, 3, 4],
stack: 'Study'
}, {
name: 'MR',
data: [2, 5, 6, 2, 1, 10, 6, 2, 1, 7, 2, 8, 5, 3, 4],
stack: 'Study'
}, {
name: 'US',
data: [3, 0, 4, 4, 3, 11, 3, 5, 6, 7, 2, 8, 5, 3, 4],
stack: 'Study'
}]
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment