[GRASS-user] raster analysis sectorwise as in a pie chart

Markus Neteler neteler at osgeo.org
Wed Jan 28 05:39:11 EST 2009


On Wed, Jan 28, 2009 at 10:40 AM, Otto Dassau <otto.dassau at gmx.de> wrote:
> On Tue, 27 Jan 2009 15:46:02 -0800 (PST)
> Hamish <hamish_b at yahoo.com> wrote:
>
>> Otto Dassau wrote:
>> > I would like to analyse elevation data (slope, aspect, etc) around a
>> > point with a defined radius. For my analysis I would like to devide
>> > that circle into several sectors 1,5,10,x degree steps, like a pie.
>> >
>> > Is that possible in GRASS? Are there people who did
>> > something similar? Any hints and ideas are welcome.
>>
>> r.reclass into range bands, then
>> d.histogram style=pie   (perhaps rendered into a corner sub- d.frame)
>> or somehow into a vector DB + 'd.vect.chart ctype=pie'
>
> thanks for your suggestion, but maybe my description was not very clear. I would
> like to split data into spatial sectors and then start my analysis. E.g.:
>
> a) Create a 1km buffer around a coordinate
> b) Split this circle into sections (subareas) with a certain degree value. If I
> choose 1 degree the circle would be devided into 360 subareas
> c) Do my analysis in each sector
>
> I am thinking about a solution for b)

With v.buffer you can create a circle. Then with a bit of geometry [1] you
can calculate the angles and more (perhaps implement in a shell/python
script) and then generate the lines and centroids with v.edit.
Finally rebuild the topology to obtain sector areas (v.build).

Hope this helps,
Markus

[1] essentially, radius of circle, angle, school geometry :)


More information about the grass-user mailing list