Ocean Color Forum - Not logged in
In the past, our group has used the hdfgroup's h4toh5 converter to produce hdf5 files and then loaded those using the hdf5 library in R. This has not been a robust approach, particularly for Windows XP users, and does not preserve map projections. Recently, the hdfgroup made Windows 7 their "reference" platform and do not appear to have current binaries for Windows XP. This means R developers would need to produce their own hdf5 libraries in order to support XP. Meanwhile, the rgdal library appears to be well maintained on Windows, and installs easily on linux or Mac OS X. SeaDAS 6.x supports geotiff directly, but produces 8-bit RGB. I have, however, found that rgdal can read geotiff's with 'float' values created using the following user band command gleaned from other postings to these forums:
; write tiff with 'float' data
MAKE_GEOTIFF, fbuf, B1, map_info, geo_tags
RESULT=-1.0*B1 ;; convert to float
WRITE_TIFF, 'float.tif', RESULT, GEOTIFF=geo_tags, /FLOAT
The WRITE_TIFF procedure is part of SeaDAS and only supports the cylindrical equidistant projection. There are some examples on the web of the geo_tags structure for other projections, but because IDL has a proprietary projection library this may not always be a simple task. Another route to get the geo_tags structure is to create a geotiff with the projection you want using your external application, then have someone with an IDL license dump the structure for you and try to construct a matching projection in IDL.
Time will tell if this a more robust approach than relying on h4toh5 and hdf5 readers.