[GRASS-user] problem with v.edit tool=merge

Martin Landa landa.martin at gmail.com
Thu Mar 29 03:32:38 EDT 2007


Hi Jarek,

2007/3/29, Jarek Jasiewicz <jarekj at amu.edu.pl>:

> >> - it sometimes work, but new line has two categories on one layer, it is
> >> corrected? IMHO it is not the best solution
> >
> > sometimes?;-)
> I made several test on that file some lines have merged, but I can't say
> why that ones

Could be possible to send *exact command* you typed? For fixing a bug
there is need to *reproduce* (wrong) behaviour of module.

> >
> > yes, it is not the best solution, but I am not sure what the user
> > would expect, what do you thing? Merging two lines (layer 1) described
> > bellow:
> >
> > +-----1/1-----+------1/2-----+
> >
> > we get new line
> >
> > +------1/?------+
> >
> > I think that the vector layer should not be changed (i.e. still layer 1).
> >
> > Currently this line gets category 1 and 2.
>
> I think that tool is suitable to work on fresh vector (for example after
> r.to.vect) without atributies it will rather be a part of the sript than
> stand-alone tool,
> maybe other grass-user will help which solution will be the best

At least I will add a warning about that (merging lines with different
categories).

> >> - I did not reproduced merge in file i send. It has only worked when i
> >> used cat=1-99999 (i.e only 2 or three lines has been merged)
> >> - but if i used cat 1-99 it hasen't worked, no line has been merged
> >
> > I am not sure if I understand well, using your testing data
> > cat=1-99999 and cat=1-99 works OK.
> no, in that situation cat=1-99 gave negative result (no lines merged)
> but cat=1-99999 merged two or three lines

Using your data:

g.copy vect=linie,linie1 ; v.edit linie1 tool=merge cat=1-99
Copy vector <linie at temp> to current mapset as <linie1>
WARNING: The vector 'linie1' already exists and will be overwritten.
[11] of [11] features selected
Editing: [3] lines merged

 g.copy vect=linie,linie1 ; v.edit linie1 tool=merge cat=1-99999
Copy vector <linie at temp> to current mapset as <linie1>
WARNING: The vector 'linie1' already exists and will be overwritten.
[11] of [11] features selected
Editing: [3] lines merged

-> Result is the same.

So I cannot reproduce this problem.

> >> - there is no problem with merging if there are only two lines in map
> if I prepared few vector with only two lines the result was OK
> >> - if two lines has been merged and line with cat=1/2 has been created,
>
> in some situations in file where were more than two lines with huge
> threshold first two lines, but no more lines can be merged again

I disabled threshold for merging lines.

Martin

> Jarek
>


-- 
Martin Landa <landa.martin at gmail.com> * http://gama.fsv.cvut.cz/~landa *




More information about the grass-user mailing list