我无法在Power BI中显示视觉效果。我正在使用R并希望进行绘图添加,以便在用户将鼠标悬停在其上时使图形中的不同值可视/交互式。
我尝试研究不同的论坛,技巧和问题。我想我做到了建议,但没有运气。
dataset <- data.frame(QTY, Turnover, FY Month, COUNTRY)
dataset <- unique(dataset)
Paste or type your script code here:
if(!require(shinyLP)){ install.packages('shinyLP', repos='http://cran.us.r-project.org' ,lib=.libPaths()) }
library("ggplot2")
library("scales")
library("plotly")
library("htmlwidgets")
euro <- dollar_format(prefix = "\u20ac", big.mark = ",")
g = ggplot(dataset, aes(COUNTRY, Turnover)) + geom_point(aes(colour = QTY)) + theme_classic() + theme(axis.text.x = element_text(angle = 45, hjust = 1)) + scale_y_continuous(labels = euro) + theme(legend.position="none")
p = ggplotly(g)
p