[GRASS-user] How to write scripts in GRASS
Glynn Clements
glynn at gclements.plus.com
Wed Oct 8 08:29:02 EDT 2008
Christian Schwartze wrote:
> > I´d very grateful if anyone can point any tutorial on how to write scripts
> > in Python to perform routine tasks. I remember to have seen anyone at GRASS
> > web site, but I can´t find it.
>
> http://grass.osgeo.org/wiki/GRASS_and_Python ...maybe your starting point.
That was a bit out of date, so I've replaced it with an actual script
(d.shadedmap) from the current GRASS SVN trunk.
6.4 and 7.0 include a Python module (named "grass") which provides
various utility functions for writing GRASS scripts in Python.
The best available documentation for this module is the code itself
(lib/python/grass.py in 6.4 and 7.0) and the scripts which use it
(scripts/*/*.py, currently only in 7.0). There is also a README file
(lib/python/README.txt).
--
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-user
mailing list