[GRASS-user] Problem exporing rasters

Richard Feldman richard.feldman at mail.mcgill.ca
Tue Jun 16 19:57:53 EDT 2009


I have two rasters. One is an elevation dataset from Worldclim, imported into GRASS using r.in.bin. The other is a MODIS raster, which I had previously worked on in ArcGIS. Consequently, I imported this raster (.adf) into GRASS using r.in.gdal. Both rasters display and manipulate properly in GRASS. I used r.mapcalc to mask the raster

newelevation=if(studyarea at mapset, elevation at mapset)

and wished to export this new raster as an ascii grid. When using either r.out.gdal or r.out.arc, the exported file is only 1KB and does not contain any data e.g. elevations). (Again, this new raster displays fine in GRASS). With r.out.gdal, I have tried both .grd and .tif formats as well as “byte,” “int16,” “uint16” and “int32” file types. Every time the export takes 0 sec and produces a 1-2KB file.

I have tried exporting elevation.dem from the spearfish dataset and it exports fine. I'm using GRASS6-SVN on Windows Vista.

What am I doing wrong?

Richard Feldman

More information about the grass-user mailing list