"R extension"
yoshida
New Altair Community Member
Follow the guidance to install R extension, but the RapidMiner complained about :
The local binary library "...\jri.dll' could not be loaded. Reason: ...\jri.dll: Can't find dependent libraries.
This might be the problem of Java path setting. Any idea?
Many thanks !!!
The local binary library "...\jri.dll' could not be loaded. Reason: ...\jri.dll: Can't find dependent libraries.
This might be the problem of Java path setting. Any idea?
Many thanks !!!
Tagged:
0
Answers
-
Hi
If you have installed the rJava library in R, there is a jri native library inside the jri directory of the rJava R plugin.
You have to select the jri library for your OS (jri.dll or libjri.so).
Cheers
Javier0 -
Thanks, Javier:jbejar wrote:
Hi
If you have installed the rJava library in R, there is a jri native library inside the jri directory of the rJava R plugin.
You have to select the jri library for your OS (jri.dll or libjri.so).
Cheers
Javier
I did install rJava and provide the path to the RapidMiner. I checked this from the Preference Setting. It is there.
But it does not work, why?
Regards
Ryu
0 -
You have to put the path to the file that contains the jri library (.dll or .so), the path to the rJava instalation does not work.
Cheers.
Javier0 -
I have the same problem. I specify the directory (i think correctly) but appears the same message.
I use windows xp OS and the direcotry that i put in the R extension setting is "c:\...\R\R-2.11.1\library\rJava\jri\jri.dll"
Thanks.
arzofaifo0 -
FYI. I followed the directions to a T and it all worked. Its most important to add R bin directory to your path, and also create the JAVA_HOME system variable with the path to the RM JRE.
-Gagi0 -
Thanks a lot for your replies.
I have tried everything as you suggested, but it did not succeed.
1) JAVA_HOME=C:\Program Files\Java\jdk1.6.0_21
2) Add the R and jri.dll directory to the PATH.
Any idea?
Thanks
Ryu
0 -
@arzofaifo, CO http://wso2.org/project/wsas/java/1.1/docs/setting-java-home.html for setting the mentioned JAVA_HOME on XP (default entry is C:\Program Files\Java\jre6)
Beneath it you should edit the field Path and enter C:\Program Files\R\R-2.11.1\bin if you used the default installation settings.
Then when you start RM it will load longer and you will be able to enter the R console view (part with the Preferences -> R extension you've put in RM should be just like that if you installed R/library in default directory).
@Ryu, regarding XP there is no need to add R and jri.dll to Path, just R/bin (C:\Program Files\R\R-2.11.1\bin). I don't have JDK installed which is why probably my settings were a bit different.0 -
thanks a lot for the tutorial of setting the JAVA_HOME parameter. But the problem still work
JAVA_HOME= "C:\Program Files\Java\jre6"
jri.ddl path = "C:\Program Files\R\R-2.11.1\bin"
i try to copy the jri.ddl in the bin folder of R and both libraries to the JAVA\jre6\bin folder but have the same problem.
0 -
I had the same problem.
If you have jdk installed in your system, try to configure the JAVA_HOME like "C:\Program Files\Java\jdk1.6.0_20\jre\bin;C:\Program Files\Java\jdk1.6.0_20\bin;"
If you don't have jdk installed, try to configure the JAVA_HOME "C:\Program Files\Java\jre6\bin"
It worked for me.
Ronaldo Baltar0 -
What you need to do is (In Windows):
1. Put in your PATH the right location of your JAVA_HOME. If you don't have a JAVA_HOME then you need to create it!.
Your PATH must contain something like this: PATH=<other_paths>;%JAVA_HOME%\bin
2. You need a path to your R directory. Something like this: R_HOME=<r_directory>. Then you need to add this variable to the PATH in the same way you did the JAVA_HOME variable. PATH=<other_paths>;%R_HOME%\bin
In Unix is very similar, the difference is the way you create your variables and the way you add these ones to the PATH (Here the separator character is ':' and not a ';' like in windows).
After all that, you can restart your RM environment.
That's all!
0 -
Hi,
cool to see that there are some people using (or at least trying to use) the new R Extension. Beside from the fact that installation doesn't seem to be that easy, I would be happy about any feedback to the way this extension works, what's missing, where problems and missunderstandings can arise.
I personally am not an R expert and so we might have missed some issues during design time. I would be happy if you could contribute on that way.
For people who really like the idea and want to invest a little bit more energy in that, we have a Special Interest Group, dealing with these issues of integrating R to RapidMiner. If you want to join, just write me a mail or a personal message.
Back to the original problem:
How many people still have problem with installing the extension? It seems to me that only arzofaifo's installation resists any improvements. Anyone else?
@arzofaifo
I would suggest removing the setting's value from the RapidMiners property dialog and again follow the installation instructions popping up on the next startup. I think you have messed something up somewhere there and cleaning everything and restarting from scratch will probably solve the issue.
If not, we need some more details on your installation and your steps during setup to find the error.
Greetings,
Sebastian0 -
Hi,
In fact I also had to add "C:\Program Files\R\R-2.12.0\bin\i386" to the PATH variable (in addition to "C:\Program Files\R\R-2.12.0\bin"), since the R.dll file is in the i386 folder. This has changed in version R-2.12.0 (there was no such folder in R-2.11.1).
Best
Gilbert0 -
Hi,
I think there is also a problem with recognising the PATH or JAVA_HOME variables if you set them *after* you've installed Rapidminer. I have installed the R extension on my computer at work (Vista) and at home (Windows 7) and got the same behaviour. I first set the environment variables to point to the Java installation, but restarting Rapidminer didn't start the installation guide. After uninstalling and then re-installing Rapidminer, it correctly started the installation guide for the R extension. Maybe there is a more elegant solution, and I have no idea whether a re-install will remove configuration data. In my case, I am only just starting to use Rapidminer, so it didn't matter much. Excellent tool by the way.
Gilbert0 -
Hi,
if you set system wide environment variables while a program is running, these changes does not affect the actual running program. You have to restart it completely. This holds true for command lines, too, so if you start RapidMiner from a console and do not restart the console after changing the settings, the old settings are used with which the console was started.
Greetings,
Sebastian
PS: Everybody who got it to work is welcome to give feedback to the Extension. We want to further improve it and hence need some user feedback, what's still missing, what's not as it should be, etc...
0 -
I have just installed RapidMiner on XP, which already housed R. Unfortunately, I am having trouble getting the R extension to work. I have attempted to follow all directions provided by RapidMiner after R Extension was installed and have also tried troubleshooting with what I've found on the forum. After installing the Extension and restarting RapidMiner, I get the following error:
The local binary libary '...\R-2.11.1\library\rJava\jri\jri.dll' could not be loaded. Reason: ...\R-2.11.1\library\rJava\jri\jri.dll: Can't find dependent libraries.
The R folder does show up in RapidMiner in the Operators menu. However, when I try to run one of the R operators in the Process window, I get a Process Failed message: Reason: Could not initiate session with native R. Try using server. Reason: Could not initialize R via JRI. Reason: Cannot load JRI native library.
It would be very helpful to have fully enumerated directions that take a user from Help>Update RapidMIner through successful installation. Thanks in advance!0 -
My rapidminer has R operators, but also comes up to this can-not-find-jri.dll problem when it starts up.
I followed suggestions in this topic, but I found that I had no jri.dll or R folder although I had installed the R extension.0 -
Hi,
I suspect you both have forgot to include the R/bin directory into your PATH variable.
If you have the newest .12 version of R installed these directories might have moved somewhere else. Please take a look for the file R.dll. This is the directory you have to insert into the path.
The Extension has been released with 2.11.1 version of R and the installation is tested on this particular version.
Greetings,
Sebastian0 -
I have updated to R-2.12.0 and change the directory. The problem still exists.
It must be something wrong with Java, but I do not know what.
I did the same thing (but R-2.11.1) on a brand new laptop (windows 7, 64). No problem at all. What is the problem with my desktop?
Thanks
Ryu
0 -
I have just double checked and have, in fact, defined R/bin as a system path variable. I am running R-2.11.1. A simple step-by-step guide would be beneficial. If we standardize everyone's process, we can better identify possible bugs, etc. (if problems still exist).
Thanks,
Damian0 -
Hi,
actually I thought there IS a step by step guide in the installation hints?
Greetings,
Sebastian0 -
yes there is one, but it's not very practical ( you got the solution before having the pb and just after you see the pb you got a one choice restart button , lol)Sebastian Land wrote:
actually I thought there IS a step by step guide in the installation hints?
otherwise, there who I fixed this pb:
* copy/paste of the rapidminer step by step instructions:
**to change system environment variable (java home path and system path):
1. After you have installed a proper version of R, you need to open the R console to prepare R to support being accessed by RapidMiner. You have to install rJava available on CRAN by typing the following command on the console:
install.packages("rJava")
2. You should now type .libPaths() and note the listed directories. One of them is used to store the rJava package and you will need to remember it when RapidMiner starts. If finished successfully, R is prepared for RapidMiner.
3. Now you have to make sure, that RapidMiner can find the program libraries of R by adding it to the PATH environment variable of your operating system: Add <R installation directory>/bin to the PATH variable on Linux systems or <R installation directory>\bin on Windows machines. This directory must contain the dynamic link library of R and all dependent libraries, which is called libR.so, R.so or R.dll depending on your operating system.
4. If you don't already have a valid JAVA_HOME variable pointing to the installation directory of your java, you need to create it. If you don't have java installed on your computer, point it to <RapidMiner installation directory>/jre. You have to make sure, that the java is of the same architecture as R and RapidMiner, either 32bit or 64bit.
5. Now you can configure RapidMiner. If you click on Next, you will be asked to enter the path to the jri library that has been installed with rJava. This is located in one of the .libpath directories noted above and more exact in <libpath directory>/rJava/jri/. The filename depends on your operating system and is jri.dll on Windows and libjri.so or jri.so on Unix.
6. If you have selected the file, RapidMiner will exit, since the new environment variables are still unknown and you need to restart the program manually.
If the new R Perspective has been added after restart, everything runs just fine. If not, please check if the file is in the correct directory, is accessible by RapidMiner and if the path is set to the correct R version.
***if \bin doesn't work try \bin\i386 (where do u find the R.dll)Marin wrote:
http://wso2.org/project/wsas/java/1.1/docs/setting-java-home.html for setting the mentioned JAVA_HOME on XP (default entry is C:\Program Files\Java\jre6)
Beneath it you should edit the field Path and enter C:\Program Files\R\R-2.11.1\bin if you used the default installation settings.
Then when you start RM it will load longer and you will be able to enter the R console view (part with the Preferences -> R extension you've put in RM should be just like that if you installed R/library in default directory).
@Ryu, regarding XP there is no need to add R and jri.dll to Path, just R/bin (C:\Program Files\R\R-2.11.1\bin). I don't have JDK installed which is why probably my settings were a bit different.0 -
I'm sorry all, but I have reinstalled R and RapidMiner 4 times. I even reinstalled XP. Each time, I have tried following the above instructions to a T, but it is still not working. I'm still getting the "Could not load native library" error. Suggestions? Anyone want to make a video tutorial taking everyone through the process?
Best,
Damian0 -
Hi,
one last suggestion before I have to ask someone to volunteer to surrender his computer so that I can track this problem
Please set the additional R_HOME environment variable as mentioned in the thread earlier. I didn't need to set it but it seems on other machines this is the case. Please set it to the installation directory of R, for example "C:\Programs\R\R-2.11.1"
If this does not help, then we actually have a problem: Since this behavior does not show up on our machines, I would like to ask you for helping me, tracing this problem. Everybody who volunteers, please do the following:- start a new command shell. On windows type "cmd" into the "execute command" box reachable by the start menu
- execute the "set > c:\variables.txt" command and send me the resulting file c:\variables.txt by mail.
- I will then contact you with further questions or post a solution here
Sebastian0 -
Hi All,
a hint and a reminder.
Hint: Use the tool Dependency Walker (http://www.dependencywalker.com/) to load the jri.dll - you will immediately see whether it finds its dependent DLLs (such as JVM.dll, and R.dll)
Reminder: Please note (or remember) that R version 2.11.x has a different directory structure compared to version 2.12.0. So you can't simply switch between the two versions and expect the R Extension to work.
Gideon0