Unable to load any package in R (unable to load shared object)

 ̄綄美尐妖づ 提交于 2019-11-28 08:56:51

问题


I have been using R for the last 2 years. I tried to start the program yesterday to run one of my scripts and the packages that I am using failed to load. I am not sure what happened as it was working fine earlier. I tried to uninstall and re-install the software but it wasn't of any help. Here's the error I get when I require()/library() a package (for example ggplot2):

>require(ggplot2)
Loading required package: ggplot2
Error in inDL(x, as.logical(local), as.logical(now), ...) : 
  unable to load shared object '//mypath/myuser/data/Documents/R/win-library/3.2/digest/libs/x64/digest.dll':
  LoadLibrary failure:  Access is denied.

>library(ggplot2)
Error in inDL(x, as.logical(local), as.logical(now), ...) : 
      unable to load shared object '//mypath/myuser/data/Documents/R/win-library/3.2/digest/libs/x64/digest.dll':
      LoadLibrary failure:  Access is denied.

I have found many people asking the same question on different websites, but their main problem was with a specific package. I am having this trouble with all packages. Any ideas how I can solve this problem? Much appreciated.


回答1:


As BondedDust has explained in the comments, the problem has to do with the permissions that are given to users. I am connected to a network where the libraries are saved on a shared space. The issue was resolved by moving the default library to a local path. The process that needs to be followed to change the library to a local one is quite simple and it is mentioned in the second answer in this question on stackoverflow.



来源:https://stackoverflow.com/questions/30034542/unable-to-load-any-package-in-r-unable-to-load-shared-object

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