Skip to content

properly using function aggregate(raster)

3 messages · Guillaume Blanchet, Robert J. Hijmans

#
Dear Guillaume,

This probably happened because the aggregate function tests if the
output raster can be stored in memory. This is a mistake as it should
do the test for the input raster (which is, in this case, 16 times
larger). I have just fixed that. For now, you can use this (otherwise
*not* recommended (or necessary), as it slows things down) option, to
force processing the file in chunks :

setOptions(todisk=TRUE)
wam<-aggregate(wam, fact=4, fun=mean, expand=FALSE,
filename="wam_ag4", progress='tcltk')
setOptions(todisk=FALSE)

Robert

On Mon, May 17, 2010 at 10:15 AM, Guillaume Blanchet
<gblanchet.list at gmail.com> wrote:
#
Dear Robert !

Thank you very much for your quick answer !

I just ran the bits of code you gave me and it worked perfectly !

Have a good day !

Guillaume

Le 10-05-17 11:50, Robert J. Hijmans a ?crit :