HighCharts rendering chart already enlarged

Is it possible to make scalable diagrams and increase the scale. I use a scatter plot that scales along the x and y axis and would like it to be already zoomed in to certain values.

Are there any default scaling options that I can set when defining a graph?

Here is a working chart example: Chart example

$('#container').highcharts({ chart: { type: 'scatter', zoomType: 'xy' }... 
+5
source share
1 answer

The chart.zoom function is available (but not intended for this use), but usually takes quite a few parameters from the drag event. Faking it when creating a chart can be performed at least:

 $('#container').highcharts({ // ... }, function() { this.zoom({ xAxis: [{ min: 25, max: 30, axis: this.xAxis[0] }], yAxis: [{ min: 0, max: 300, axis: this.yAxis[0] }] }); }); 

See this CodePen for an example. If you make a manual selection, I registered the original input that will perform the function.

+2
source

Source: https://habr.com/ru/post/1235901/


All Articles