raster analysis using real locations? deficiency in mapcalc??

Malcolm Williamson malcolm at cast.uark.edu
Wed Jan 5 11:51:27 EST 1994


Simon Cox writes:
> 
> I want to manipulate a raster map layer where I
> apply a polynomial transformation, in which the
> coefficients of the polynomial are a (simple) function
> of real location.  r.mapcalc only appears to know about
> relative locations (using the neighbourhood operator).
> I can imagine a gruesome technique involving r.stats
> and some awk scripts, but there must be a better way.
> Can anyone make a suggestion?
> 
This may be a wacky idea, but you could create two additional raster map layers,
one containing northings and the others containing eastings:

	612300 612400 612500 612600 612700 ...
	612300 612400 612500 612600 612700 ...
	612300 612400 612500 612600 612700 ...
	612300 612400 612500 612600 612700 ...
	612300 612400 612500 612600 612700 ...

		and

	4173900 4173900 4173900 4173900 4173900 ...
	4173800 4173800 4173800 4173800 4173800 ...
	4173700 4173700 4173700 4173700 4173700 ...
	4173600 4173600 4173600 4173600 4173600 ...
	4173500 4173500 4173500 4173500 4173500 ...

(These would be for a UTM projection with 100 meter resolution.)

These layers could be used to give you absolute coordinates for each cell in
r.mapcalc.

What do you think?

-- 
Malcolm D. Williamson - Research Assistant       E-mail: malcolm at cast.uark.edu
Center for Advanced Spatial Technologies      Telephone: (501) 575-6159
Ozark Rm. 12                                        Fax: (501) 575-3846 
University of Arkansas              
Fayetteville, AR 72701



More information about the grass-user mailing list