我想更改垂直轴的 colored颜色 ,如图col.axis=4
所示
par(bg = 1, fg = 2, col.axis=4)
plot(rnorm(10),t="b", col=8)
但我不能做同样的chart_Series()
功能从quantmod
包.
从图中可以看出,只有横轴改变了 colored颜色 ,而纵轴没有改变.
library(quantmod)
p1 <- rnorm(8000) |> cumsum() |> xts(Sys.time()+1:8000) |> to.minutes(name = NULL) |> round(0)+100
par(bg = 1, fg = 2, col.axis=4)
th <- chart_theme()
th$col$dn.col <- "darkred"
th$col$up.col <- "darkgreen"
th$col$grid=NA
th$col$grid2=8
th$col$dn.border="#454545"
th$col$up.border="#454545"
chart_Series(p1, theme = th)