Problem solved, please ignore my previous post: 
g.region's a flag does the job. 

Christoph

On Feb 21, 2011, at 3:40 PM, Christoph Heibl wrote:

> Dear list,
> 
> I am puzzled by a phenomenon in GRASS that I cannot really explain and that 
> spoils some of my downstream applications after preparing my data in GRASS. 
> 
> Problem: 
> 
> I have a set of vector points and some raster layers with environmental data 
> . For each point, the environmental data of the raster cell it lies within 
> has be to be sampled (either with v.what.rast or by the downstream 
> application [Maxent]). So far, so good and no problem. Now imagine only a 
> subset of the vector points is taken to sample the raster data and this is 
> achieved by laying a buffer around this subset of points and then setting the 
> region to this buffer. What happens now is that the vector points are shifted 
> with respect to the raster grid (or vice versa?). This pushes those of my 
> vector points, which lie near the coastline, into the sea and the downstream 
> application skips them, because it cannot link them to environmental data.
> 
> These pictures may clarify the point:
> 
> http://www.christophheibl.de/points1.png: This is the default setting. The 
> three red points represent my set of vector points.
> 
> http://www.christophheibl.de/points2.png: Now only one of the three red 
> points is choosen as a subset and displayed, but without changing the region 
> setting. All points keep their position relative to each other and the raster 
> grid as in points1.png.
> 
> http://www.christophheibl.de/points3.png: The same as in points2.png, but 
> this time a buffer was laid around the red point and this buffer was used to 
> update the region settings. Now, as described above, the vector points are 
> shifted with regard to the raster grid and the whole grid seems to be 
> centered in a way that the red point comes to lie at the corner where four 
> raster cells meet.
> 
> Question:
> 
> 1. Why does this shifting occur? This is somewhat frightening for me, because 
> I thought that the position of the grid would be fixed and given by the 
> projection. 
> 
> 2. How can I can make sure that the relationship between the raster grid and 
> my vector points "stays the same", when I "zoom in" on subsets of the study 
> region?
> 
> Best wishes
> -- Christoph
> 
> ________________________________________________________
> 
> Christoph Heibl
> 
> Systematic Botany
> Ludwig-Maximilians-Universität München
> Menzinger Str. 67
> D-80638 München
> GERMANY
> 
> 
> 
> 
> 
> _______________________________________________
> grass-user mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/grass-user

_______________________________________________
grass-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to