From ripley at stats.ox.ac.uk  Tue May 13 19:11:23 2008
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Tue, 13 May 2008 18:11:23 +0100 (BST)
Subject: [Rd] Catching warning message(stdout) from C
In-Reply-To: <1210689426.5844.34.camel@5-hkg-07-0014>
References: <1210689426.5844.34.camel@5-hkg-07-0014>
Message-ID: <alpine.LFD.1.10.0805131805420.5570@gannet.stats.ox.ac.uk>

On Tue, 13 May 2008, Maarten van Iterson wrote:

> I'm using the 'pnt' C function from Rmath library in some C-code.

So I assume you compiled against -lRmath?

> How can I catch the warning message: "full precision was not achieved in
> 'pnt'" in R. I call the function using the .C().
> (options(warn=-1) didn't work)

If you are calling options(warn=-1) then you are running R, and in that 
case you want to link against R and not against -lRmath.  libRmath is 
intended for standalone use, without R involved.


> Thanks in advance
>
> -- 
> Maarten van Iterson
> Center for Human and Clinical Genetics
> Leiden University Medical Center (LUMC)
> Research Building, Einthovenweg 20
> Room S-04-005
> Phone: 071-526 9428
> E-mail: M.van_iterson.HG at lumc.nl
> ---------------
> Postal address:
> Postzone S-04-P
> Postbus 9600
> 2300 RC Leiden
> The Netherlands
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>

-- 
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



[Rd] Catching warning message(stdout) from C
Prof Brian Ripley