加载plyr软件包时出现问题 [英] Problem loading the plyr package

查看:298
本文介绍了加载plyr软件包时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用R 2.13.1,但尝试在R中加载"plyr 1.6"软件包失败.我已将其手动安装到目录〜/R/library"中. 我的代码是:

I use R 2.13.1 and have unsuccessfully tried to load the package "plyr 1.6" in R. I have manually installed it into a directory "~/R/library". My code is:

.libPaths("~/R/library")
 library(plyr)

我收到消息:

库(plyr)中的错误:'plyr'不是有效的已安装软件包

Error in library(plyr) : 'plyr' is not a valid installed package

它可以与其他软件包("chron","zoo","ismev","Lmoments")配合使用,但不适用于"plyr"软件包,我不知道会发生什么.我尝试安装和加载"plyr"的早期版本,但结果相同.

It works fine with other packages ("chron", "zoo", "ismev", "Lmoments"), but not for the "plyr" package, and I have no idea what is goin on. I have tried installing and loading earlier versions of "plyr", but with the same result.

自从卡住以来,我非常感谢您的帮助! 问候 西塞(Sisse)

I appreciate any help a lot since I am stuck! Regards Sisse

推荐答案

这不是手动安装plyr的答案.这是有关为什么必须首先手动安装的更多答案.

This isn't an answer to manually installing plyr. This is more answer about why you have to manually install in the first place.

我怀疑您的CRAN镜像设置不正确.要检查,请输入

I suspect your CRAN mirror is improperly set. To check, type

options("repos")[[1]][1]

这应该返回如下内容:

> options("repos")[[1]][1]
                                    CRAN 
"http://streaming.stat.iastate.edu/CRAN" 
> 

尝试将您的存储库设置为其他镜像,如下所示:

try setting your repo to a different mirror like this:

options(repos="http://streaming.stat.iastate.edu/CRAN")

或使用任何其他您选择的镜像.

然后尝试加载plyr:

Then try loading plyr:

install.packages("plyr")
library("plyr") 

,让我们知道会发生什么.

and let us know what happens.

这篇关于加载plyr软件包时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆