[R] R + memory of objects

2011-12-02 Thread Marc Jekel
Dear R community, I am still struggling a bit on how R does memory allocation and how to optimize my code to minimize working memory load. Simon (thanks!) and others gave me a hint to use the command gc() to clean up memory which works quite nice but appears to me to be more like a fix to a

Re: [R] R + memory of objects

2011-12-02 Thread Uwe Ligges
I guess the numbers your report are what your OS shows you? R runs garbage collection (which can be manually triggred by gc()) after certain fuzzy rules. So what you report below is not always the current required memory but what was allocated and not yet garbnage collected. See ?object.size