简体   繁体   English

Highcharts同步具有不同大小的多个图表

[英]Highcharts Synchronisation of multiple charts with different sizes

this example: Synchronisation of multiple charts 此示例: 多个图表的同步

use the chartx and charty position of the mouse to detect which data point is hovered. 使用鼠标的chartx和charty位置检测鼠标悬停在哪个数据点上。 But if u want to sync charts with different sizes... of course it stops working. 但是,如果您想同步不同大小的图表...当然会停止工作。

the charts are timeseries with the same data length. 图表是具有相同数据长度的时间序列。 Is there a way to synchronise relative? 有没有办法同步相对?

Greetings mok 问候莫

It's not working as you expecting, because it's not taking current xAxis focused value, but actually the pointer position. 它没有按您预期的那样工作,因为它没有采用当前的xAxis 焦点值,而是实际的指针位置。 However, I found the example on our Highcharts forum, which shows how to draw the crosshair on all charts, basing on current xAxis position instead of pointer one, so it should help you to solve your problem. 但是,我在Highcharts论坛上找到了该示例,该示例显示了如何基于当前xAxis位置而不是指针1在所有图表上绘制十字准线,因此它应该可以帮助您解决问题。

Please refer to this topic: https://forum.highcharts.com/highcharts-usage/synchronize-line-chart-with-xrange-chart-t39781/?hilit=synchronization&sid=72b63bab7545ef4ba2c4a102ef52cfa5 请参考此主题: https : //forum.highcharts.com/highcharts-usage/synchronize-line-chart-with-xrange-chart-t39781/?hilit=synchronization&sid=72b63bab7545ef4ba2c4a102ef52cfa5

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM