简体   繁体   English

R包列在CRAN上但不在可用包中

[英]R package listed on CRAN but not in available package

I want to install a package that is listed in https://cran.r-project.org/web/packages/available_packages_by_name.html as available in CRAN, but when I check in R the install packages menu or the available.packages() command, I can't see the package there. 我想在CRAN中安装https://cran.r-project.org/web/packages/available_packages_by_name.html中列出的软件包,但是当我在R中检查安装软件包菜单或available.packages( )命令,我看不到那里的包。

Do I need to do something different to install those packages? 我是否需要做一些不同的安装这些包? Why aren't those packages available? 为什么不提供这些包裹?

The packages I'm interested on are WikipediR ( https://cran.r-project.org/web/packages/WikipediR/index.html ), WikidataR and WikipediaR. 我感兴趣的软件包是WikipediR( https://cran.r-project.org/web/packages/WikipediR/index.html ),WikidataR和WikipediaR。

If it matters, I'm using R 2.15.0 in Windows XP. 如果重要,我在Windows XP中使用R 2.15.0。

See the documentation for ?available.packages ... 请参阅?available.packages文档...

By default, the return value includes only packages whose version and OS requirements are met by the running version of R, and only gives information on the latest versions of packages. 默认情况下,返回值仅包括运行版本的R满足其版本和操作系统要求的软件包,并且仅提供有关软件包的最新版本的信息。

In other words... your R 2.15 is likely too old for the package you are looking to download. 换句话说......你的R 2.15对于你想要下载的软件包来说可能太旧了。

您可以尝试下载软件包源手动将软件包添加到通常位于“win-library / 2.15 /”之类的软件包库中,但是像Cory所说的那样,旧版本的R可能不支持软件包构建。

The advice given so far is a bit incomplete although I do agree you need to update your R version if you want to use these packages. 到目前为止给出的建议有点不完整,但我同意如果你想使用这些软件包,你需要更新你的R版本。 Looks like they don't need compilation so you might have been able to either install from a local copy or drop R code in, but critically they depend on httr which requires R 3.0.0 or above. 看起来他们不需要编译,因此您可以从本地副本安装或删除R代码,但关键是他们依赖于需要R 3.0.0或更高版本的httr They were released only relatively recently, so there will be no Windows binaries from back in 2012. (Your copy of R is from 30-Mar-2012.) Look in the DESCRIPTION file which is presented in a nice web format at the CRAN/package listing: 它们仅在最近才发布,因此2012年将不会出现Windows二进制文件。(您的R副本是2012年3月30日。)查看描述文件,该文件以漂亮的Web格式显示在CRAN /包装清单:

https://cran.r-project.org/web/packages/WikidataR/index.html
    Imports:    httr, jsonlite, WikipediR
   Suggests:    testthat, knitr, pageviews

# only one version of these two
https://cran.r-project.org/src/contrib/Archive/WikidataR/WikidataR_1.0.0.tar.gz
https://cran.r-project.org/src/contrib/Archive/WikipediaR/WikipediaR_1.0.tar.gz
# pick one of these
https://cran.r-project.org/src/contrib/Archive/WikipediR/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM