I ran into this problem that the rCharts chart will not display in my shiny application. I found this example that fits my needs perfectly. Despite the fact that this diagram works fine, but simply draws in R, in brilliant it is a blank page.
I'm not sure what's wrong with him. Firstly, I'm not sure that I am choosing the right library in showOuput() , but I have not found a better solution.
I am trying to build this more complex application, however, I am reproducing my simple application code below the server:
server.R library(rCharts) library(reshape2) options(RCHART_WIDTH = 1700) meansconferences <-read.csv("https://raw.github.com/patilv/ESPNBball/master/meansconferences.csv") shinyServer(function(input, output) { output$test <- renderChart({ meltmeansconferences=melt(meansconferences[-c(1,10:14)], id.vars=c("Conference","Year")) d1=dPlot(y="Year", x="value",data=meltmeansconferences, groups="variable",type="bar") d1$yAxis(type="addCategoryAxis", orderRule="Year") d1$xAxis(type="addPctAxis") return(d1) }) } )
And ui:
ui.R options(RCHART_LIB = 'dimple') shinyUI(pageWithSidebar( headerPanel("rCharts and shiny"), sidebarPanel(), mainPanel( h4("Graph here"), showOutput("test","dimple") ) ))
EDITED: I am using R version 3.0.2 and rCharts 0.4.2 shiny 0.8.0.99
If you have any ideas, just let me know. Thank you in advance!
adomasb
source share