2017-08-25 248 views
0

我想部署一個應用程序,我在Rshiny中做了幾天,但沒有成功......本地它的工作很漂亮......只有問題出現在我嘗試發佈到Shinyapps.io帳戶.....無法在shinyapps.io中部署閃亮的應用程序

我裝包在全球範圍(在apps.r腳本)爲:

加載所需的軟件包

mLoad <- function(...) { 
    sapply(sapply(match.call(), as.character)[-1], require, character.only = TRUE) 
} 

mLoad(cluster,plyr,dplyr,DT,data.table,ggfortify,ggcorrplot,ggraph,ggplot2,ggthemes,imputeTS,knitr,markdown,purrr,randomForest,rCharts,reshape2,rpivotTable,rsconnect,shiny,shinythemes,shinyapps,tibble,tidyr,tidyverse,vegan,VIM,visdat) 

我收到以下錯誤,同時部署.....

An error has occurred 

The application failed to start. 

Loading required package: cluster 
Loading required package: plyr 
Loading required package: dplyr 

Attaching package: ‘dplyr’ 

The following objects are masked from ‘package:plyr’: 

    arrange, count, desc, failwith, id, mutate, rename, summarise, 
    summarize 

The following objects are masked from ‘package:stats’: 

    filter, lag 

The following objects are masked from ‘package:base’: 

    intersect, setdiff, setequal, union 

Loading required package: DT 

Attaching package: ‘DT’ 

The following objects are masked from ‘package:shiny’: 

    dataTableOutput, renderDataTable 

Loading required package: data.table 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘data.table’ 
Loading required package: ggfortify 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘ggfortify’ 
Loading required package: ggcorrplot 
Loading required package: ggplot2 
Loading required package: ggraph 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘ggraph’ 
Loading required package: ggthemes 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘ggthemes’ 
Loading required package: imputeTS 
Loading required package: knitr 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘knitr’ 
Loading required package: markdown 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘markdown’ 
Loading required package: purrr 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘purrr’ 
Loading required package: randomForest 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘randomForest’ 
Loading required package: rCharts 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘rCharts’ 
Loading required package: reshape2 
Loading required package: rpivotTable 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘rpivotTable’ 
Loading required package: rsconnect 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘rsconnect’ 
Loading required package: shinythemes 
Loading required package: shinyapps 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘shinyapps’ 
Loading required package: tibble 
Loading required package: tidyr 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘tidyr’ 
Loading required package: tidyverse 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘tidyverse’ 
Loading required package: vegan 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘vegan’ 
Loading required package: VIM 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘VIM’ 
Loading required package: visdat 
Warning in library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, : 
    there is no package called ‘visdat’ 
Error in value[[3L]](cond) : could not find function "rpivotTableOutput" 
Calls: local ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous> 
Execution halted.. 

據我知道所有需要的包已經被無論是從CRAN或Github的本地安裝.....仍然不知道爲什麼我收到上述錯誤....

好像有衝突的地方有的包間....找不出哪裏....

回答

2

解決了閃亮的部署問題......剛剛將庫名的rpivotTableOutput("mypivot") UI部分,如下圖所示.. 。

rpivotTable::rpivotTableOutput("mypivot") ..

Infact即使在部署之後,許多功能無法正常工作(本地應用程序無縫工作)....對於exp ...甚至在加載dplyr庫後重命名dplyr()...只需將庫名稱前面的功能.... dplyr::rename() .....必須做的應用程序的許多功能...在server以及ui部分的閃亮代碼....

Plz see my閃亮的應用程序在這裏:

https://nishantsbi.shinyapps.io/microsegmentation_ml_app/ 
相關問題