v.reclass - Changes vector category values for an existing vector map according to results of SQL queries or a value in attribute table column.
vector, attribute table
v.reclass input=name output=name [rules=name] [column=name] [type=string[,string,...]] [layer=integer] [--overwrite] [--verbose] [--quiet]
- Allow output files to overwrite existing files
- Verbose module output
- Quiet module output
- Name of input vector map
- Name for output vector map
- Full path to the reclass rule file
- The name of the column whose values are to be used as new categories
- The column must be type integer or string
- Select type
- Options: point,line,boundary,centroid
- Default: point,line,boundary,centroid
- Layer number
- A single vector map can be connected to multiple database tables. This number determines which table to use.
- Default: 1
v.reclass allows user to create a new vector map based on the reclassification
of an existing vector map.
Rules file may contain on each row either pair:
(separated by space) or comment beginning by #(hash).
Definition of new category begins with keyword cat followed by new category value.
Keyword where specifies SQL where condition.
the rules file contains :
v.reclass input=land output=land_u type=boundary rules=land.rcl
Produces a new vector area map land_u containing boundaries from land with area category values selected
from database by SQL select statement:
# land reclass file
where use = 'E13' and owner = 'Jara Cimrman'
where use = 'E14'
select id from tland where use = 'E13' and owner = 'Jara Cimrman' changed to category 1;
values selected from database by SQL select statement:
select id from tland where use = 'E14' changed to category 2.
No table is created for reclassed layer if column option is used and column type is
integer (there is nothing which could be written to the table).
For dissolving common boundaries, see v.dissolve.
No table is created for reclassed layer if rules option is used.
GRASS SQL interface
R.L. Glenn, USDA, SCS, NHQ-CGIS
from v.reclass to v.db.reclass and later to v.reclass in 5.7 rewritten by Radim Blazek
Last changed: $Date: 2008-04-10 07:40:25 -0700 (Thu, 10 Apr 2008) $
Main index - vector index - Full index
© 2003-2008 GRASS Development Team