[GRASS-dev] Re: [GRASS GIS] #1109: g.mlist functionality extension:
return e.g. $prefix.001 to $prefix.031 out of $prefix.365 maps
GRASS GIS
trac at osgeo.org
Tue Jul 20 19:58:37 EDT 2010
#1109: g.mlist functionality extension: return e.g. $prefix.001 to $prefix.031 out
of $prefix.365 maps
-------------------------------+--------------------------------------------
Reporter: nikos | Owner: grass-dev@…
Type: enhancement | Status: new
Priority: minor | Milestone:
Component: default | Version: unspecified
Keywords: g.mlist, pattern, | Platform: Unspecified
Cpu: Unspecified |
-------------------------------+--------------------------------------------
Comment(by nikos):
Replying to [comment:6 hamish]:
> as long as it works and is understandable by you, I wouldn't be too
concerned with how elegant the outer loops are. that's not the
computationally expensive part.
I think I understand it (+have the illusion that I am 100% sure I know
what I am doing :-p)
> if your map names are longer than ~10 chars in total, beware that the
maximum command line length may be 4096 chars on some OSs. so eg it may be
better to sum months to get the full year instead of summing up 365 maps
directly.
Actually that is what the script is doing: it creates a list with the days
of jan, feb, march, etc., which is then fed as an input to "r.series
method=average".
The results (per month mean, units as derived from r.sun) over a study
area in Greece seem rational to me (e.g. r.info for january:
min=535.582112958354, max=5788.08932396673 and for july:
min=1695.6559625441, max=8480.92313508065).
> (although if you can it might be interesting to compare results of doing
it both ways, in the past I'd gotten two slightly different answers by
doing that which confused me)
That is strange. It's only summing and dividing, right? No time currently
(=added in ToDo list).
(I still consider the enhancement wish valid, especially when working with
(r.)series which follow a naming pattern)
Nikos
--
Ticket URL: <https://trac.osgeo.org/grass/ticket/1109#comment:8>
GRASS GIS <http://grass.osgeo.org>
More information about the grass-dev
mailing list