Highcharts Demo
author(s): Torstein Hønsi
by Geo George
HTML
<script src="https://code.highcharts.com/highcharts.js"></script>
<div id="container"></div>
CSS
#container {
min-width: 310px;
max-width: 800px;
margin: 0 auto;
}
JavaScript
Highcharts.chart('container', {
chart: {
type: 'column'
},
title: {
text: 'Annual precipitation'
},
subtitle: {
text: 'Highcharts data labels with callout shape'
},
xAxis: {
categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']
},
plotOptions: {
series: {
dataLabels: {
enabled:true
}
}
},
series: [{
data: [{
y: 29.9,
dataLabels: {
enabled: true,
format: 'January<br><span style="font-size: 1.3em">Dryest</span>',
verticalAlign: 'bottom',
y: -10
}
}, {
y: 71.5
}, {
y: 106.4
}, {
y: 129.2
}, {
y: 144.0
}, {
y: 176.0
}, {
y: 135.6
}, {
y: 148.5
}, {
y: 216.4,
dataLabels: {
enabled: true,
format: 'September<br><span style="font-size: 1.3em">Wettest</span>',
align: 'right',
verticalAlign: 'middle',
x: -35
}
}, {
y: 194.1
}, {
y: 95.6
}, {
y: 54.4
}]
}]
});