Hi !

I recently started to use the raster package to play with a file that I 
consider fairly big. Since file size is subjective, following is the 
summary output R gives of the data I am working with :

 > wam
class       : RasterLayer
filename    : w001001.adf
nrow        : 14143
ncol        : 11733
ncell       : 165939819
min value   : 0
max value   : 36.3769
projection  : +proj=utm +zone=11 +ellps=GRS80 +datum=NAD83 +units=m 
+no_defs +towgs84=0,0,0
xmin        : 410133
xmax        : 421866
ymin        : 6287971
ymax        : 6302114
xres        : 1
yres        : 1

I would like to aggregate the information of that RasterLayer. I tried 
to use the function aggregate() without any real success. Following is 
the code line I use to perform that procedure and the error message I get:

 > wam<-aggregate(wam, fact=4, fun=mean, expand=FALSE, filename="wam_ag4")

Erreur : impossible d'allouer un vecteur de taille 633.0 Mo (A loose 
translation would be : "Error: allocating a vector of 633.0 Mb in size 
is impossible")
De plus : Messages d'avis :
1: In .local(x, ...) :
   Reached total allocation of 3061Mb: see help(memory.size)
2: In .local(x, ...) :
   Reached total allocation of 3061Mb: see help(memory.size)
3: In .local(x, ...) :
   Reached total allocation of 3061Mb: see help(memory.size)
4: In .local(x, ...) :
   Reached total allocation of 3061Mb: see help(memory.size)

I understood while reading help files and various posting that the 
raster package can handle files larger than the RAM memory of the 
computer. The computer I am using has 3Gb of RAM and the file I want to 
read is only 633 Mb. I suppose there something I am not doing right.

Any help would be much appreciated !

Thank you in advance !

Guillaume Blanchet

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@stat.math.ethz.ch
https://stat.ethz.ch/mailman/listinfo/r-sig-geo

Reply via email to