У меня есть версия R 3.6.3, и мне нужно установить пакет ConvergenceConcepts, но пока я безуспешно. Когда я пытаюсь установить этот пакет, R выдает мне следующее сообщение:
> install.packages("ConvergenceConcepts", binary = TRUE)
There is a binary version available but the source version is later:
binary source needs_compilation
ConvergenceConcepts 1.2.1 1.2.2 FALSE
installing the source package ‘ConvergenceConcepts’
trying URL 'https://cran.rstudio.com/src/contrib/ConvergenceConcepts_1.2.2.tar.gz'
Content type 'application/x-gzip' length 14123 bytes (13 KB)
==================================================
downloaded 13 KB
* installing *source* package ‘ConvergenceConcepts’ ...
** package ‘ConvergenceConcepts’ successfully unpacked and MD5 sums checked
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
xcrun: error: active developer path ("/Library/Developer/CommandLineTools") does not exist
Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools.
See `man xcode-select` for more details.
Error: package or namespace load failed for ‘tcltk’:
.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.6/Resources/library/tcltk/libs/tcltk.so':
dlopen(/Library/Frameworks/R.framework/Versions/3.6/Resources/library/tcltk/libs/tcltk.so, 10): Library not loaded: /opt/X11/lib/libX11.6.dylib
Referenced from: /Library/Frameworks/R.framework/Versions/3.6/Resources/library/tcltk/libs/tcltk.so
Reason: image not found
Error: package ‘tcltk’ could not be loaded
In addition: Warning message:
In system2("/usr/bin/otool", c("-L", shQuote(DSO)), stdout = TRUE) :
running command ''/usr/bin/otool' -L '/Library/Frameworks/R.framework/Resources/library/tcltk/libs//tcltk.so'' had status 1
Execution halted
ERROR: lazy loading failed for package ‘ConvergenceConcepts’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/ConvergenceConcepts’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/ConvergenceConcepts’
Warning in install.packages :
installation of package ‘ConvergenceConcepts’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/9j/7lphywsj3494xw3_41pxt_sh0000gn/T/RtmpzrNvDB/downloaded_packages’
Когда я пытаюсь добавить пакет в библиотеку, выдается еще одна ошибка:
> library(ConvergenceConcepts)
Loading required package: tcltk
xcrun: error: active developer path ("/Library/Developer/CommandLineTools") does not exist
Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools.
See `man xcode-select` for more details.
Error: package or namespace load failed for ‘tcltk’:
.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.6/Resources/library/tcltk/libs/tcltk.so':
dlopen(/Library/Frameworks/R.framework/Versions/3.6/Resources/library/tcltk/libs/tcltk.so, 10): Library not loaded: /opt/X11/lib/libX11.6.dylib
Referenced from: /Library/Frameworks/R.framework/Versions/3.6/Resources/library/tcltk/libs/tcltk.so
Reason: image not found
Error: package ‘tcltk’ could not be loaded
In addition: Warning message:
In system2("/usr/bin/otool", c("-L", shQuote(DSO)), stdout = TRUE) :
running command ''/usr/bin/otool' -L '/Library/Frameworks/R.framework/Resources/library/tcltk/libs//tcltk.so'' had status 1
Я пытался установить "tcltk" вручную, но он снова говорит, что он недоступен для R 3.6.3 (хотя также упоминается, что это базовый пакет и не должен обновляться). Я попытался отдельно установить tcltk, tkrplot и lattice, хотя Я понимаю, что они уже встроены в пакет ConvergenceConcepts. Я был успешным только с решеткой пакета. Может кто-нибудь помочь?