Re: [Rd] missing IntegerFromString()

From: Aniko Szabo <>
Date: Wed, 06 Jun 2007 09:48:54 -0500

Thanks to everybody who responded to my question. asInteger(coerceVector(x,INTSXP)) indeed does what I need. I guess there is a lot I don't understand about type coercion, as I would not have expected it to work.


-----Original Message-----
From: Seth Falcon [] Sent: Tuesday, June 05, 2007 11:24 PM
To: Aniko Szabo
Subject: Re: [Rd] missing IntegerFromString()

Hi Aniko,

"Aniko Szabo" <> writes:

> I have created a DLL not so long ago using C code. My code used the
> IntegerFromString() function that used to be exported in the
> Rinternals.h header file (and thus easily accessible). Recently I
> upgraded to R 2.5.0 and my DLL stopped working. I see that the
> IntegerFromString() function is not exported in any of the header
> in the RHOME\include directory. Is it possible for me to use it
> installing all R source files? I can see that the function is in
> coerce.c, however it #includes other stuff that I don't have and I am
> afraid to mess things about by doing things I don't understand. Or
> perhaps there is another function that is intended to be used
> instead?

I think you want asInteger (which calls IntegerFromString). This is in RHOME/include/Rinternals.h

Best Wishes,

+ seth

PS: Nice to see you again :-)

Seth Falcon | Computational Biology | Fred Hutchinson Cancer Research

______________________________________________ mailing list
Received on Thu 07 Jun 2007 - 08:47:46 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 07 Jun 2007 - 16:34:30 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.