[GRASSLIST:5999] Re: sites to raster
Paul Kelly
paul-grass at stjohnspoint.co.uk
Thu Apr 10 04:37:26 EDT 2003
Hello
On Thu, 10 Apr 2003, Stephan Eickschen wrote:
> Hi all,
>
> appr. 600m. I want to convert them to raster data but not do an
> interpolation with s.surf.* or something like that. Preferable is a
> 'drop-in-a-bucket' approach which calculates a mean from all site data
> within every cell. AFAIK s.to.rast uses the last value 'dropping' into
You could try the latest CVS version of s.surf.idw with the npoints option
set to 1. Then if more than one site falls into a cell it will average
them. Assuming there will be some cells with no sites falling into them
and you want them to be null (s.surf.idw will assign the value of the
nearest site) you could use the output of s.to.rast as a mask as it will
have nulls where no sites fell within the cells.
e.g.
g.copy rast=storastoutput,MASK
r.resample input=ssurfidwoutput output=newoutput
g.remove rast=MASK
or something like that. I haven't thought it through fully but it might do
what you're looking for.
Paul
More information about the grass-user
mailing list