LoadLibrary失败:找不到指定的模块



如何修复它?

启动期间-

Warning message:
package ‘stats’ in options("defaultPackages") was not found 
Error in inDL(x, as.logical(local), as.logical(now), ...) : 
unable to load shared object 'C:/Program Files/R/R-4.2.1/library/stats/libs/x64/stats.dll':
LoadLibrary failure:  The specified module could not be found.
In addition: Warning message:
R graphics engine version 15 is not supported by this version of RStudio. The Plots tab will be disabled until a newer version of RStudio is installed.

这是我的错误

这是一个PATH和权限问题。我已经解决了这个缺少dll的问题如下:

  1. 将R和RStudio安装更改为我的管理员用户

  2. 在这个链接中,@kevinushey引起了我对空系统的注意("stats.dll"(,我在Windows中将以下所有路径添加到我的PATH中(但最后两个似乎有所不同(:

    • C:\Program Files\R\R-4.2.1 \bin\x64
    • C: \Program Files\R\R-4.2.1 \bin\i386
    • C: \PROGRA1\R\R-421.1\bin\x64
    • C: \Users\USER\AppData\Local\Programs\R\R-4.2.1 \library\rJava\jri
    • C: \Program Files\R\R-4.2.1 \library\stats
    • C: \Users\USER\AppData\Local\R\bin\x64
    • C: \Users\USER\AppData\Local\R\library\stats\libs\x64
  3. 本期从@lrasmus之后的以下文件夹中移出了"Rprofile.site"C: \Users\user\AppData\Local\Programs\R\R-4.2.1 \etc

我在运行R扩展时尝试在R中运行nrlx包(与R和NetLogo连接(时遇到了这个问题。我已经在R.NET问题页面上发布了这个答案。我希望这能有所帮助。

最新更新