Dygraph输出在相邻数据点之间断开连接

时间:2016-01-22 16:23:53

标签: r shiny dygraphs

我在Shiny App中绘制了一个Dygraph输出,并且我的图表中有一些部分没有连接数据点之间的点。有谁知道为什么Dygraph中某个时间步之间的某些段会断开连接?

谢谢!

enter image description here

1 个答案:

答案 0 :(得分:0)

我通过使用Dygraphs的connectSeparatedPoints选项解决了这个问题。例如,这是我用来显示我的dygraph的代码:

dygraph(component, main = "Temperature Rise Data Plot") %>%
      dyAxis("y", label = "Temp (F)") %>%
      dyAxis("x", label = "Time (min)")%>%
      dyRangeSelector() %>%
      dyOptions(colors = RColorBrewer::brewer.pal(8, "Dark2"), connectSeparatedPoints = TRUE)