0
看起来plotly
将ggplot2
图形中的NA值转换为空标签。这是一个简单的例子。R - 使用空标签将ggplot2图形中的NA标签转换为图形
library(ggplot2)
library(plotly)
col1 <- c("a","c","b","c",NA,"a","b","b",NA,NA)
df <- data.frame(col1)
MyPlot <- ggplot(data = df, aes(x = df$col1)) +
geom_bar(stat = "count")
print(MyPlot)
ggplotly(MyPlot)
是否有覆盖这种行为并保持NA标签的功能?也许plotly_bluid
函数允许更改剧情?