对于metricsgraphics,ggplot2中的coord_flip相当于什么?

时间:2015-02-04 22:28:53

标签: r widget shiny

我正在尝试翻转我的metricsgraphics图表(使用metricsgraphics html-widget在r中制作用于闪亮的应用程序)。

我已经能够在我的ShinyApp中成功展示它,但是真的想应用等效的

ggplot2::coord_flip() 

但是对于metricsgraphics

mjs_bar()

功能。

这是可能的吗?我还没有在MetricsGraphics.js文档中找到这样做的选项。

我的代码如下:

        barchart %>%
            mjs_plot(x=year,y=population,
                    width = 300,
                    height = 400,
                    show_rollover_text = TRUE,
                    decimals = 2) %>%
                    mjs_bar() ->

})

output$mjs2 <- renderMetricsgraphics(m2) 

相关的软件包如下:

metricsgraphics_0.6.1 htmlwidgets_0.3.2
htmltools_0.2.6

提前致谢

0 个答案:

没有答案