在R 3.4中,段错误'内存未映射'错误加载'ape'

时间:2017-07-26 20:48:49

标签: r

尝试使用R 3.4.1中的“require”或“library”函数加载包时,我收到两条不同的错误消息。由于问题已经开始,我只能加载一个包(ggplot2),而其他包(包括任何面向系统发育的包,例如ape)会导致以下错误:

*** caught segfault ***
address 0x0, cause 'memory not mapped'

Traceback:
 1: getDLLRegisteredRoutines.DLLInfo(dll, addNames = FALSE)
 2: assignNativeRoutines(dlls[[lib]], lib, env, nsInfo$nativeRoutines[[lib]])
 3: loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]])
 4: asNamespace(ns)
 5: namespaceImportFrom(ns, loadNamespace(j <- i[[1L]], c(lib.loc,     .libPaths()), versionCheck = vI[[j]]), i[[2L]], from = package)
 6: loadNamespace(package, lib.loc)
 7: doTryCatch(return(expr), name, parentenv, handler)
 8: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 9: tryCatchList(expr, classes, parentenv, handlers)
10: tryCatch({    attr(package, "LibPath") <- which.lib.loc    ns <- loadNamespace(package, lib.loc)    env <- attachNamespace(ns, pos = pos, deps)}, error = function(e) {    P <- if (!is.null(cc <- conditionCall(e)))         paste(" in", deparse(cc)[1L])    else ""    msg <- gettextf("package or namespace load failed for %s%s:\n %s",         sQuote(package), P, conditionMessage(e))    if (logical.return)         message(paste("Error:", msg), domain = NA)    else stop(msg, call. = FALSE, domain = NA)})
11: library(ape)

Possible actions:
1: abort (with core dump, if enabled)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace

[编辑:以下错误已解决,请参阅下面的第一条评论]当我尝试加载包rJava时,我收到以下错误。其他包含类似错误的包:

library(rJava)
Error: package or namespace load failed for ‘rJava’:
 .onLoad failed in loadNamespace() for 'rJava', details:
  call: dyn.load(file, DLLpath = DLLpath, ...)
  error: unable to load shared object '/Users/dummyname/R_libs/rJava/libs/rJava.so':
  dlopen(/Users/dummyname/R_libs/rJava/libs/rJava.so, 6): Library not loaded: @rpath/libjvm.dylib
  Referenced from: /Users/dummyname/R_libs/rJava/libs/rJava.so
  Reason: image not found

我已尝试卸载所有软件包,如下所示: caught segfault error in R 我也重新安装了R.重新安装软件包后会出现同样的错误。会话信息位于错误消息下方。建议?

> sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: OS X El Capitan 10.11.6

Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
[1] compiler_3.4.1

0 个答案:

没有答案