[GRASSLIST:98] Re: how to load data into d.vect.thematic ?

Philipp H. Mohr phm4 at kent.ac.uk
Tue Mar 14 13:32:29 EST 2006


Hi,

I managed to solve the problem of importing the data with the help from
the IRC chat.
I connected the input vector to a postgre database, which allowed me to
read off the correct column name for the attribute column. d.vect.thematic
still doesn't display anything, but at least I don't get any errors ;-)
I will look into this again tomorrow.

Thank you,
Phil


On Tue, 14 Mar 2006, Philipp H. Mohr wrote:

> Dear Hamish,
>
> thank you for your reply.
>
> > > I have tried to use d.vect.thematic, but I ran into a few problems.
> > > I load my data in with:
> > >
> > >         cat grass.in | v.in.ascii out=mypoints3 x=2 y=1 cat=3
> > >         columns='cat int, x double, y double'
> > >
> > > I can draw the vector mypoints3 without any problems. But when I try
> > > to display this vector with:
> > >
> > >    d.vect.thematic map=mypoints3 type=point column=cat
> > >         themetype=graduated_colors themecalc=interval layer=1
> > >         icon=basic/circle size=5 maxsize=20 nint=4
> > >         colorscheme=blue-red pointcolor=255:0:0 linecolor=0:0:0
> > >         startcolor=255:0:0 endcolor=0:0:255 monitor=x0
> > >
> > > I get the ERROR: No such column [cat].
> > > Could some one please tell me how to read the data in so that it can
> > > be used with d.vect.thematic.
> >
> >
> > v.info -c mypoints3
> >
> >
> > "cat" column there?
>
> No it doesn't seem to be there - which is strange. v.info gives me the
> following output:
>
> v.info map=catTest layer=1
>
> +----------------------------------------------------------------------------+
>  | Layer:    catTest                        Organization:
> |
>  | Mapset:   phm4                           Source Date:
> |
>  | Location: canterburySize                 Name of creator:
> |
>  | Database: /home/phm4/phd/common/grassdata
> |
>  | Title:
> |
>  | Map Scale:  1:1
> |
>  | Map format: native
> |
>
> |----------------------------------------------------------------------------|
>  |   Type of Map:  Vector (level: 2)
> |
>  |
> |
>  |   Number of points:       1073            Number of areas:      0
> |
>  |   Number of lines:        0               Number of islands:    0
> |
>  |   Number of boundaries:   0               Number of faces:      0
> |
>  |   Number of centroids:    0               Number of kernels:    0
> |
>  |
> |
>  |   Map is 3D:              0
> |
>  |   Number of dblinks:      0
> |
>  |
> |
>  |   Projection: Latitude-Longitude (zone 0)
> |
>  |            N: 51.382        S: 51.257
> |
>  |            E: 1.113          W: 0.867
> |
>  |            B: 0.000         T: 0.000
> |
>  |
> |
>  |   Digitize threshold: 0.00000
> |
>  |   Comments:
> |
>  |
> |
>
> +----------------------------------------------------------------------------+
>
>
> The loading in of the data says the 3 columns have been generated:
>
> v.in.ascii
> input=/home/phm4/phd/common/progs/python/memoryStructure/grass.in
> output=catTest format=point fs=| x=2 y=1 z=0 cat=3
> Maximum input row length: 32
> Maximum number of columns: 3
> Minimum number of columns: 3
> Building topology ...
> Registering lines:   1000
> 1073 primitives registered
> Building areas:
>
>
> 0 areas built
> 0 isles built
> Attaching islands:
> Attaching centroids:
>
> Topology was built.
> Number of nodes     :   1072
> Number of primitives:   1073
> Number of points    :   1073
> Number of lines     :   0
> Number of boundaries:   0
> Number of centroids :   0
> Number of areas     :   0
> Number of isles     :   0
>
>
>
> Thank you for your help.
>
> Cheers,
> Phil
>




More information about the grass-user mailing list