Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Importing ESRI raster data to MATLAB

299 views
Skip to first unread message

Troy Fowler

unread,
Apr 7, 2006, 4:05:02 AM4/7/06
to
Can anyone help clarify the steps to converting ESRI raster data sets
into a MATLAB-friendly format?

I am trying to import raster datasets created with ArcMAP 9.0 in
MATLAB, but the MATLAB import wizard does not recognize any of the
ESRI file formats.

What am I missing?

Thanks for your time.

Mingtian

unread,
May 10, 2006, 2:37:05 PM5/10/06
to
I am also working on this annoying issue. One way to show the raster
maps in MATLAB is converting raster data to Arc/Info ASCII Grid
Format by Convertion Toolbox. The output file can be .txt or .asc,
however you need to change it to .grd by hand otherwise MATLAB won't
recognize it. Then either geoshow or mapshow can plot the map.

In case you need the data in raster file, landuse classes for
instance, one way I can image is delete the first 4 lines of the
ascii file (.grd) then load it into MATLAB. But the problem is I
didn't find an easier way to link the cells with Lat/Lon coordinate
yet.

Hope this would be helpful......

J. Luis

unread,
May 10, 2006, 6:23:56 PM5/10/06
to

You may want to try my program. It reads binary/ascii Arc
grids as well as ESRI hdr files.
w3.ualg.pt/~jluis/mirone

J. Luis

R. Koller ADD

unread,
Jun 20, 2006, 9:38:12 AM6/20/06
to
i was in front of a similar problem. ;) well i am using tntmips and
already figured out that gis specific rasterformats arent recognized by
matlab. and its also problematic if you wanna port 32 bit floating
point data for example over to matlab like in my case. but the securest
way is ( i suppose) to export your raster data sets into seperate text
files and then import into matlab. worked the best for me. only problem
for me is the import speed and processing speed afterwards. or maybe
you can try to export your rasters into sun raster format. that
provides 32 bit floating point values (which doesnt work in tntmips) or
if you deal with only 8 bit integer values you might try also tiffs.
hope that helps a bit. best regards ralf

Stelios Liodakis

unread,
Sep 27, 2010, 6:20:04 AM9/27/10
to

I'm trying to follow these simple guidelines but Matlab won't recognise the .grd file i have created from the ascii file that was exported from Arcmap.
The message i'm geting is the following :

??? Function ARCGRIDREAD was unable to find file 'sooo.grd'.
Error in ==> arcgridread at 26
[filename, isURL] = checkfilename(filename, {'grd'}, mfilename, 1, true);

'sooo.grd' is the name of the ascii file i'm trying to import to Matlab
I would be grateful if somebody would help me out because i can't understand what seems to go wrong
Thanks

Steven_Lord

unread,
Sep 27, 2010, 9:27:29 AM9/27/10
to

"Stelios Liodakis" <slio...@hotmail.com> wrote in message
news:i7pr4j$3v$1...@fred.mathworks.com...

Is the sooo.grd file in the current directory or in a directory on the
MATLAB path?
If not, have you specified the full path to the file in your call to
ARCGRIDREAD?
Are you certain that the file is named sooo.grd and not soooo.grd or
s000.grd or something similar?

--
Steve Lord
sl...@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Stelios Liodakis

unread,
Sep 29, 2010, 5:40:09 AM9/29/10
to
Steven
Finaly i've used <txt2mat> that worked fine for me
Thanks for your time
0 new messages