gpt4 book ai didi

r - 如何正确安装和加载dplyr?

转载 作者:行者123 更新时间:2023-12-03 08:40:28 25 4
gpt4 key购买 nike

我目前正在通过Spiro包练习R编程。而且我在其中一门类(class)的安装步骤中遇到了以下错误。

| This lesson requires the ‘dplyr’ package. Would you like me to install it for
| you now?

1: Yes
2: No

Selection: 1

| Trying to install package ‘dplyr’ now...
package ‘dplyr’ successfully unpacked and MD5 sums checked

| Could not install package ‘dplyr’!

|
| | 0%Error in seq.default(0, 1, length.out = nrow(e$les)) :
argument 'length.out' must be of length 1

| Leaving swirl now. Type swirl() to resume.

即使我尝试手动安装它并成功完成,由于以下错误我也无法加载。
> library(dplyr)
Error: package or namespace load failed for ‘dplyr’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
namespace ‘rlang’ 0.4.5 is already loaded, but >= 0.4.6 is required

我试图删除,重新安装和更新软件包。似乎没有任何作用。请帮忙

最佳答案

要么

install.packages("dplyr", dependencies = TRUE)

还是先回去做
install.pacakges("rlang")

然后安装 dplyr

欢迎来到Package Hell。这是您的类卓琴。昨晚我必须安装4个级别的软件包,然后才能加载所有 tidyverse。这很乏味但可行。

https://www.google.com/search?source=univ&tbm=isch&q=welcome+to+hell.+here%27s+your+banjo&client=firefox-b-1-e&sa=X&ved=2ahUKEwi2wMPGosnpAhWSIDQIHX7JBC0QsAR6BAgIEAE&biw=1600&bih=805#imgrc=mlE1KJg7CKY-5M

关于r - 如何正确安装和加载dplyr?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61967808/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com