[R] running SJava

Thomas Lumley tlumley at u.washington.edu
Thu Aug 29 17:09:29 CEST 2002


On Wed, 28 Aug 2002, Stephen C. Upton wrote:

> Folks,
>
> Having problems getting started with SJava and request help.
>
> I get this error when running .JavaInit() (within RGui 1.5.1, on Windows
> 2000):
> Error in .JavaInit() : Couldn't start Java Virtual Machine: Cannot find
> the Omegahat interface manager class. Check you classpath!

One workaround I have had some success with is to set the working
directory to the directory containing the Omegahat dll before running
.JavaInit().

	-thomas

> (Before you right back saying read the emails, please read further - in
> short, been there, done that)
>
> Environment:
> RWin 1.5.1 (install from binaries)
> OS Win 2000 SP3
> jdk 1.4.0 (could this be it?? I saw requirement for 1.2 or 1.3 - I
> wouldn't think this is the problem)
> SJavaWin_0.62-8 binary
> (. . . what else?)
>
> Install procedure:
> 1. According to http://www.omegahat.org/RSJava/#Download,
> cd $RHOME/library
> unzip SJavaWin_0.62-8.zip
> 2. did that
> 3. got .Defunct error. email suggested changing SJava file in
> {R_HOME}/library/SJava/R
> 4. did that
> 5. tried .JavaInit()
>
> Attempts to solve problem:
> 1. Read the FAQ. Not much here on this one, although several emails
> requesting help on this one, with no apparent solution.
> 2. Read the Archives. There were several emails concerning this, but
> though one even said problem solved, but does not. It's a java classpath
> problem, and not a LD_LIBRARY problem.
> 3. RTFM. Actually, the Howto.pdf dated 16 July 2002 (page 5), in fact
> states:
> "The default values in .javaConfig are computed and fixed when the R
> library is installed These contain
> the entries of the default classpath necessary to locate the classes
> used to run the embedded Omegahat
> interpreter and also the system properties that control how that
> interpreter is created and behaves (e.g.
> class names for components, etc.)." The other manuals don't seem to
> cover the
> a. Tried setting a reasonable classpath, in my case
> C:/R/rw1051/library/SJava in a CLASSPATH environment variable. java
> should be able to find the
> org.omegahat.Interfaces.NativeInterface.OmegaInterfaceManager. However I
> noticed on the SJava file, in the javaConfig assignment, the
> expression      if(nchar(tmp) > 0)
>        classPath <- strsplit(tmp,":")[[1]]
>    }
> " which seems to split based on a unix environment and not a windows.
> Realizing I *shouldn't* need this just to see if things will run, took
> out my CLASSPATH (after trying other various settings).
> b. Tried modifying the SJava file where the default$classPath is set.
> 4. Uninstalled by deleting the library/SJava directory and started over.
>
> Any help would be greatly appreciated. Also willing to be a guinea pig
> for the windows stuff. Haven't tried a install from source. My next step
> if I haven't really mucked things up.
>
> thanx
> steve
> novice R user, but plenty of java
>
>
>
> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
> r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>

Thomas Lumley			Asst. Professor, Biostatistics
tlumley at u.washington.edu	University of Washington, Seattle
^^^^^^^^^^^^^^^^^^^^^^^^
- NOTE NEW EMAIL ADDRESS

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list