Rank: 23699 based on 0 downloads (last 30 days) and 0 files submitted
photo

Colin Lazauski

E-mail

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Comments and Ratings by Colin
Updated File Comments Rating
13 Mar 2009 ARCGRIDWRITE Write gridded data set in Arc ASCII Grid Format Author: Andrew Stevens

This is a nice file and works well. Modification of the header section write format will allow the file to be read directly by ESRI Arc-GIS. My modification is:

%write header
fprintf(fid,'%s','ncols ');
fprintf(fid,' %d\n',nz);
fprintf(fid,'%s','nrows ');
fprintf(fid,' %d\n',mz);
fprintf(fid,'%s','xllcorner ');
fprintf(fid,[dc,'\n'],minX);
fprintf(fid,'%s','yllcorner ');
fprintf(fid,[dc,'\n'],minY);
fprintf(fid,'%s','cellsize ');
fprintf(fid,'%-6.0d\n',dx);
fprintf(fid,'%s','NODATA_value ');
fprintf(fid,'%-5.0d\n',-9999);

This place the numeric values starting in column 15 and removes the trailing zeros from the last two values.

Contact us at files@mathworks.com