[R-gui] Getting started on R GUIs

Duncan Temple Lang duncan at research.bell-labs.com
Thu Dec 18 08:07:03 MET 2003


I imagine that you the R DCOM interface you are referring to is Thomas
Baier's version on CRAN.  If so, an alternative view 
is the RDCOMServer on the Omegahat site:
  www.omegahat.org/RDCOMServer

It allows one to create R server objects for DCOM rather than using
the S language as the medium to chose. That should be higher
performance and certainly more flexible in development. And it is
bi-directional in the sense that R can call DCOM methods using the
RDCOMClient ( www.omegahat.org/RDCOMClient).  These servers can be run
in process or not; depends on registration and invocation options.
And this handles a rich set of data types.

We can do a .Net interface in much the same way we have done SJava and
other inter-system interfaces. The model is pretty well established.

Over the past 4 years, we have been pushing on embedding R in other
applications.  In the no too distant future, we might push further on
this for creating stand-alone R applications which are as lean as
possible by examining the call graph of the script.  The RDCOMServer
package might be a good place to start, either using it directly or
using it as sample code for how to embed R in another application.

As Byron mentioned in his response, generalizations of the event loop
are underway. But typically, when embedding R in other applications,
the R event loop is not an issue; R is used just as a library of
functions or interpreter.  The events are handled by the host
application.

Fast ways to get data into R will probably be context dependent.  One
situation that I think is worth exploring is avoiding explicit
transfer but rather let R pull it as needed.  Different data models
(e.g. ADO) might be worth looking at, and as I mentioned, the
bi-directional RDCOM client and server make this feasible (entirely
within R code).

Just some quick thoughts. I can be more specific if needed when I have
some more time.

 D.

Anthony Berno wrote:
> Hello all,
>  
> I'm working on a Microsoft .NET application in which is, in part, an R
> front end. But I'm having a bit of difficulty getting started. I spent a
> bit of time writing a package that communicates with the R executable
> using text, but that was a disaster. Information about other methods has
> been a little hard to come by.
>  
> I've used the R DCOM interface, and looked at the source code, but it's
> a little obscure, and I"m having a hard time figuring out how it works
> at all. I've successfully written a VB test app that uses this server,
> but I'd rather not do all the .NET -> DCOM interoperability stuff if
> there is a more direct, and possibly higher-performance route to
> accessing R functionality.
>  
> So a few extremely basic questions:
>  
> - Is the file R.dll the DLL that is most suitable for letting my app
> talk to R?
>  
> - Assuming this is the case, I can't figure out what the correct header
> file is, or find any description of the entry points to this DLL. Some
> introductory material would be very helpful!
>  
> And a few more general ones:
>  
> - Does the R engine necessarily run in a different process, or can it be
> run in the same process as my app?
>  
> - What is the fastest possible way to get a large dataset (10 - 100K
> rows) from an application front end into the R engine, and back out
> again?
>  
> Thanks for any comments you might have.
>  
> -Anthony Berno
>  
>  
>  
> 
> 	[[alternative HTML version deleted]]
> 
> _______________________________________________
> R-SIG-GUI mailing list
> R-SIG-GUI at stat.math.ethz.ch
> https://www.stat.math.ethz.ch/mailman/listinfo/r-sig-gui

-- 
_______________________________________________________________

Duncan Temple Lang                duncan at research.bell-labs.com
Bell Labs, Lucent Technologies    office: (908)582-3217
700 Mountain Avenue, Room 2C-259  fax:    (908)582-3340
Murray Hill, NJ  07974-2070       
         http://cm.bell-labs.com/stat/duncan



More information about the R-SIG-GUI mailing list