Dear all, I don't get it: First of all, the help doesn't say what are the memory limits of R. Say, what's the max heap size for instance ???? Secondly, I invoke R with the following commands each time: rgui --vsize 30M --nsize 1000K rgui --vsize 30M --nsize 2000K rgui --vsize 30M --nsize 3000K rgui --vsize 30M --nsize 4000K I try to open a matrix 8000x8000 by issuing x<-matrix(nrow=8000,ncol=8000) I always get the following message: Error: heap memory (20480 Kb) exhausted [needed 250000 Kb more] It's always 250000 Kb less. Although gc() reports the memory management as expected (correctly ?), increased every time I invoke R with greater vsize,nsize params. My matrix should hold roughly 1 Meg of memory. Is this correct ? When I issue : rgui --vsize 30M --nsize 5000K R hangs up and have to kill the session. I am using R on a 333 Celeron Pentium PC with 128Megs of memory under windows 98. I don't think I should have a problem there. Hardware seems ok... Would the interpreter normally use the swap disk to create a ramdrive for extra memory needs ? When I use large vsize, nsize params there is an awful lot of disk swapping... This is more obvious on slower pentiums. I'd hate to recompile R to enlarge the heap. Is there another way out of it ? Anything undocumented ? Thanks for your time and attention. Best regards, Costas -- ------------------------------------------------------------------------- Konstantinos E. Vorloou | Tel: +44 (0)191 374 1821 Department of Economics & Finance | Fax: +44 (0)191 374 7289 University of Durham, | email: K.E.Vorloou at durham.ac.uk 23/26 Old Elvet, | or : vorlow at rocketmail.com Durham DH1 3HY, | or : Vorlow at bigfoot.com UK. | Express: 20595534 at pager.mirabilis.com | ICQ number: 20595534 http://www.durham.ac.uk/Economics | http://www.durham.ac.uk/~dec3kev ------------------------------------------------------------------------- -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Konstantinos Euripides Vorloou <K.E.Vorloou at durham.ac.uk> writes:> rgui --vsize 30M --nsize 1000K > rgui --vsize 30M --nsize 2000K > rgui --vsize 30M --nsize 3000K > rgui --vsize 30M --nsize 4000K > > I try to open a matrix 8000x8000 by issuing > > x<-matrix(nrow=8000,ncol=8000) > > I always get the following message: > > Error: heap memory (20480 Kb) exhausted [needed 250000 Kb more]it's --vsize that controls the heap...> It's always 250000 Kb less. Although gc() reports the memory management > as > expected (correctly ?), increased every time I invoke R with greater > vsize,nsize > params. My matrix should hold roughly 1 Meg of memory. > Is this correct ?I get 8000*8000*8 = 512000000 bytes, alias 488Meg... -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
On 27 Apr 1999, Peter Dalgaard BSA wrote:> Konstantinos Euripides Vorloou <K.E.Vorloou at durham.ac.uk> writes:> > I try to open a matrix 8000x8000 by issuing > > > > x<-matrix(nrow=8000,ncol=8000) > > > > params. My matrix should hold roughly 1 Meg of memory. > > Is this correct ?On 27 Apr 1999, Peter Dalgaard BSA wrote:> I get 8000*8000*8 = 512000000 bytes, alias 488Meg...Peter's arithmetic is correct. By default R stores numeric values in double precision (32-bit integers are the other possibility). There are 8000*8000 elements in the matrix, each occupying 8 bytes (the size of a double). This is a very large matrix. R isn't designed to handle problems on this scale (not many interactive systems are). If you really want to try problems of this scale, you'd be better off trying Fortran or C. Ross -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._