[GRASS-SVN] r67547 - grass/trunk/lib/python/docs/src
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Jan 11 02:33:52 PST 2016
Author: lucadelu
Date: 2016-01-11 02:33:52 -0800 (Mon, 11 Jan 2016)
New Revision: 67547
Modified:
grass/trunk/lib/python/docs/src/pygrass_raster.rst
Log:
pygrass: updated documentation
Modified: grass/trunk/lib/python/docs/src/pygrass_raster.rst
===================================================================
--- grass/trunk/lib/python/docs/src/pygrass_raster.rst 2016-01-11 10:19:04 UTC (rev 67546)
+++ grass/trunk/lib/python/docs/src/pygrass_raster.rst 2016-01-11 10:33:52 UTC (rev 67547)
@@ -161,8 +161,8 @@
[ 144.99488831 145.22894287 145.57142639]
>>> new = raster.RasterSegment('new')
>>> new.open('w', 'CELL')
- >>> for irow in xrange(elev.rows):
- ... new[irow] = elev[irow] < 144
+ >>> for irow, row in enumerate(elev):
+ ... new[irow] = row < 144
...
>>> for row in new[:5]: print(row[:3])
[1 1 1]
More information about the grass-commit
mailing list