Unable to install a package package in R

三世轮回 提交于 2020-04-07 08:25:09

问题


I am using rstudio with an r version 3.6.2. I already referred this post in forum but doesn't seem to help. The package can be found here

I am trying to install aphrodite package but unfortunately it throws error as shown below. I get either of the below 2 errors

Error: Failed to install 'Aphrodite' from GitHub: (converted from warning) unable to access index for repository https://OHDSI.github.io/drat/bin/windows/contrib/3.6: cannot open URL 'https://OHDSI.github.io/drat/bin/windows/contrib/3.6/PACKAGES'

Error: Failed to install 'Aphrodite' from GitHub: (converted from warning) installation of package ‘C:/Users/test/AppData/Local/Temp/RtmpEzlckw/file29a84d6a1a43/Aphrodite_2.0.tar.gz’ had non-zero exit status

Can someone help me resolve this error? I am not a tech person but any help to resolve this will be very useful


回答1:


So the issue turned out to be the "error converted to warning" scenario, as described here

Setting Sys.setenv(R_REMOTES_NO_ERRORS_FROM_WARNINGS="true") before the install command solves the issue.



来源:https://stackoverflow.com/questions/60785166/unable-to-install-a-package-package-in-r

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!