R、车包无法加载 [英] R, car package unable to load

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

问题描述

我是 R 新手,在加载汽车库时遇到了一些问题.我使用 Windows 8.1(64 位)并且我在 32 位 R 环境中工作.我很好地下载了库,但是当我尝试使用 library(car) 加载 car 库时,我得到的消息是:

I'm new with R, and I'm having some trouble loading the car library. I use Windows 8.1 (64 bit) and i'm working in 32 bit R environment. I downloaded the library just fine, but when i try to load the car library using library(car) the message i get is:

加载命名空间中的错误(j <- i[[1L]], c(lib.loc, .libPaths()),版本检查 = vI[[j]]) :
没有名为quantreg"的包
错误:汽车"的包或命名空间加载失败

Error in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]) :
there is no package called ‘quantreg’
Error: package or namespace load failed for ‘car’

出现此消息要求除了 quantreg 之外的其他几个库.我下载了一些其他的库,希望它足以运行汽车,但它并没有停止要求更多的库.

This message came up asking for several other libraries besides quantreg. I downloaded some of those other libraries in the hope that it would be enough to run car, but it doesn't stop asking for more libraries.

有人遇到过同样的问题吗?这也发生在我认识的一些人身上,他们使用不同的操作系统,主要是 Windows,但也有 Linux.

Has anyone had the same issue? This also happened to some people I know, using different operating systems, mostly Windows, but also Linux.

推荐答案

好像你安装car的时候没有自动安装依赖.我假设您尝试使用 Rstudio 进行安装,它不会自动安装依赖项.

It seems that you did not install the dependencies automatically when you installed car. I'm assuming that you tried installing with Rstudio, which does not automatically install dependencies.

这篇SO帖子这个应该可以帮助您自动安装它们.

This SO post and this one should help you to install them automatically.

尝试使用命令 install.packages("car",dependencies=TRUE) 重新安装.

Try reinstalling with the command install.packages("car",dependencies=TRUE).

此外,将来您可以查看 CRAN 页面 查看依赖、导入、建议等.

Additionally, in the future you can check the CRAN page to see the depends, imports, suggests, etc.

这篇关于R、车包无法加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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