Highcharts Demo
author(s):
Torstein Hønsi
by Gert Vaartjes
HTML
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/variwide.js"></script>
<div id="container"></div>
CSS
#container {
max-width: 800px;
min-width: 380px;
margin: 0 auto;
}
JavaScript
Highcharts.chart('container', {
chart: {
type: 'variwide'
},
title: {
text: 'Labor Costs in Europe, 2016'
},
subtitle: {
text: 'Source: <a href="http://ec.europa.eu/eurostat/web/' +
'labour-market/labour-costs/main-tables">eurostat</a>'
},
xAxis: {
type: 'category',
title: {
text: 'Column widths are proportional to GDP'
}
},
legend: {
enabled: false
},
series: [{
name: 'Labor Costs',
data: [
[50.2, 335504],
[ 42, 277339],
[ 39.2, 421611],
],
dataLabels: {
enabled: true,
format: '€{point.y:.0f}'
},
tooltip: {
pointFormat: 'Labor Costs: <b>€ {point.y}/h</b><br>' +
'GDP: <b>€ {point.z} million</b><br>'
},
colorByPoint: true
}]
});