我在一个(只有一个)我的RStudio项目中遇到了奇怪和恼人的行为.每当我在这个项目中重新启动R会话时,我就不能再保存任何文件了,当我尝试(或RStudio尝试自动)时,我得到一个弹出错误,说"系统找不到指定的文件",我有重新打开项目和所有R脚本.
我查看了日志文件,我看到了很多以下错误:
07 Oct 2015 00:52:05 [rsession-Mark] ERROR system error 5 (Access is denied) [path=C:/Users/Mark/GoogleDrive/Research/CEQUAL_event/.Rproj.user/5E5F98D9/sdb/s-26E44539/lock_file];
OCCURRED AT: bool rstudio::core::FilePath::exists() const C:\Users\Administrator\rstudio\src\cpp\core\FilePath.cpp:308;
LOGGED FROM: bool rstudio::core::FilePath::exists() const C:\Users\Administrator\rstudio\src\cpp\core\FilePath.cpp:308
Run Code Online (Sandbox Code Playgroud)
看起来问题可能出在.Rproj.user文件夹中.所以我删除了它,让RStudio重新生成它,但行为又重新启动了.
我使用的是Windows 7,RStudio版本0.99.441和R版本3.2.2.
我有一个反应式表达式,我想从最近两个其他反应式表达式中的任何一个中取得的值.我做了以下示例:
ui.r:
shinyUI(bootstrapPage(
column(4, wellPanel(
actionButton("button", "Button"),
checkboxGroupInput("check", "Check", choices = c("a", "b", "c"))
)),
column(8,
textOutput("test")
)
))
Run Code Online (Sandbox Code Playgroud)
和server.r:
shinyServer(function(input, output) {
output$test <- renderText({
# Solution goes here
})
})
Run Code Online (Sandbox Code Playgroud)
我希望输出显示任意一个的值button(按钮被点击的次数)或 check(一个字符向量显示哪些框被选中),具体取决于最近更改的内容.