2012-01-14

grass gis batch interpolation and statistics

This post continues the previous one. Using two loops I created a raster files for each month and made a text file with basic statistics about these raster files in it.

here`s the code - http://pastebin.com/RtXuaQKS

I was using "boolean" switches because if the script grows larger, sometimes it is unnecessary to do things multiple times. Such switches eliminates running unwanted code (yeah, commenting also works, but.. i hate commenting blocks).

In this example the challenge was to correctly make heading-monthName when statistics were generated. Using awk the month name was passed as a command line argument and written in the appending file before statistics were written.

Nav komentāru:

Ierakstīt komentāru