r - 试图加载 tidyverse 但我遇到了 "> library(tidyverse) 库中的错误(tidyverse):没有名为 'tidyverse' 的包"
问题描述
我跑了install.packages("tidyverse")
,安装完成了。
最后出现以下错误和警告:
Error in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open the connection
In addition: Warning messages:
1: In download.file(url, destfile, method, mode = "wb", ...) :
downloaded length 61440 != reported length 104968
2: In unzip(zipname, exdir = dest) : error 1 in extracting from zip file
3: In read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open compressed file 'rprojroot/DESCRIPTION', probable reason 'No such file or directory'
解决方案
很可能是因为您
a) 忘记了install.packages('tidyverse')
或
b) 'install.packages('tidyverse')' 失败
您可能更喜欢 {pacman} 方法
,该方法p_load()
检查是否已安装,
然后安装/加载或
仅根据需要加载
推荐阅读
- android - 检查 2 个用户是否同时打开聊天
- r - 根据序列中的序列填充 NA 和更正数据
- mysql - MySQL有没有办法选择按列分组的前N条记录
- javascript - ReactJS 和 Redux - 正确创建具有类型的连接类组件
- r - 在数字的两侧拆分字符串
- shell - 使用 certbot 和 nginx 制作站点 https 的 Shell 脚本
- android - 由于 com.android.tools.lint,gradlew bundleRelease 失败
- sql - SQL - 使用最大日期值和其他字段汇总列
- python - 复制解密的 PDF 文件
- swift - 无法在 UItableviewcell 中为我的单元格设置字体