[GRASS-user] Varying results - v.select,v.distance,v.what

Kevin Webb kfw4 at cornell.edu
Wed Nov 19 12:15:09 EST 2008


Good day!

I am executing IDENTITY_ANALYSIS, or point-in-polygon
analysis for a series of points and layers and I am troubled
by the variation in results I am seeing. I am inclined to think it
is something I am doing incorrectly but I haven't found my error.
v.select yields nothing, v.distance yields a non-null answer, and
v.what yields a non-null value that is different from the value
generated by v.distance.


--Workflow--
A LOCATION was created tailored to the specifics of the layer
I am processing. The layer itself was imported using:
v.external, followed by v.category, followed by v.db.connect.

1. v.select workflow:
g.region vect=EXT_CENSUS_CAT
v.proj single_point location=lat_lon mapset=PERMANENT --overwrite
v.db.addtable single_point --q
v.select ainput=EXT_CENSUS_CAT binput=single_point output=single_select 
--overwrite --q
v.db.addtable single_select --q
v.db.select -c single_select --q
/* nothing returned */

2. v.distance workflow:
g.region vect=EXT_CENSUS_CAT
v.proj single_point location=lat_lon mapset=PERMANENT --overwrite
v.db.addtable single_point --q
v.distance -p from=single_point to=EXT_CENSUS_CAT upload=cat column=match
  100%
  100%
from_cat|match
1|114255
v.distance complete.

3. v.what workflow:
g.region vect=EXT_CENSUS_CAT
v.proj single_point location=lat_lon mapset=PERMANENT --overwrite
v.db.addtable single_point --q
v.out.ascii single_point
/* Take output values from v.out.ascii as east_north parameter for v.what */
v.what EXT_CENSUS_CAT east_north=-88.2551479,41.9068764

East: 88:15:18.53244W
North: 41:54:24.75504N

Map: EXT_CENSUS_CAT
Mapset: PERMANENT
Type: Centroid
Id: 231449
Layer: 1
Category: 114263

Am I doing this incorrectly?
Should I expect the three methods to yield the same result?
Which method is suggested to be the most reliable?

Thank you.


KFW





More information about the grass-user mailing list