In this question How to install.packages of R 4.2.0?, when I try the code in R
install.packages("devtools")
library("devtools")
install_github("sangwon-hyun/omd", subdir = "omd")
I have tried install goal as the comment on R
install.packages(c('rasterVis', 'rgdal', 'raster', 'sp', 'sf', 'gstat'))
But it still shows that
ERROR: lazy loading failed for package ‘omd’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2/Resources/library/omd’
Warning message:
In i.p(...) :
installation of package ‘/var/folders/4v/wwrgppgn1s5dqn1mfv457mqm0000gn/T//RtmpJAqJio/fileafc37eeacc4a/omd_0.0.0.9000.tar.gz’ had non-zero exit status
Related
When I try to install ggplot with this code
install.packages("png")
install.packages("RgoogleMaps")
install.packages("ggmap")
library(ggmap)
It returns error
installing to /usr/local/Cellar/r/4.2.2/lib/R/library/00LOCK-png/00new/png/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘png’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/usr/local/Cellar/r/4.2.2/lib/R/library/00LOCK-png/00new/png/libs/png.so':
dlopen(/usr/local/Cellar/r/4.2.2/lib/R/library/00LOCK-png/00new/png/libs/png.so, 6): Library not loaded: #rpath/libz.1.dylib
Referenced from: /usr/local/Cellar/r/4.2.2/lib/R/library/00LOCK-png/00new/png/libs/png.so
Reason: image not found
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/usr/local/Cellar/r/4.2.2/lib/R/library/png’
Warning in install.packages :
installation of package ‘png’ had non-zero exit status
ERROR: dependency ‘png’ is not available for package ‘RgoogleMaps’
* removing ‘/usr/local/Cellar/r/4.2.2/lib/R/library/RgoogleMaps’
Warning in install.packages :
installation of package ‘RgoogleMaps’ had non-zero exit status
ERROR: dependencies ‘RgoogleMaps’, ‘png’ are not available for package ‘ggmap’
* removing ‘/usr/local/Cellar/r/4.2.2/lib/R/library/ggmap’
Warning in install.packages :
installation of package ‘ggmap’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/fd/7vyffy191_l3j6fhyqbvsn0r0000gn/T/RtmptKSXHF/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Error in library(ggmap) : there is no package called ‘ggmap’
I am installing all the dependencies that the error says are missing. By adding the install packages before installing the ggmap itself.
I keep getting an error message when trying to download sjPlot (removed part of mu directory)
ERROR: lazy loading failed for package ‘sjPlot’
* removing ‘/Users/Library/R/4.0/library/sjPlot’
Warning in install.packages :
installation of package ‘sjPlot’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/t7/__d172j90w1gp2cdfnyz8j180000gn/T/RtmpcHqFgR/downloaded_packages’
This is what I did:
install.packages("sjPlot")
I need to install this package into R 3.5 so I can submit an R script that was created on that version. I have to do this via linux. After typing R35, I run install.packages('tidyverse') and get the folloing error:
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
namespace ‘vctrs’ 0.3.6 is being loaded, but >= 0.3.7 is required
ERROR: lazy loading failed for package ‘tidyr’
* removing ‘/ua/jwlorge/R/x86_64-pc-linux-gnu-library/3.5/tidyr’
ERROR: dependency ‘dtplyr’ is not available for package ‘tidyverse’
* removing ‘/ua/jwlorge/R/x86_64-pc-linux-gnu-library/3.5/tidyverse’
The downloaded source packages are in
‘/tmp/RtmpAHxP3R/downloaded_packages’
Warning messages:
1: In install.packages("tidyverse") :
installation of package ‘vctrs’ had non-zero exit status
2: In install.packages("tidyverse") :
installation of package ‘ellipsis’ had non-zero exit status
3: In install.packages("tidyverse") :
installation of package ‘hms’ had non-zero exit status
4: In install.packages("tidyverse") :
installation of package ‘pillar’ had non-zero exit status
5: In install.packages("tidyverse") :
installation of package ‘tibble’ had non-zero exit status
6: In install.packages("tidyverse") :
installation of package ‘dplyr’ had non-zero exit status
7: In install.packages("tidyverse") :
installation of package ‘dbplyr’ had non-zero exit status
8: In install.packages("tidyverse") :
installation of package ‘dtplyr’ had non-zero exit status
9: In install.packages("tidyverse") :
installation of package ‘tidyr’ had non-zero exit status
10: In install.packages("tidyverse") :
installation of package ‘tidyverse’ had non-zero exit status
I searched online and found other people who had this problem but none of the suggestions worked. I tried updating vctrs and rlang. This is the error I get when I try to re-install vctrs:
Error : .onLoad failed in loadNamespace() for 'rlang', details:
call: NULL
error: 'is_character' is not an exported object from 'namespace:rlang'
ERROR: lazy loading failed for package ‘vctrs’
* removing ‘/ua/jwlorge/R/x86_64-pc-linux-gnu-library/3.5/vctrs’
Re-installing rlang was successful but didn't solve the problem. I also found online that re-starting R solves the problem, but I am using linux and I am a bit new to it. I don't know how you would restart R35 in linux.
I have tidyverse succesfully installed in in another version but not in 3.5. Does anyone have an idea what is causing this issue? Thanks!
I'm trying to install ggplot2 on my campus' Rstudio server. Unfortunately I receive the classic "installation of package 'ggplot2' had non-zero exit status." I've looked through the many threads of users who've had the same problem with other packages, but haven't found any workable solutions.
I've tried using install.packages("ggplot2", dependencies = TRUE), which hasn't worked.
Also, I'm running the most recent version of OSX on a MacBook Pro.
This is the error message I receive:
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/mnt/trafficstop/jrleary/R/x86_64-redhat-linux-gnu-library/3.5/vctrs’
Warning in install.packages :
installation of package ‘vctrs’ had non-zero exit status
ERROR: dependency ‘vctrs’ is not available for package ‘pillar’
* removing ‘/mnt/trafficstop/jrleary/R/x86_64-redhat-linux-gnu-library/3.5/pillar’
Warning in install.packages :
installation of package ‘pillar’ had non-zero exit status
ERROR: dependency ‘pillar’ is not available for package ‘tibble’
* removing ‘/mnt/trafficstop/jrleary/R/x86_64-redhat-linux-gnu-library/3.5/tibble’
Warning in install.packages :
installation of package ‘tibble’ had non-zero exit status
ERROR: dependency ‘tibble’ is not available for package ‘ggplot2’
* removing ‘/mnt/trafficstop/jrleary/R/x86_64-redhat-linux-gnu-library/3.5/ggplot2’
Warning in install.packages :
installation of package ‘ggplot2’ had non-zero exit status
To put it simply, my R could not recognize my "libssl.so.1.0.0" installed.
Wondering any one has any suggestion.
For the details:
I was trying to install a R package "devtools",
but had one issue.
install.packages("devtools")
...
*** installing help indices
** building package indices
** testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) :
unable to load shared object '/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/git2r/libs/git2r.so':
libssl.so.1.0.0: cannot open shared object file: No such file or directory
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/git2r’
ERROR: dependency ‘openssl’ is not available for package ‘httr’
* removing ‘/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/httr’
ERROR: dependencies ‘httr’, ‘git2r’ are not available for package ‘devtools’
* removing ‘/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/devtools’
...
it seemed that "libssl.so.1.0.0" is required.
But when I checked which "openssl" I am using:
$ which openssl
~/.anaconda/bin/openssl
$ ldd ~/.anaconda/bin/openssl
linux-vdso.so.1 => (0x00007fffb0de8000)
libssl.so.1.0.0 => /somewhere/Jun/.anaconda/bin/../lib/libssl.so.1.0.0 (0x00002b0618dca000)
libcrypto.so.1.0.0 => /somewhere/Jun/.anaconda/bin/../lib/libcrypto.so.1.0.0 (0x00002b0619041000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000003cae000000)
libc.so.6 => /lib64/libc.so.6 (0x0000003cad800000)
/lib64/ld-linux-x86-64.so.2 (0x0000003cad400000)
So it seems to me that "libssl.so.1.0.0" was there, the problem is that R could not find it.
Any suggestion to solve this?
Update:
Another tempt (following 42-'s kind suggestion in the comments)
Adding dependencies=TRUE for "install.packages" command
install.packages("devtools", dependencies=TRUE)
1: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘openssl’ had non-zero exit status
2: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘git2r’ had non-zero exit status
3: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘httr’ had non-zero exit status
4: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘covr’ had non-zero exit status
5: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘gmailr’ had non-zero exit status
6: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘devtools’ had non-zero exit status
7: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘lintr’ had non-zero exit status
tried to install "git2r" first:
install.packages("git2r",dependencies=TRUE)
** R
** inst
** preparing package for lazy loading
Creating a generic function for ‘summary’ from package ‘base’ in package ‘git2r’
Creating a generic function for ‘diff’ from package ‘base’ in package ‘git2r’
Creating a generic function for ‘merge’ from package ‘base’ in package ‘git2r’
Creating a generic function for ‘plot’ from package ‘graphics’ in package ‘git2r’
Creating a generic function for ‘head’ from package ‘utils’ in package ‘git2r’
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) :
unable to load shared object '/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/git2r/libs/git2r.so':
libssl.so.1.0.0: cannot open shared object file: No such file or directory
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/host/somewhere/Jun/Programme/R-3.3.1/lib64/R/library/git2r’
The downloaded source packages are in
‘/tmp/Rtmp55IwjF/downloaded_packages’
Warning message:
In install.packages("git2r", dependencies = TRUE) :
installation of package ‘git2r’ had non-zero exit status