I'm having trouble installing the lme4
package from CRAN on Ubuntu 18.04. I'm running install.packages("lme4")
on R 3.4.4 and get the following error:
ERROR: configuration failed for package ‘nloptr’
* removing ‘/home/peter/R/x86_64-pc-linux-gnu-library/3.4/nloptr’
ERROR: dependency ‘nloptr’ is not available for package ‘lme4’
* removing ‘/home/peter/R/x86_64-pc-linux-gnu-library/3.4/lme4’
Looking more closely, I see these two error lines:
libtool: link: ERROR: no information for variable 'AR' cru .libs/libutil.a .libs/mt19937ar.o .libs/sobolseq.o .libs/timer.o .libs/stop.o .libs/redblack.o .libs/qsort_r.o .libs/rescale.o
checking for ranlib... ERROR: no information for variable 'RANLIB'
However, both ar
and ranlib
commands work on my machine. What may be the cause of the errors?
You just need to install the older version of nloptr package.
For example:
packageurl<-"https://cran.r-project.org/src/contrib/Archive/nloptr/nloptr_1.2.1.tar.gz"
install.packages(packageurl, repos=NULL, type="source")
I guess you are using R 3.X. Such error is caused by package update for supporting R 4.0.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With