[Rd] possibility of R/Maxima linking

From: Robert Dodier <robert.dodier_at_gmail.com>
Date: Wed 03 Aug 2005 - 02:34:07 GMT


I'm aware that recently there has been discussion of R joining forces with an algebra system in some way. Here is my $0.02.

I suggest linking R with Maxima (http://maxima.sf.net). Maxima is written in Lisp. Maxima objects are pretty simple. Maxima works on expressions, and almost every expression is a Lisp list of the form ((op) arg1 arg2 arg3 ...) which associates an operator and its arguments. Every kind of operation is cast in this form -- infix, prefix, postfix, function calls, array references, lists, and even control structures such as if-then-else and do-loops.

Maxima usually parses an input written in the Maxima language (yet another Algol derivative) and then calls MEVAL, the main evaluation function, with the Lisp representation of the input as its argument. However, if R could construct a suitable Lisp object, R could bypass the parsing and just call MEVAL directly.

Although several interfaces which are based on sockets have been created, I believe it should be possible to directly link Maxima with R, if Maxima is compiled with a Lisp variety which is implemented in C. I believe direct linkage is possible with Clisp, and maybe with GCL as well.

Whether or not this scheme works depends pretty strongly on how much effort is needed to munge R objects into Lisp. Maybe someone has some comments about that.

There is more that can be said but I'll let this be enough for now.

all the best,
Robert Dodier

R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed Aug 03 12:37:32 2005

This archive was generated by hypermail 2.1.8 : Mon 24 Oct 2005 - 22:27:33 GMT