[R-sig-Geo] How to open and work with an .hdf map

Marc Marí Dell'Olmo marceivissa at gmail.com
Fri Jul 6 11:32:21 CEST 2012


Hello,

I'm trying to open and work with a map I have downloaded from
http://glovis.usgs.gov/, obtained from MODIS Terra satellite. This web
only allows to download maps in .hdf format. I do not have ArcView, a GIS
programme which opens these maps without any problem. I have been trying to
do it using "R", however, I have not succeeded... First, I converted the map
- which is in version 4 - to version 5 (with h4h5tools
http://www.hdfgroup.org/h4toh5). I have tried to open it with satinGet
(library satin) but I have obtained this error message:
Error en queryname(nom.hdf5, what = "date") :
 objeto 'date.str' no encontrado

Finally I managed to open the file using the function hdf5load (library
hdf5). With this function I have obtained two objects   "HDF4_DIMGROUP" ,
"MOD44B_250m_GRID" but I don't know how can I represent spatially the data.
I think I have a grid with the values of the variables but I don't know the
reference of the coordinates (UTM long lat), the distance between the points
of the grid, etc... In general, I don't know how to work with the
information...

I'm using Windows.

Here is the link of the original map, in case it helps.

http://dl.dropbox.com/u/22891835/MOD13Q1NDVI_2012Maig.hdf

Thanks in advance for the help!

Marc



More information about the R-sig-Geo mailing list