[R-sig-Geo] reading select values from a binary file

Karl Ove Hufthammer karl at huftis.org
Thu Dec 10 10:39:50 CET 2009

On Wed, 9 Dec 2009 10:58:01 -0600 Jonathan Thayn <jthayn at ilstu.edu> 
> Now I want to open select values from the binary file, not a complete 
> line. Say I want to read values 3, 7, and 10, process them, write the 
> result, and then read values 4, 5, and 17.  How do I direct readBin to 
> those specific values? Thanks.

You can use the 'readBinFragments' function in the 'R.utils' package.

Also, if your file is an a 'standard' format, the 'raster' package may 
be of use: http://raster.r-forge.r-project.org/

Karl Ove Hufthammer

More information about the R-sig-Geo mailing list