R studio 无法使用 ggplot2 且没有错误消息

R studio can't use ggplot2 with no error message

我这样测试简单的代码:

g <- ggplot(mpg, aes(class))
g + geom_bar()

然后R studio显示忙碌,一直等到我从系统中关闭R studio程序。没有错误信息。 但是,它可以在 RGui 中工作。

我已经卸载并重新安装了 R and R studio。它也不起作用。 几天前,我做了 windows 更新,然后它工作了一段时间。

OS版本为Win8.1 64位。 R 和 R studio 的版本是 "R-3.3.1-win" 和 "RStudio-0.99.903"

有人知道这个问题吗?

这可能是 32 位版本的 R 3.3.x 和 RStudio 之间的不良交互。您应该可以通过以下方式解决此问题:

  1. 降级回 R 3.2.5,
  2. 切换到 64 位版本的 R,或者
  3. 正在安装 RStudio preview release