我正在尝试在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’
答案 0 :(得分:2)
这可能对那些在Linux上遇到相同问题的人有用(长时间的讨论,跳到最后才能获得最终解决方案):
http://r.789695.n4.nabble.com/Where-is-the-tcltk-package-td3434915.html
答案 1 :(得分:0)
如果您的R版本> 3.0然后Tck / Tk 8.6.0与它捆绑在一起。你应该可以删除它