Reputation: 11
I'm having problem with Caret package, Please see the error below,
library(caret)
Error: package or namespace load failed for ‘caret’ in dyn.load(file, DLLpath = DLLpath, ...): unable to load shared object '/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/libs/Rcpp.so': dlopen(/Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/libs/Rcpp.so, 6): Symbol not found: _EXTPTR_PTR Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/libs/Rcpp.so Expected in: /Library/Frameworks/R.framework/Resources/lib/libR.dylib in /Library/Frameworks/R.framework/Versions/4.0/Resources/library/Rcpp/libs/Rcpp.so In addition: Warning message: package ‘caret’ was built under R version 4.0.2
I am using macOS Catalina.
Thanks in advance, Daniel
Upvotes: 0
Views: 501
Reputation: 26
I had a similar issue when moving from 4.0 to 4.1 and reinstalling ggplot2
Basically when loading vctrs
it was using the libR.dylib
from the R.Framework 4.0 not the 4.1 (and I removed the 4.0)
>library(ggplot2)
Error: package or namespace load failed for ‘ggplot2’ in
dyn.load(file, DLLpath = DLLpath, ...): unable to load shared
object '/Users/xxxx/Library/R/4.1/library/vctrs/libs/vctrs.so':
dlopen(/Users/xxxx/Library/R/4.1/library/vctrs/libs/vctrs.so, 6):
Library not loaded:
/Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libR.dylib
Referenced from: /Users/lgzdl/Library/R/4.1/library/vctrs/libs/vctrs.so
Reason: image not found
My temporary solution has been to duplicate the 4.1 and renamed it 4.0. At, least for now > library(vctrs)
is not throwing an error!
There must be a lingering reference to the R.Framework 4.0? somewhere?
Upvotes: 0
Reputation: 21
I resolve this problem with latest release R-4.0.2.pkg in www.r-project.org -> Download -> CRAN and select your country.
Upvotes: -1