如何在各个数据点之间添加行? [英] How to add lines between individual data points?

查看:83
本文介绍了如何在各个数据点之间添加行?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Highcharts中创建散点图,只将两个点连接到对方,但不连接到任何其他点。 (显示数据点随时间的变化)。



这里我说明了我的问题。我希望有一个点之间的界限



[20,20] 和<$ c
$ b

和一个单独的连接线

[60,40] to [85,60]



但没有连线

$ [80,80] [60,40 ]



有没有一个可以轻松配置的方法来做到这一点,还是我必须手动渲染每一行?

解决方案

您可以在这些点之间简单地添加 null

  data:[[20,20],[80,80],null,[60,40],[85,60]] 

演示


I'm trying to make a scatter plot in Highcharts that only connects two individual points to each other, but doesn't connect to any other points. (To show the change in a data point over time).

Here I illustrate my question. I'd like for there to be a line between the points

[20, 20] and [80, 80]

and a separate line connecting

[60, 40] to [85, 60]

but no line connecting

[80, 80] to [60, 40]

Is there an easily configurable way to do this, or do I have to manually render each line?

解决方案

You can simple add null between these points.

data: [[20, 20], [80, 80], null, [60, 40], [85, 60]]

Demo

这篇关于如何在各个数据点之间添加行?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆