作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在尝试更改 Highcharts 中折线图的 dashStyle。
我提到了 RDocumentation ,第 7 页,任何地方都没有它的例子。它所说的就是使用 dash_styles()
然后我检查了here并尝试过,但没有得到我需要的结果。
library(highcharter)
highchart() %>%
hc_title(text = title) %>%
hc_xAxis(categories = batchno) %>%
hc_add_series(name = "Mixer A", data = A,
color = "hotpink", pointWidth = 20, type = "line",
dash_styles(style = "LongDot")) %>%
hc_add_series(name = "Mixer B" , data = B,
color = "slateblue", pointWidth = 20,type = "line") %>%
hc_chart(type = "column") %>%
hc_yAxis(
list(lineWidth = 3, lineColor='seashell', title=list(text= "text"),max= 10)) %>% hc_tooltip(crosshairs = TRUE, shared = TRUE)
}
我如何使用这个 dash_style ?
最佳答案
dash_styles
只是一个辅助函数,显示您可以使用的破折号类型。
检查 this example .你会看到你只需要给出破折号类型的名称:
highchart() %>%
hc_add_series(data = rnorm(5), dashStyle = "longdash") %>%
hc_add_series(data = rnorm(5), dashStyle = "DashDot")
关于r - Highcharts 中的 dash_styles,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47136518/
我正在尝试更改 Highcharts 中折线图的 dashStyle。 我提到了 RDocumentation ,第 7 页,任何地方都没有它的例子。它所说的就是使用 dash_styles() 然后
我是一名优秀的程序员,十分优秀!