Javascript examples for highcharts:Bar Chart
Dynamic enable/disable scrollbar for range selector
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-3.0.0.js"></script> <script type="text/javascript"> window.onload=function(){/*w ww .j a v a 2 s.c o m*/ $(function() { $('#container').highcharts('StockChart', { chart: { type: 'line' }, series: [{ name: 'pierwsza', data: [1, 2, 3, 4, 5, 6] }] }); $('#btn1').bind('click', function() { var chart = $('#container').highcharts(); chart.addSeries({ name: 'second', data: [6, 7, 8, 9] }); }); $('#btn2').bind('click', function() { var chart = $('#container').highcharts(); chart.series[0].update({ pointStart: 6, data: [5, 1, 6, 0, 12, 3] }, true); }); $('#btn3').bind('click', function() { var chart = $('#container').highcharts(); chart.series[0].addPoint(10); }); }); } </script> </head> <body> <script src="https://code.highcharts.com/stock/highstock.js"></script> <div id="container"></div> <button id="btn1">Add Series</button> <button id="btn2">Udate Series</button> <button id="btn3">Add Point</button> </body> </html>