hc_yaxis_multiple 用于 add_series_list
我想在 highchart 中有多个 y 轴,但出于某种原因第二个轴只显示名称而不显示值,下面是一个示例,
ds <- lapply(seq(1), function(x) {
list(data = cumsum(rnorm(100, 2, 5)), name = "1")
})
da <- lapply(seq(1), function(x) {
list(data = cumsum(rnorm(100, 2, 5)), name = "2")
})
highchart() %>%
hc_plotOptions(series = list(marker = list(enabled = FALSE))) %>%
hc_yAxis_multiples(list(title = list(text = "Retention"), opposite = FALSE),
list(showLastLabel = TRUE, opposite = TRUE, title = list(text = "Limit")))%>%
hc_add_series_list(ds)%>%
hc_add_series_list(da)
谢谢
i want to have multiple y axis in highchart, but for any reason the second axis only display the name but not values, below here is an example,
ds <- lapply(seq(1), function(x) {
list(data = cumsum(rnorm(100, 2, 5)), name = "1")
})
da <- lapply(seq(1), function(x) {
list(data = cumsum(rnorm(100, 2, 5)), name = "2")
})
highchart() %>%
hc_plotOptions(series = list(marker = list(enabled = FALSE))) %>%
hc_yAxis_multiples(list(title = list(text = "Retention"), opposite = FALSE),
list(showLastLabel = TRUE, opposite = TRUE, title = list(text = "Limit")))%>%
hc_add_series_list(ds)%>%
hc_add_series_list(da)
Thank you
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您必须通过为一个(且仅针对一个)系列设置
yAxis
参数来指定要在主 y 轴上显示哪个系列:You have to specify which of the series you want to display on the primary y-axis by setting the
yAxis
argument for one (and only for one) series: