Меня интересует установка пакетов pscl и robust в R Studio на моем устройстве MacOS.
Когда я пытаюсь использовать команду install.packages
для robust, я получаю следующее:
Loading required package: robust also installing the dependencies
‘pcaPP’, ‘robustbase’, ‘rrcov’
Warning in install.packages : unable to access index for repository
XXXX: cannot
open URL
'XXXX'
Packages which are only available in source form, and may need
compilation of C/C++/Fortran: ‘pcaPP’ ‘robustbase’ ‘rrcov’ ‘robust’
Do you want to attempt to install these from sources? (Yes/no/cancel)
Когда я выбираю Да, вот что я получаю:
installing the source packages ‘pcaPP’, ‘robustbase’, ‘rrcov’,
‘robust’
trying URL 'XXXX'
Content type 'application/x-gzip' length 198131 bytes (193 KB)
================================================== downloaded 193 KB
trying URL
'XXXX'
Content type 'application/x-gzip' length 2956184 bytes (2.8 MB)
================================================== downloaded 2.8 MB
trying URL 'XXXX'
Content type 'application/x-gzip' length 1020006 bytes (996 KB)
================================================== downloaded 996 KB
trying URL
'XXXX' Content
type 'application/x-gzip' length 232065 bytes (226 KB)
================================================== downloaded 226 KB
* installing *source* package ‘pcaPP’ ...
** package ‘pcaPP’ successfully unpacked and MD5 sums checked
** using staged installation
** libs xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at:
/Library/Developer/CommandLineTools/usr/bin/xcrun ERROR: compilation
failed for package ‘pcaPP’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/pcaPP’
Warning in install.packages : installation of package ‘pcaPP’ had
non-zero exit status
* installing *source* package ‘robustbase’ ...
** package ‘robustbase’ successfully unpacked and MD5 sums checked
** using staged installation
** libs xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at:
/Library/Developer/CommandLineTools/usr/bin/xcrun ERROR: compilation
failed for package ‘robustbase’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/robustbase’
Warning in install.packages : installation of package ‘robustbase’
had non-zero exit status ERROR: dependencies ‘robustbase’, ‘pcaPP’ are
not available for package ‘rrcov’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rrcov’
Warning in install.packages : installation of package ‘rrcov’ had
non-zero exit status ERROR: dependencies ‘robustbase’, ‘rrcov’ are not
available for package ‘robust’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/robust’
Warning in install.packages : installation of package ‘robust’ had
non-zero exit status
The downloaded source packages are in
‘/private/var/folders/w_/fc17blzn66v_j8xbm24vpmvm0000gn/T/RtmpR5qpwD/downloaded_packages’
Warning message: In library(package, lib.loc = lib.loc, character.only
= TRUE, logical.return = TRUE, : there is no package called ‘robust’
Когда я пытаюсь использовать команду install.packages для pscl, я получаю следующее:
Warning in install.packages : unable to access index for repository
XXXX: cannot
open URL
'XXXX'
Package which is only available in source form, and may need
compilation of C/C++/Fortran: ‘pscl’
Do you want to attempt to install these from sources? (Yes/no/cancel)
Когда я выберите Да, вот что я получаю:
installing the source package ‘pscl’
trying URL 'XXXX'
Content type 'application/x-gzip' length 3170945 bytes (3.0 MB)
================================================== downloaded 3.0 MB
* installing *source* package ‘pscl’ ...
** package ‘pscl’ successfully unpacked and MD5 sums checked
** using staged installation
** libs xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at:
/Library/Developer/CommandLineTools/usr/bin/xcrun ERROR: compilation
failed for package ‘pscl’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/pscl’
Warning in install.packages : installation of package ‘pscl’ had
non-zero exit status
The downloaded source packages are in
‘/private/var/folders/w_/fc17blzn66v_j8xbm24vpmvm0000gn/T/RtmpR5qpwD/downloaded_packages’
Мне кажется, я установил на свой компьютер последние версии R и RStudio.
Я хотел попрактиковаться в материалах с этого сайта , и для этого требуются эти 2 пакета. Но они не работают на моем компьютере.
Обратите внимание, что выше XXXX взяты из ссылок крана, которые я не могу сохранить в этом посте, потому что, если у меня более 8 ссылок, переполнение стека не позволит мне опубликовать sh этот пост.