[GRASS-user] Re: How to add new columns of number of nodes and length of line vector ?

SGW00412 at nifty.com SGW00412 at nifty.com
Mon Oct 31 07:26:19 EDT 2011


Dear Richard and all

> Yasuo -
> 
> For length:
> v.to.db map=line_db option=length units=k column=length
> 
> This would put the length of the line into the column, in kilometers. If 
> you want some other unit, check v.to.db --help to choose the right 
> parameter.


Thank you for useful adivece!

I also saw grass 6.4 manual and found it.

http://grass.osgeo.org/gdp/html_grass64/v.to.db.html
Upload line lengths (in meters) of each vector line to attribute table (use v.
category in case of missing categories):
v.to.db map=roads option=length type=line col=linelength units=me


> I don't know how to check the node count - someone else may help there.

....please give me some information about it...

Best
Yasuo shimada ( JWA )
---
SGW00412 at nifty.com wrote:
> Hi grass users;
> 
> We traced bird migration by marine radar.
> 
> By using graphic analyze of radar monitor capture on PC, we had  many line 
> vectors of bird flight.
> 
> I would like to add new columns of the number of node and lenght of line 
vector,
> 
> 
> So;
> 
> v.db.addcol line_db columns="num_node int"
> v.db.addcol line_db columns="length double precision"
> 
> After that, to update and fill two columus, what commands do I use ?
> 
> I think...can I use SQL query with spatilite...is it right ?
> 
> Best
> 
> Yasuo shimada ( Japan Weather Association )


More information about the grass-user mailing list