[GRASSLIST:4703] Re: v.in.ascii and dig_cats file

David Orme d.orme at imperial.ac.uk
Tue Nov 2 06:46:00 EST 2004


Thanks Radim - just as a follow up question on v.in.ascii - is the
dig_att file used? I followed up the v.in.ascii with 'v.category
op=print' and got a list of -1 values. Does this mean that neither
dig_vats nor dig_att is used?

In which case, just to check, the correct use of v.in.ascii in grass 5.7
should be something like:

v.in.ascii EBCC_Grid output=EBCC_Grid
v.category EBCC_Grid output=EBCC_Grid_C op=add
db.execute # to create attribute table
v.db.connect # to link the geometry in to the attributes

Thanks,
David


On Tue, 2004-11-02 at 09:25, Radim Blazek wrote:
> dig_cats are ignored by v.in.ascii, you have to create 
> db table directly and link it to vector:
>  db.execute (create table ..., insert into ....)
>  v.db.connect
> 
> Radim
> 
> On Monday 01 November 2004 19:14, David Orme wrote:
> > Hi,
> >
> > I'm trying to create a vector file through v.in.ascii, following the
> > template files in Example 1 from the v.in.ascii manual page:
> >
> > http://grass.itc.it/grass57/manuals/html57_user/v.in.ascii.html
> >
> > How does the category input from dig_cats work? There was a similar
> > thread last week started by Ian MacMillan but I didn't see a solution to
> > getting a dig_cats file working. I've appended head output for the
> > ascii, att and cats files that I have created, in case there is problem
> > there.
> >
> > (Recent build of Grass 5.7 running on RHEL 3).
> >
> > Many thanks,
> >
> > David
> >
> >
> > [dorme at diomedea dorme]$ head -n 20 dig_ascii/EBCC_Grid
> > ORGANIZATION: ADHoC
> > DIGIT DATE:   26/10/2004
> > DIGIT NAME:   -
> > MAP NAME:     EBCC_Grid
> > MAP DATE:     2004
> > MAP SCALE:    50000
> > OTHER INFO:   Test polygons
> > ZONE:         0
> > MAP THRESH:   0.500000
> > VERTI:
> > A 7
> >  3000000 202512
> >  3000000 250000
> >  3000000 300000
> >  3050000 300000
> >  3050000 250000
> >  3050000 203715
> >  3000000 202512
> > A 5
> >  3000000 300000
> > [dorme at diomedea dorme]$ head -n 20 dig_att/EBCC_Grid
> > A 250000 3025000 1
> > A 3e+05 3025000 2
> > A 350000 3025000 3
> > A 4e+05 3025000 4
> > A 450000 3025000 5
> > A 5e+05 3025000 6
> > A 550000 3025000 7
> > A 6e+05 3025000 8
> > A 650000 3025000 9
> > A 7e+05 3025000 10
> > A 250000 3075000 11
> > A 3e+05 3075000 12
> > A 350000 3075000 13
> > A 4e+05 3075000 14
> > A 450000 3075000 15
> > A 5e+05 3075000 16
> > A 550000 3075000 17
> > A 6e+05 3075000 18
> > A 650000 3075000 19
> > A 7e+05 3075000 20
> > [dorme at diomedea dorme]$ head -n 20 dig_cats/EBCC_Grid
> > # 904 categories
> > Vector map: EBCC_Grid
> >
> > 0.00 0.00 0.00 0.00
> > 1:31SBL4
> > 2:31SCL2
> > 3:31SCL4
> > 4:31SDL2
> > 5:31SDL4
> > 6:31SEL2
> > 7:31SEL4
> > 8:31SFL2
> > 9:31SFL4
> > 10:31SGL2
> > 11:31SBL3
> > 12:31SCL1
> > 13:31SCL3
> > 14:31SDL1
> > 15:31SDL3
> > 16:31SEL1




More information about the grass-user mailing list