[R] Calling R function from within C code

ripley@stats.ox.ac.uk ripley at stats.ox.ac.uk
Thu Jan 16 16:23:02 CET 2003


That way.  It's a pairlist of arguments.  As that manual says

Function @code{lang2} creates an executable `list' of two elements, but
this will only be clear to those with a knowledge of a LISP-like
language.

There are examples in optim.c and deriv.c.

On Thu, 16 Jan 2003, Timur Elzhov wrote:

> I'd like to call R function from within C code.
> I looked through the 'R exts' manual, found examples with
> lang2(R_fcall, list), and tried it, but it seemed to create
> the call, which can accept only a single argument of 'list'
> type, when I need to create the call of R functions with
> arbitrary numbers of arguments.
> 
> How can I do it?

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list