不兼容的库版本RSiena

时间:2018-02-12 21:23:21

标签: r macos

我试图将RSiena软件包加载到R中,但不断收到此错误消息:

Error: package or namespace load failed for ‘RSiena’:
 .onLoad failed in loadNamespace() for 'tcltk', details:
  call: dyn.load(file, DLLpath = DLLpath, ...)
  error: unable to load shared object '/Library/Frameworks/R.framework/Versions/3.4/Resources/library/tcltk/libs/tcltk.so':
  dlopen(/Library/Frameworks/R.framework/Versions/3.4/Resources/library/tcltk/libs/tcltk.so, 10): Library not loaded: /opt/X11/lib/libfontconfig.1.dylib
  Referenced from: /usr/local/lib/libtk8.6.dylib
  Reason: Incompatible library version: libtk8.6.dylib requires version 11.0.0 or later, but libfontconfig.1.dylib provides version 10.0.0

我试过安装三种方法: install.packages("RSiena")install.packages("RSiena", repos="http://R-Forge.R-project.org"),直接从tgz文件(来自https://cran.r-project.org/web/packages/RSiena/index.html)安装。

前两种安装方法不会出现任何错误,并说The downloaded binary packages are in /var/folders/mk/__r_sbzn5mx88x04mrlycsg00000gq/T//RtmpbxlMY8/downloaded_packages。第三种选择会显示此消息Error in install.packages : type == "both" cannot be used with 'repos = NULL'

没有人允许我加载包。我在Mac OS X El Capitan(版本10.11.6)的RStudio版本1.1.423中使用R版本3.4.3(2017-11-30)。

我已尝试卸载并重新安装。我不确定如何解决此问题。

2 个答案:

答案 0 :(得分:1)

https://github.com/snlab-nl/rsiena的最新版本(RSiena v.1.2.26)解决了tcltk个问题,现在可以在Github上的{{3}}上找到。

答案 1 :(得分:0)

解决方案。我从xquartz.macosforge.org安装了XQuartz,现在该软件包已成功加载。