在R openair中使用timePlot时,我似乎无法从图形底部移动图例。有人能帮上忙吗?
以下是我的脚本和一些数据:
library(openair)
timeozone <- import(npsfiles[2], date="year", date.format = "%Y", header=TRUE, na.strings="NA")
timePlot(timeozone, pollutant = c("BIBEKB", "MACAGO", "MACAHM", "VOYASB"), group = TRUE, ylab = "Ozone (ppbv)", key.columns = 1)数据:
Year BIBEKB
1990 70.25
1991 59.25
1992 62.5
1993 64.25
1994 76
1995 68.25
1996 78.375
1997 66.25我试过了:
auto.key = list(space = "right")
space = "right"
key.position = "right"我还尝试将图例规范放在timePlot代码行之外,但我希望能够让它与timePlot函数中的位置规范一起工作。感谢您能提供的任何帮助:
plot.new()
legend(1, -1, c("BIBEKB","MACAGO","MACAHM", "VOYASB"))发布于 2016-09-02 15:59:39
我看到在openair timePlot的github库中添加了"key.position =“函数选项
但它是开发人员版本。因此您可以尝试手动安装它。也许它会对你有所帮助!
https://stackoverflow.com/questions/39236622
复制相似问题