Hi Markus,<br>I'm usgin GRASS65 (compiled from source) on an Ubuntu 11.10machine, but I tried with GRASS64 (compiled too) and the result is the same.<br><br>I made an attempt with the NC spm dataset: I took the elevation@PERMANENT map and the streams@PERMANENT (vector), I copied the streams in user1 mapset, set DEBUG at "2" and obtained:<br>
<br>GRASS 6.5.svn (nc_spm_08):~ > v.rast.stats vector=streams@user1 layer=1 raster=elevation@PERMANENT colprefix=stats percentile=90 --verbose<br>D2/2: filename = /usr/local/grass-6.5.svn/scripts/v.rast.stats<br>D2/2: set GIS_FLAG_C=0<br>
D2/2: set GIS_FLAG_E=0<br>D2/2: set GIS_OPT_VECTOR=streams@user1<br>D2/2: set GIS_OPT_LAYER=1<br>D2/2: set GIS_OPT_RASTER=elevation@PERMANENT<br>D2/2: set GIS_OPT_COLPREFIX=stats<br>D2/2: set GIS_OPT_PERCENTILE=90<br>D2/2: G__read_Cell_head<br>
D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>
D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D1/2: Vect_open_old(): name = streams@user1 mapset= user1 update = 0<br>
D1/2: Vect_set_thresh(): thresh = 0.000000<br>D1/2: dig_spidx_init()<br>D1/2: open format file: 'user1/vector/streams/frmt'<br>D1/2: Vector format: 0 (native)<br>D1/2: Vect_set_thresh(): thresh = 0.000000<br>D1/2: Vect__read_head(): vector = streams@user1<br>
D1/2: Vect_set_thresh(): thresh = 0.000000<br>D1/2: Level request = 2<br>D1/2: Vect_open_topo(): name = streams mapset= user1<br>D1/2: get coor info: /home/annalisa/DATAGRASS/nc_spm_08/user1/vector/streams/coor<br>D1/2: Info->size = 2747992, Info->mtime = 1323518807<br>
D2/2: Topo header: file version 5.0 , supported from GRASS version 5.0<br>D2/2: byte order 0<br>D2/2: header size 142<br>D2/2: with_z 0<br>D2/2: coor size 2747992<br>D1/2: Topo head: coor size = 2747992, coor mtime = 140732276991781<br>
D1/2: dig_load_plus()<br>D1/2: dig_spidx_init()<br>D2/2: Topo header: file version 5.0 , supported from GRASS version 5.0<br>D2/2: byte order 0<br>D2/2: header size 142<br>D2/2: with_z 0<br>D2/2: coor size 2747992<br>
D2/2: Vect_cidx_open(): name = streams mapset= user1<br>D1/2: V1_open_old_nat(): name = streams mapset = user1<br>D2/2: Coor header: file version 5.1 , supported from GRASS version 5.1<br>D2/2: byte order 0<br>D2/2: header size 14<br>
D2/2: with_z 0<br>D2/2: coor size 2747992<br>D1/2: get coor info: /home/annalisa/DATAGRASS/nc_spm_08/user1/vector/streams/coor<br>D1/2: Info->size = 2747992, Info->mtime = 1323518807<br>D1/2: coor size in head = 2747992, real coor file size= 2747992<br>
D2/2: dig_file_load ()<br>D2/2: requested mode = 2<br>D2/2: size = 2747992<br>D2/2: file was not loaded to the memory<br>D1/2: Vect_open_old(): vector opened on level 2<br>D1/2: Vect_read_dblinks(): map = streams, mapset = user1<br>
D1/2: dbln file: /home/annalisa/DATAGRASS/nc_spm_08/user1/vector/streams/dbln<br>D1/2: dbln: 1 streams cat $GISDBASE/$LOCATION_NAME/$MAPSET/dbf/ dbf<br>D1/2: field = 1 name = (null), table = streams, key = cat, database = $GISDBASE/$LOCATION_NAME/$MAPSET/dbf/, driver = dbf<br>
D1/2: Dblinks read<br>D1/2: Vect_Rewind(): name = streams<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D1/2: 0 areas sorted<br>D1/2: Vect_close(): name = streams, mapset = user1, format = 0, level = 2<br>
D1/2: close history file<br>D1/2: V1_close_nat(): name = streams mapset= user1<br>D1/2: close streams_3353.0 compressed<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>
D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>ERROR: No categories found in raster map<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>
D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br>D2/2: G__read_Cell_head<br>D2/2: G__read_Cell_head_array<br><br><br>(sorry for long email)<br><br>hope it helpes..<br><br>Thanks, Annalisa<br> <br><br><div class="gmail_quote">
2011/12/9 Markus Neteler <span dir="ltr"><<a href="mailto:neteler@osgeo.org">neteler@osgeo.org</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Annalisa,<br>
<div class="im"><br>
On Fri, Dec 9, 2011 at 6:22 PM, Annalisa Minelli <<a href="mailto:annagrass6@gmail.com">annagrass6@gmail.com</a>> wrote:<br>
> Hi all,<br>
> I'm experiencing some problems with v.rast.stats and (I suppose) v.category.<br>
> I have a lines vector file and I want to obtain some statistics on each<br>
> feature.<br>
> I try to use the module but it soon exits with the message:<br>
><br>
> v.rast.stats vector=ord1_pl_3d_cat raster=dem colprefix=stats percentile=90<br>
> --verbose -c<br>
> ERROR: No categories found in raster map<br>
><br>
> evenif I have some feature (with categories and "cat" column too on<br>
> associated dbf) in my file.<br>
<br>
</div>could you please tell us<br>
- which operating system<br>
- which GRASS version<br>
<div class="im"><br>
> Then I tried r.category by itself and I discovered that sometimes it works<br>
> but sometimes not.<br>
> Align region on input raster map doesn't affect the result.<br>
><br>
> Any hint?<br>
<br>
</div>If possible, please send a North Carolina data set example for easy<br>
replication.<br>
<br>
cheers<br>
<span class="HOEnZb"><font color="#888888">Markus<br>
</font></span></blockquote></div><br>