[GRASS5] bug reports for GRASS 5.7

Radim Blazek blazek at itc.it
Wed Apr 14 10:18:26 EDT 2004


On Monday 05 April 2004 18:01, Michael Barton wrote:
> >> **********************************
> >> s.in.ascii
> >> Actually imports ascii files to vector points (not "sites"). Also, it
> >> ignores any values after the xy(z) dimensions. That is, no attributes
> >> imported. This is not a bug per se, but it seems that a way to input
> >> an
> >> ascii file with xyz dimensions, plus attributes is a good thing to
> >> have. The name should be changed perhaps. (v.points.in.ascii?)
> >
> > s.in/out.ascii modules are there only for tests of sites library which
> > in fact
> > reads/writes vectors. Both s.in/out.ascii will be removed once all
> > modules
> > using sites are rewritten to vectors.
> >
> > I agree that a module which can import ascii points is useful.
> > v.in.ascii output= can import x|y[|z]|cat from stdin.
> > We can add attributes, but tell me how to define column names and
> > types.
> > It could be the part of SQL statement for create table?
>
> Just put them in GRASS 5.7 native dbf format. The original s.in.ascii
> parser could identify integers (cat), floating point numbers
> (dimensions and fp attributes), and strings (or at least it is supposed
> to). Why not do a simple parse into integer, fp numbers, and strings.
> There could be a checkbox (flag) to ask the user if the first line of
> the file represents column names. If unchecked, the column names are
> just called var1, var2,... (or more sophicated, int1, int2...fp1,
> fp2,...strng1, strng2...).
>
> As with the original s.in.ascii, dates will end up as strings. However,
> one can work with the table after the fact once it is in. Of course, it
> could be more clever, do an initial parsing and ask the user to specify
> field types, but I don't know if that is worth the trouble (it requires
> an interactive interface of course).

I have extended v.in.ascii. Now it imports also points' attributes.
Column names and types may be specified by 'columns' option, otherwise 
default names are used. It is also possible to specify x,y,z,cat columns. 

Radim




More information about the grass-dev mailing list