[GRASS-SVN] r59291 - grass/trunk/raster/r.sun

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Mar 22 07:54:42 PDT 2014


Author: annakrat
Date: 2014-03-22 07:54:42 -0700 (Sat, 22 Mar 2014)
New Revision: 59291

Modified:
   grass/trunk/raster/r.sun/r.sun.html
Log:
r.sun manual: how to get day of year using Python

Modified: grass/trunk/raster/r.sun/r.sun.html
===================================================================
--- grass/trunk/raster/r.sun/r.sun.html	2014-03-22 12:31:06 UTC (rev 59290)
+++ grass/trunk/raster/r.sun/r.sun.html	2014-03-22 14:54:42 UTC (rev 59291)
@@ -290,6 +290,12 @@
 d.rast.leg it172
 </pre></div>
 
+We can compute the day of year from a specific date in Python shell:
+<div class="code"><pre>
+>>> import datetime
+>>> datetime.datetime(2014, 6, 21).timetuple().tm_yday
+172
+</pre></div>
 
 <h2>SEE ALSO</h2>
 



More information about the grass-commit mailing list