The input coordinates can be entered directly on the command line, or redirected via stdin from an input text file, script, or piped from another program (like d.where).
If none of the above input methods are used and the module is run from the terminal prompt, the program will interactively query the user for point locations and labels.
Each line of the input consists of an easting, a northing, and an optional label, which are separated by spaces. In interactive mode, the word "end" must be typed after the last pair of input coordinates.
r.what output consists of the input geographic location and label, and, for each user-named raster map layer, the category value, and (if the -f label flag is specified) the category label associated with the cell(s) at this geographic location.
r.what input=soils,aspect << EOF 635342.21 7654321.09 site 1 653324.88 7563412.42 site 2 EOF 635342.21|7654321.09|site 1|45|21 653324.88|7563412.42|site 2|44|20
echo "635342.21 7654321.09" | r.what input=soils,aspect 635342.21|7654321.09|45|21
r.what input=soils,aspect < input_coord.txt 635342.21|7654321.09|site 1|45|21 653324.88|7563412.42|site 2|44|20
r.what input=soils,aspect east_north=635342.21,7654321.09,653324.88,7563412.42 635342.21|7654321.09|45|21 653324.88|7563412.42|44|20
d.where | r.what input=soils,aspect 635342.21|7654321.09|45|21 653324.88|7563412.42|44|20
v.out.ascii bugsites fs=' ' | r.what input=soils,aspect
r.what -f input=soils,aspect << EOF 635342.21 7654321.09 site 1 653324.88 7563412.42 site 2 EOF 635342.21|7654321.09|site 1|45|NaC|21|30 degrees NW 653324.88|7563412.42|site 2|44|NdC|20|15 degrees NW
Last changed: $Date: 2010-09-16 09:25:59 +0200 (Thu, 16 Sep 2010) $
Main index - raster index - Full index
© 2003-2011 GRASS Development Team