r.mapcalc

martijn at scanner.frw.uva.nl martijn at scanner.frw.uva.nl
Mon Mar 21 06:29:54 EST 1994


Ah, an interesting problem. Mapcalc can't, as for as I know, write out 
any attribute information (`labels'). So getting a map with zillions of
categories is the only way. Of course, once you know that labels of a map 
are stored in the directory $LOCATION/cats, it shouldn't be too difficult 
to write a script that multiplies the attribute field. The resultant 
changed cats file can then be attached to a copy of the original cell file.

P. Martijn van Leusen

Institute of Prehistory, University of Amsterdam
martijn at scanner.frw.uva.nl


On Fri, 18 Mar 1994, S. E. Walker wrote:

> 
> 	What's the deal with r.mapcalc?  I want to create
> a map with category labels that are a multiple of the 
> category labels in another map.  According to the manual
> I should do the following:
> 
> r.mapcalc> result=@original_map*mult_factor
> 
> What I get from doing this is a map whose category NUMBERS
> (not labels) are multiples of the original cat. labels --
> i.e. I end up with a zillion categories, instead of the
> original number of categories whose values (labels) are changed.
> 
> 
> 	Thanks for any enlightenment!
> 
> Sharyl Walker
> Agricultural Engineering
> University of Illinois
> 



More information about the grass-user mailing list