我正在尝试在R中进行多重修复,并且已经安装了Amelia并尝试打开AmeliaView,但它显示需要tcltk包。我继续安装tcltk,但错误消息弹出如下。有人能帮帮我吗?
> AmeliaView()
Loading required package: tcltk
Loading Tcl/Tk interface ... Error : .onLoad failed in loadNamespace() for 'tcltk', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so':
dlopen(/Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so, 10): Library not loaded: /usr/local/lib/libtcl8.5.dylib
Referenced from: /Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so
Reason: image not found
Error in AmeliaView() : The package 'tcltk' is required
> require(tcltk2)
Loading required package: tcltk2
Loading required package: tcltk
Loading Tcl/Tk interface ... Error : .onLoad failed in loadNamespace() for 'tcltk', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so':
dlopen(/Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so, 10): Library not loaded: /usr/local/lib/libtcl8.5.dylib
Referenced from: /Library/Frameworks/R.framework/Versions/2.12/Resources/library/tcltk/libs/i386/tcltk.so
Reason: image not found
Failed with error: ‘package 'tcltk' could not be loaded’
发布于 2013-06-05 00:34:04
这对于那些在Linux上有相同问题的人可能很有用(长时间的讨论,跳到最后以获得最终的解决方案):
http://r.789695.n4.nabble.com/Where-is-the-tcltk-package-td3434915.html
发布于 2014-06-13 21:38:41
如果您的R版本大于3.0,那么Tck/Tk 8.6.0将与其捆绑在一起。你应该可以删除它
https://stackoverflow.com/questions/5567500
复制相似问题