为什么我的应用程序没有在shinyapps.io上部署?

时间:2015-03-04 03:51:00

标签: r shiny rstudio

我按照shinyapps.io中显示的相同命令上传了我的应用,但收到以下错误:

> library(shinyapps)
> shinyapps::deployApp("/Users/mona/CS764/demo")
Error in lint(appDir) : Cancelling deployment: invalid project layout.
The project should have one of the following layouts:
1. 'shiny.R' and 'ui.R' in the application base directory,
2. 'shiny.R' and 'www/index.html' in the application base directory,
3. An R Markdown (.Rmd) document.

这是我文件的结构: enter image description here

1 个答案:

答案 0 :(得分:4)

使用deployApp()时,如果使用自定义用户界面,则必须部署包含ui.Rserver.R文件的目录(或shiny.R / www/index.html)。这些文件不能是子目录。

此外,重要的是要注意目录或任何子目录中的任何R文件都将被解析,因此重要的是它们具有有效的语法。

相关问题