Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have some ESRI grid data that I would like to import into Matlab. As a typical ESRI grid data I have the two folders with the *.adf files and *.dat, .nit and.dat files.

I would like to know how can I import the information stored in those files into Matlab.

Tank you all!

share|improve this question
add comment

1 Answer

I would convert the GRID to ASCII format first using Raster to ASCII (Conversion). If you have many GRIDs, use the batch conversion by right-clicking on the tool and selecting "batch". Then you can easily bring in the ASCII files into MATLAB using arcgridread. Here's an example from Mathworks:

[Z,R] = arcgridread('MtWashington-ft.grd');
mapshow(Z,R,'DisplayType','surface');
xlabel('x (easting in meters)'); ylabel('y (northing in meters)')
demcmap(Z)

There is also a discussion here that may give you some ideas too.

Another option is to convert your ESRI grids to another format, such as a TIFF, and bring them into MATLAB using imread (source).

share|improve this answer
    
Thank you very much for your response. I have already tried that but it's not working. When I convert it to ASCII I only get like the 'mask' of my data , that is: -9999 and 2 indicating whether there is a value or no data but not the actual value at each given point. Any idea how to retrieve the value? –  Maria Feb 15 '13 at 11:05
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.