[GRASSLIST:947] Re: Planning swath bathymetry surveys
David Finlayson
david.p.finlayson at gmail.com
Thu Apr 27 18:14:47 EDT 2006
Thanks for your help Hamish.
I'm still learning the ins and outs of vectors and it doesn't always
make sense to read the man pages. I couldn't find a way to dissolve
the areas into a single unit. v.extract -d did the trick!
There was quite a bit of magic in that script you built, though you've
been so deep in GRASS (I suspect) I doubt that you see it.
For the rest of us:
1. v.buffer left us with a borked vector file. Huge, criss-crossing
boundary lines which only defined a few actual areas (that is, only a
few of the enclosed spaces had centroids).
2. You used v.clean tool=break to break the criss-crossing boundary
lines at intersections. There were still no centroids in most of the
enclosed spaces.
3. This is confusing: You then used v.category to add centroids to all
of the potential areas? How did v.category know where the new areas
were?? What happened here? Why is a command called v.category adding
centroids? (Magic #1)
4. Once you've got closed boundaries and a centroid for each enclosed
space, presto these are now areas!? Was this also a bit of v.category
magic? Now v.category turns boundaries + centroid into areas. Maybe
v.category is a bad name for this module (suggest: v.makearea)? (Magic
#2)
5. Now you extract all of the areas with a category = 0 and dissolve
them into a single area using v.extract -d. This is documented, but I
never thought to look at extract to do a dissolve. (Hidden Gem #1)
6. End result: a vector with a single area that represents the total
area of the buffered line above.
Cool, but weird.
David
On 4/27/06, Hamish <hamish_nospam at yahoo.com> wrote:
> > http://david.p.finlayson.googlepages.com/swathwidth
> ..
> > 3) v.db.addtable sends weird messages to the screen:
> >
> > First, it posts an ERROR that the table I am about to create does not
> > exist. Isn't the whole point of v.db.addtable to create a new table??
>
>
> v.db.addtable updated in CVS to make those go away.
> (superfluous test output)
>
> While doing this I found a segfault in v.to.db for layer >1, see
> following report..
>
>
> Hamish
>
--
David Finlayson
More information about the grass-user
mailing list