Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/ruby-on-rails-4/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
R shinny:googlecharts调用renderGvis()';我无法制作图表_R_Google Visualization_Shiny_Googlevis - Fatal编程技术网

R shinny:googlecharts调用renderGvis()';我无法制作图表

R shinny:googlecharts调用renderGvis()';我无法制作图表,r,google-visualization,shiny,googlevis,R,Google Visualization,Shiny,Googlevis,(更新:解决了div的高度/宽度问题;更改了问题)。 我正在做: output$mainplot <- renderGvis({gvisBubbleChart()}, chartid="foo") chartid=“foo”需要进入gvisBubbleChart()作为示例 rm(list=ls()) 图书馆(谷歌) 图书馆(闪亮) 时代感谢;我意识到了这一点并做出了改变,它现在陷入了gvisBubbleChart:说“你的数据中没有足够的列。”-这是一个谎言!!这是另一个问题,所以我接

(更新:解决了div的高度/宽度问题;更改了问题)。 我正在做:

output$mainplot <- renderGvis({gvisBubbleChart()}, chartid="foo")
chartid=“foo”
需要进入
gvisBubbleChart()
作为示例

rm(list=ls())
图书馆(谷歌)
图书馆(闪亮)

时代感谢;我意识到了这一点并做出了改变,它现在陷入了gvisBubbleChart:说“你的数据中没有足够的列。”-这是一个谎言!!这是另一个问题,所以我接受你的回答。
> sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252   
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C                          
[5] LC_TIME=English_United States.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] googleVis_0.5.7  data.table_1.9.4 shiny_0.11      

loaded via a namespace (and not attached):
 [1] chron_2.3-45    digest_0.6.7    htmltools_0.2.6 httpuv_1.3.2    mime_0.2        plyr_1.8.1     
 [7] R6_2.0.1        Rcpp_0.11.3     reshape2_1.4.1  RJSONIO_1.3-0   stringr_0.6.2   tools_3.1.2    
[13] xtable_1.7-4   
> 
rm(list = ls())
library(googleVis)
library(shiny)
times <- seq(c(ISOdate(2014,01,06)), by = "day", length.out = 100)
data1 <- round(runif(100, min = 100, max = 1000))
test <- round(runif(100, min = -10, max = 10))
my_data <- as.data.frame(cbind(as.character(times),data1,test))
colnames(my_data) <- c("time","data1","test")

ui =fluidPage(mainPanel(htmlOutput("view")))
server = function(input, output, session){
  datasetInput <- reactive({
    gvisBubbleChart(my_data,idvar="test", 
                    xvar="time", yvar="data1", chartid="foo")})
  output$view <- renderGvis({datasetInput()})
}
runApp(list(ui = ui, server = server))