GIS to GRASS command translation
Translation Quick Reference Table
GIS Software/Module | GIS command/feature | GRASS command(s) | Discrepancies* |
---|---|---|---|
ESRI ARC-INFO (GRID) | GRID operators | r.mapcalc | |
ESRI ARC-INFO (ARC) | LATTICESPOT | v.what.rast | Major |
Notes on discrepancies
Clever GRASS users should be able to perfectly replicate commands from other software packages, either through coding or by adding new lines to the GRASS translation commands listed below. Over time, discrepancies listed below should not exist as new ideas/code are added, but until then we rank the degree of discrepancy as follows:
- None: GRASS command(s) in the Translation Discussion should perfectly replicate the output of the GIS software command/feature.
- Minor: GRASS command(s) in the Translation Discussion should perfectly replicate the output of the GIS software command/feature with minor database/mapcalc post-processing of the outputs, or GRASS command(s) listed do not cover all possible options available from the GIS software/feature.
- Major: While basic functionality is analagous between the GIS software and GRASS commands listed, significant algorithmic differences exit that will result in different outputs.
- Missing: The GIS software has a feature that is essentially missing/nonexistant in GRASS GIS.
Translation Discussion
ESRI ARC-INFO
GRID operators
GIS command/feature | GRASS command(s) |
---|---|
<outfile>=<infile1><operator><infile2> | r.mapcalc <outfile>="<infile1>"<operator>"<infile2>" |
r.mapcalc and GRID operations are similar in how they are both called. Symbols used for operators, however, do differ in certain cases between GRID and GRASS:
GRID operator | Description of operator | Precendence | r.mapcalc operator |
---|---|---|---|
Arithmetic: | |||
- | unary minus | 12 | |
mod | modulus | 11 | % |
* | multiplication | 11 | * |
/ | division | 11 | / |
div | floating point division | 11 | / |
+ | addition | 10 | + |
- | subtracts | 10 | - |
LATTICESPOT
GIS command/feature | GRASS command(s) |
---|---|
LATTICESPOT <in_lattice> <in_cover> {spot_item} {z_factor} | v.what.rast vector=<in_cover> raster=<in_lattice> layer=layer column={spot_item} |
Discrepancies:
- Minor:
- {spot_item} defaults to "SPOT" for LATTICESPOT, but must be explicitly defined for v.what.rast.
- {z_factor} must be applied to the GRASS vector database after-the-fact.
- Major:
- LATTICESPOT performs a bilinear interpolation to assign raster values to the output vector, whereas v.what.rast uses nearest neighbor.