[GRASS-user] r.in.mat - How can I specify a No Data Value?

Tom Russo russo at bogodyn.org
Tue Mar 11 13:35:07 EDT 2008


On Tue, Mar 11, 2008 at 06:36:22PM +0100, we recorded a bogon-computron collision of the <dobmeier at muc.zae-bayern.de> flavor, containing:
> Hello everyone,
> 
> i'd like to export an elevation raster from Octave to Grass.
> >From my available data, I can't provide a height value for every cell,
> so I need to use a No Data value here.
> The import of the .mat file works fine, as described in the manuals.
> Only the No Data Value (set to -9999 in Octave) isn't interpreted
> correctly, and that gives me an artificial "Mariana Trench" around my
> defined area ;)
> 
> Where can I set the No Data value to be used? Can I define it for a
> specific raster map? A standard value for the whole mapset? Or do I have
> to use a special value in Octave/Matlab in the first place?

I think you're looking for the GRASS program "r.null" and its "setnull"
option.  That will designate pixels of a specified value as being NULL
instead of valid numbers.

r.null map=mymap setnull=-9999

-- 
Tom Russo    KM5VY   SAR502   DM64ux          http://www.swcp.com/~russo/
Tijeras, NM  QRPL#1592 K2#398  SOC#236 AHTB#1 http://kevan.org/brain.cgi?DDTNM
"And, isn't sanity really just a one-trick pony anyway? I mean all you get is
 one trick, rational thinking, but when you're good and crazy, oooh, oooh,
 oooh, the sky is the limit!"  --- The Tick


More information about the grass-user mailing list