ASCII Grid Files

My World can read grid data as text in the ASCII Grid File format. This is the easiest way to import grid data into My World. The file format is shown in figure 29, and an example is given in figure 30.

ncols ncol

/* Number of columns in the grid */

nrows nrow

/* Number of rows in the grid */

xllcorner x

/* Lower left x coordinate of grid */

yllcorner y

/* Lower left y coordinate of grid */

cellsize size

* Grid cell size */

NODATA_value value

/* value of an empty grid cell */

z11 z1,2 z1,3 ... z1,ncols

/* values of row 1 */

z2,1 z2,2 z2,3 ... z2,ncols

/* values of row 2 */

.

 

.

 

.

 

znrows,1 znrows,2 znrows,3 ... znrows,ncols

/* values of last row*/

Figure 29. ASCII Grid File Format.

ncols        128

nrows       136

xllcorner   -42.241

yllcorner   45.154

cellsize      1.125

NODATA_value  -99

1287 1286 1286 1288 ...

288 1288 -99 1289 ...

.

.

1282 -99 1283 1284 ...

Figure 30. Sample ASCII Grid File.