Re: [GRASS-user] speeding up context evaluation...

2008-12-02 Thread Glynn Clements
Hufkens Koen wrote: > for a validation exercise I need to extract the class values around certain > pixel location. > > I have a map with all the locations (numbered) and a map with the validation > map. > > The code you find below is the one I came up with to get this information > (only ou

Re: [GRASS-user] speeding up context evaluation...

2008-12-02 Thread Maris Nartiss
Sorry, I was not reading carefully Your code snippet, but can't You just use mapcalc's ability to access neighborhood pixel values (see "THE NEIGHBORHOOD MODIFIER" in help page). Like output=if(location[-1,-1],validation,null()) || etc... It may eliminate need to create buffer, mask etc. still if i

[GRASS-user] speeding up context evaluation...

2008-12-02 Thread Hufkens Koen
Hi list, for a validation exercise I need to extract the class values around certain pixel location. I have a map with all the locations (numbered) and a map with the validation map. The code you find below is the one I came up with to get this information (only output to terminal for the mo