[R] Casting in R

From: Tuszynski, Jaroslaw W. <JAROSLAW.W.TUSZYNSKI_at_saic.com>
Date: Sat 26 Mar 2005 - 03:06:16 EST


I am looking for functions that would allow me to access raw binary data of R vectors. One way would be to use:

	x = (1:10)*pi
   	writeBin(x, "temp.bin")
   	r = readBin("temp.bin", "raw", n=length(x)*8)

Other to write my own C code. Is there any other simpler way?

I this message is a rewording of my yesterday message "Looking for function for Double to raw to double conversions", to which I got no replies. I need this functionality to implement Base64 encoding for reading/writing XML files.


 Jarek Tuszynski, PhD.                               o / \ 
 Science Applications International Corporation  <\__,|  
 (703) 676-4192                        ">  \
 Jaroslaw.W.Tuszynski@saic.com                   `    \

	[[alternative HTML version deleted]]

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sat Mar 26 03:10:40 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:30:56 EST