I'm trying to install Rmpi package in R on windows8. the R version is 3.4.3 .
I got this message
install.packages("C:/Users/Mariya/Desktop/Rmpi_0.6-6.zip", repos = NULL, type = "win.binary")package ‘Rmpi’ successfully unpacked and MD5 sums checked
when I wanted to run this library I got this message :
The procedure entry point MPI_COMM_SPLIT_TYPE could not be located in the dynamic link library
c: user/.../R/win-library/3.4/Rmpi/libs/X64/Rmpi.dll
and when I click ok, I got this error in cosole:
library(Rmpi)
Error: package or namespace load failed for ‘Rmpi’:.onLoad failed in loadNamespace() for 'Rmpi', details:call: inDL(x, as.logical(local), as.logical(now), ...) error: unable to load shared object 'C:/Users/Mariya/Documents/R/win-library/3.4/Rmpi/libs/x64/Rmpi.dll'/LoadLibrary failure: The specified procedure could not be found.
I had ms-mpi in my computer, I removed it and installed MPICH2 that is told here http://www.stats.uwo.ca/faculty/yu/Rmpi/windows2.htm
and then install Rmpi, but I got error again.
I send an email to the writer package Dr Hao Yu and found the solution.
I remove the MpiCH2 ,install msmpi and follow these Instructions : http://www.stats.uwo.ca/faculty/yu/Rmpi/
Related
I'm not too familiar with R and are using it for Uni, and we need this asreml package for one of our classes. When I try installing it this error comes up:
Error: package or namespace load failed for ‘asreml’:
.onLoad failed in loadNamespace() for 'asreml', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/00LOCK-asreml/00new/asreml/libs/libvsninet.so':
dlopen(/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/00LOCK-asreml/00new/asreml/libs/libvsninet.so, 0x0006): tried: '/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/00LOCK-asreml/00new/asreml/libs/libvsninet.so' (mach-o file, but is an incompatible architecture (have (x86_64), need (arm64e)))
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/asreml’
Warning in install.packages :
installation of package ‘/Users/Cami/Downloads/asreml-4.1.0.176-macOS-10.13.2-R4.2.tar.gz’ had non-zero exit status
I tried installing it on R both with a full path to the file and with a working directory set up. I've also tried to install it directly through the computer terminal, however, the same error comes up. A tutor in class has also tried to open a library for the package through the terminal on my laptop and it also didn't work. Neither of us are sure of what 'libvsninet.so' means. I've also tried to disinstall and reinstall both R and RStudio, but the result is the same.
install.packages("RMongo")
doesn't works (seems like it has been deprecated.
So, I was trying to install using devtools.
devtools::install_github("tc/Rmongo")
but it gives out error
Error: package or namespace load failed for 'rJava':
.onLoad failed in loadNamespace() for 'rJava', details:
call: inDL(x, as.logical(local), as.logical(now), ...)
error: unable to load shared object 'C:/Users/saini/OneDrive/Documents/R/win-library/3.5/rJava/libs/i386/rJava.dll':
LoadLibrary failure: %1 is not a valid Win32 application.
Error : package 'rJava' could not be loaded
Error: loading failed
Execution halted
*** arch - x64
Warning: package 'rJava' was built under R version 3.5.2
ERROR: loading failed for 'i386'
* removing 'C:/Users/saini/OneDrive/Documents/R/win-library/3.5/RMongo'
In R CMD INSTALL
Error in i.p(...) :
(converted from warning) installation of package ‘C:/Users/saini/AppData/Local/Temp/RtmpuEHfqO/file20f419985c01/RMongo_0.1.0.tar.gz’ had non-zero exit status
Even though library(rJava) works fine.
JDK, JRE are both 64 bit. R and R studio are also 64 bits.
Someone suggested to use
R CMD javareconf
but it doesnot recongnises javareconf.
Also, I've set Environment Variables.
I was trying to install the package igraph in R using the command install.packages("igraph"). After the installation, during testing phase it showed the following error:
testing if installed package can be loaded Error: package or namespace
load failed for ‘igraph’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object
'/home/midhun/R/x86_64-redhat-linux-gnu-library/3.5/igraph/libs/igraph.so':
libicui18n.so.58: cannot open shared object file: No such file or
directory Error: loading failed Execution halted ERROR: loading
failed
removing ‘/home/midhun/R/x86_64-redhat-linux-gnu-library/3.5/igraph’
The downloaded source packages are in
‘/tmp/RtmpLVDism/downloaded_packages’ Warning message: In
install.packages("igraph") : installation of package ‘igraph’ had
non-zero exit status
Why this is happening? What could be a solution?
The library igraph requires library files such as:
libicui18n.so.58, libicuuc.so.58, libgfortran, etc.
These were either not installed in the proper library folder or were existing as previous versions. For example, in my case, libicuuc.so.58 was required to be installed in usr/lib64. Make sure that dependencies are installed correctly to solve such problems.
Bear in mind that I am computer illiterate and new to R. I have installed the rJava package in R studio version 1.0.143 and installed Java 8 (using MacOS Sierra). When I try to load the rJava package:
library(rJava)
I get the following error
Unable to find any JVMs matching version "(null)".
No Java runtime present, try --request to install.
Error: package or namespace load failed for ‘rJava’:
.onLoad failed in loadNamespace() for 'rJava', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object
'/Users/cormac/Library/R/3.4/library/rJava/libs/rJava.so':
dlopen(/Users/cormac/Library/R/3.4/library/rJava/libs/rJava.so, 6):
Library not loaded: #rpath/libjvm.dylib
Referenced from:
/Users/cormac/Library/R/3.4/library/rJava/libs/rJava.so
Reason: image not found
In addition: Warning messages:
1: package ‘rJava’ was built under R version 3.4.2
2: running command '/usr/libexec/java_home' had status 1
Could somebody help me to interpret this error message? There is probably a very simple solution, but I am completely lost. Thank you!!
As noted in Unable to load rJava in RStudio, there is a very specific sequence of steps that must be taken to get rJava to work on a Macbook, as documented in rJava Issues #86.
Download and install Java from Oracle
Uninstall any previously installed version of rJava
Add JAVA_HOME to your .bashrc
Close & restart terminal, R and RStudio sessions so they pick up the updated JAVA_HOME
Use install.packages() to install rJava
See the URL link above for additional details on each step.
my computer is windows system, 64 bit. I am trying to install rJava_0.9-8,RWeka_0.4-29 and RWekajars_3.9.0-1 from local to R, R version is R3.4.1 and R3.0.8. Here is my steps and errors:
I tried install zip files as follows:
package ‘rJava’ successfully unpacked and MD5 sums checked
utils:::menuInstallLocal()
package ‘RWeka’ successfully unpacked and MD5 sums checked
utils:::menuInstallLocal()
package ‘RWekajars’ successfully unpacked and MD5 sums checked
then I checked it as follows:
library(rJava)
Error: package or namespace load failed for ‘rJava’:
.onLoad failed in loadNamespace() for 'rJava', details:
call: fun(libname, pkgname)
error: JAVA_HOME cannot be determined from the Registry
library(RWeka)
Error: package or namespace load failed for ‘RWeka’:
.onLoad failed in loadNamespace() for 'rJava', details:
call: fun(libname, pkgname)
error: JAVA_HOME cannot be determined from the Registry
I even tried another way as follows:
install.packages("G:/Data mining/rJava_0.9-8", type="win.binary", repos=NULL)
Installing package into ‘C:/Users/Ellen/Documents/R/win-library/3.4’
(as ‘lib’ is unspecified)
Error in .zip.unpack(pkg, tmpDir) :
zip file ‘G:/Data mining/rJava_0.9-8’ not found
Can anybody help me install these zip files?
Thanks
Encountered this issue before.. Try installing 64-bit or 32-bit Java, depending on what r version you have...
error in installing RWeka package in R
I also had to mess around with some code to set the java_home environment variable.
Try messing around with this script, which is not in any order... either set the env variable to where Java is installed, or leave it blank, which seemed to work for me.
library(rJava)
Sys.setenv(JAVA_HOME='C:\\Program Files (x86)\\Java\\jre1.8.0_131')
install.packages('rJava')
Sys.setenv(JAVA_HOME='C:\\Program Files\\Java\\jre1.8.0_131\\bin') # for 64-bit version
# Need to set rJava to blank for it to load
Sys.setenv(JAVA_HOME='')
library(rJava)
Sys.getenv("JAVA_HOME") # Use this to see where the env var is pointing to
library(RWeka)
I fixed the problem now, it was caused by my student account, not R. The solution is:
library(rJava,lib.loc ="H:/R")
install.packages("H:/2-COMP723_Data Mining/rJava_0.9-8.zip", repos = NULL, type = "win.binary",lib = "H:/R")
library(rJava)
Thanks guys.