Highcharts test tool
HTML
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="height: 300px; margin-top: 2em"></div>
<button id="getcsv">Alert CSV</button>
JavaScript
var chart = new Highcharts.Chart({
chart: {
renderTo: 'container'
},
title: {
text: 'Categorized chart'
},
series: [{
data: [{name: 'd1', color: '#FF0000', x: 10, y: 100},{name: 'd2', color: '#FF0000', x: 30, y: 100}]
}]
});
$('#getcsv').click(function () {
var csv = "Series;Name;X;Y\n";
$.each(Highcharts.charts[0].series, function(i,s){
$.each(s.points, function(j,p){
csv += s.name + ";" + p.name + ";" + p.x + ";" + p.y + "\n";
});
});
alert(csv);
});