【问题标题】:cannot install packages from github - uninterpretable error message无法从 github 安装软件包 - 无法解释的错误消息
【发布时间】:2018-11-05 23:26:32
【问题描述】:

我无法从 Github 安装任何 R 包,尽管我之前已经这样做了好几次。我在 R 版本 3.5.0 和 3.5.1 上都试过了。

尝试使用以下方式安装“https://github.com/rstudio/bookdown/bookdown-master.zip”:

devtools::install_github('rstudio/bookdown')
githubinstall::githubinstall("bookdown")

或下载并尝试在本地加载...

install_local("/Users/Brian/Documents/bookdown-master.zip")

总是给我错误信息

Error in readLines(f) : 
(converted from warning) incomplete final line found on '/Users/Brian/.Rprofile'

我也尝试了其他解决方法,但似乎所有的道路都会导致此错误消息,我找不到任何可以告诉我它与什么相关的东西。

有什么想法吗?

【问题讨论】:

  • 听起来您的 Rprofile 文件中的某些内容格式不正确。 Here's 另一个问题,虽然是一个封闭的问题,但有一些链接可能会有所帮助
  • 谢谢卡米尔。我没主意了。该信息帮助我解决了我的问题。我没有意识到 .Rprofile 是我可以编辑的东西 - 但显然我以前做过。

标签: r github


【解决方案1】:

该错误是我在使用 blogdown 包创建网站时对 .Rprofile 进行的先前编辑的结果。我不记得这样做了,但显然它干扰了包下载。

运行file.edit(".Rprofile")后,删除其中包含的单行,然后重新启动R,包再次安装。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2017-09-18
    • 1970-01-01
    • 1970-01-01
    • 2020-03-07
    • 1970-01-01
    • 2012-06-16
    • 2022-01-08
    • 2021-08-09
    相关资源
    最近更新 更多