[GRASS-user] raster analysis: hot to get one <elevation raster> from two elevation rasters?

Daniel Victoria daniel.victoria at gmail.com
Tue May 27 08:23:50 EDT 2008


If you are getting the output map with the same configuration as the
buildings, could it be that the places where there are no buildings
you have NULL values? So, when you add the maps NULL + anything = NULL

Try changing the nulls to zero in the buildings map (r.null is your
friend) and the add the maps.

Daniel

On Tue, May 27, 2008 at 9:14 AM, Nikos Alexandris
<nikos.alexandris at felis.uni-freiburg.de> wrote:
> On Tue, 2008-05-27 at 12:05 +0000, christian Brandt wrote:
>> What I want to do is to get just one <elevation-raster> with combined
>> elevation data from DGM raster and buildings raster
>>
>> Hence I tried the r.mapcalculator as follows:
>> r.mapcalculator amap=dgm bmap=geb formula=A+B outfile=dgm_geb
>
> Dear Christian,
>
> r.mapcalc or r.mapcalculator should work.
>
>
> Just some ideas (which you might have tested already, but anyway... ):
>
> 1. check the range of your "dgm" and "geb" data to be sure that both
> have "valid" values
>
> r.info -r dgm
> r.info -r geb
>
> (or use r.describe to list all values contained in your maps)
>
> 2. check the computational extent in you LOCATION:
>
> g.region -p
>
> or why not set directly to match the extent of one of your maps:
>
> g.region rast=dgm
>
>
> Nikos
>
>


More information about the grass-user mailing list