[R] calling optim from external C/C++ program

Prof Brian D Ripley
2002-04-30T06:15:31Z

On Mon, 29 Apr 2002, Vadim Ogranovich wrote:

> Hi,
>
> Does anyone have an example of calling optim() from a standalone C/C++
> program? If possible please include the linker options (I am using gcc
> version 2.96 20000731 (Red Hat Linux 7.1 2.96-98))

It's not possible.  An important part of optim() is in R.  R 1.5.0 makes
the underlying optimizers available to C code linked into R, but they are
only part of optim().

There is also no such thing as gcc 2.96: see gcc.gnu.org.  You would be
well-advised to use a released version of gcc.

--
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 272860 (secr)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595