Bladeren bron

fix broken script; added NC example

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@48104 15284696-431f-4ddb-bdfa-cd5b030d7da7
Markus Neteler 13 jaren geleden
bovenliggende
commit
39d8f41a9e
2 gewijzigde bestanden met toevoegingen van 9 en 9 verwijderingen
  1. 7 7
      scripts/v.what.vect/v.what.vect.html
  2. 2 2
      scripts/v.what.vect/v.what.vect.py

+ 7 - 7
scripts/v.what.vect/v.what.vect.html

@@ -29,11 +29,11 @@ names from the 'fields' polygon map are transferred to the 'myarchsites'
 map at points' locations:
 
 <div class="code"><pre>
-g.copy vect=archsites,myarchsites
-v.db.addcolumn myarchsites col="owner varchar(25)"
-v.what.vect myarchsites qvect=fields column=owner qcolumn=label
+g.copy vect=hospitals,myhospitals
+v.db.addcolumn myhospitals column="urb_name varchar(25)"
+v.what.vect myhospitals qmap=urbanarea column=urb_name qcolumn=NAME
 # verification:
-v.db.select myarchsites
+v.db.select myhospitals
 </pre></div>
 <P>
 
@@ -48,10 +48,10 @@ beforehand to have metric distances support:
 # extract populated places from geonames
 v.extract geonames_IT where="featurecla='P'" out=geonames_IT_cities
 # add new column 
-v.db.addcol corine_code111_112_cities col="gnameid double precision"
+v.db.addcol corine_code111_112_cities column="gnameid double precision"
 # transfer geonameid (3000m maximal distance between points and centroids)
-v.what.vect corine_code111_112_cities qvect=geonames_IT_cities col=gnameid \
-            qcol=geonameid dmax=3000
+v.what.vect corine_code111_112_cities qmap=geonames_IT_cities column=gnameid \
+            qcolumn=geonameid dmax=3000
 # now gnameid can be used for v.db.join to join further
 # attributes in from Geonames.org
 </pre></div>

+ 2 - 2
scripts/v.what.vect/v.what.vect.py

@@ -55,8 +55,8 @@ from grass.script import core as grass
 def main():
     grass.exec_command(
 	"v.distance",
-	_from = options['vector'],
-	to = options['qvector'],
+	_from = options['map'],
+	to = options['qmap'],
 	column = options['column'],
 	to_column = options['qcolumn'],
 	upload = "to_attr",