javascript - Second Y-Axis in Highcharts linked to specific data series - Stack Overflow

i have 6 series (lines) within one chart categorized by date. one of the series has a way higher max po

i have 6 series (lines) within one chart categorized by date. one of the series has a way higher max point than all the others making them disappear into a a single line at the bottom. the data is generated from different reports with series in different order but mostly with the same data mixed together with variable data. i want to add a second y-axis on the right to keep that one single series separated from all the other data but i need a way to tell highcharts to take a specific series which name i know. series.name would be always the same. is there any way to acplish that?

thanks!

i have 6 series (lines) within one chart categorized by date. one of the series has a way higher max point than all the others making them disappear into a a single line at the bottom. the data is generated from different reports with series in different order but mostly with the same data mixed together with variable data. i want to add a second y-axis on the right to keep that one single series separated from all the other data but i need a way to tell highcharts to take a specific series which name i know. series.name would be always the same. is there any way to acplish that?

thanks!

Share Improve this question asked Oct 12, 2011 at 18:11 TobiTobi 2,8285 gold badges30 silver badges46 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 6

This is how you define "y" axes -

yAxis: [{},{},{}] 
// so "yAxis" is just an array of y-axis-objects (i.e. yAxis[0], yAxis[1]...)

And you can tell Highcharts which one of these y axes you want your series be associated with as follows -

series: [{yAxis: 1}, {yAxis: 2}, {}]

So, your first series will be associated with yAxis[1], second with yAxis[2] and the third by default with yAxis[0].

Check out the API ref on yAxis and series.

You can also see the demo of dual-axes here. There you can click the "View Options" to see how the options object is configured.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744215433a4563533.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信