[GRASS-dev] what does zoom= do?

Michael Barton michael.barton at asu.edu
Sun Jan 27 23:45:35 EST 2008


On Jan 27, 2008, at 9:07 PM, grass-dev-request at lists.osgeo.org wrote:

>
> Now what does 'g.region align=' do?
>
>
>
> Hamish

This one I can answer. When you zoom, g.region has to maintain an  
integer number of rows and columns. Without -a, it will find the  
nearest integer for the rows and columns given the extents and  
resolution specified. Then it will slightly adjust the resolution so  
that the specified extents are exactly divisible by the calculated  
integer number or rows and columns.

With -a, g.region will slightly adjust the extents (instead of the  
resolution) to come up with an integer number or rows and columns as  
close as possible to the selected extents while exactly maintaining  
the specified resolution.

Try it by running g.region -ugp after setting a region to specified  
extents and resolution with and without -a. Without -a, the  
resolution will differ slightly from those specified, but the extents  
will exactly match those specified. With -a, the resolution will  
exactly match and the extents will differ slightly.

However, -a is ignored if the resolution is not specified. I asked  
that in circumstances where resolution is not specified and -a is  
used, g.region align to the current resolution, whatever it is.

Michael

____________________
C. Michael Barton, Professor of Anthropology
Director of Graduate Studies
School of Human Evolution & Social Change
Center for Social Dynamics & Complexity
Arizona State University

Phone: 480-965-6262
Fax: 480-965-7671
www: <www.public.asu.edu/~cmbarton>



More information about the grass-dev mailing list