Skip to content
Prev 316844 / 398506 Next

Rprof causing R to crash

Hi Jim,
Sorry - it just "stops" as per the message posted. The text is from eclipse.
Shouldn't be. 400MB shouldn't be a problem on a 4GB machine? 

Just tried this with no problem on 2.15.0 on "Platform:
x86_64-redhat-linux-gnu (64-bit)", so it looks to be particular to my setup
on the mac. I also just tried 2.15.2 on the mac using the GUI and  _not_
eclipse, It worked with no problem.

Therefore, it seems that my issues are specific to R 2.15.2 (and R 2.14.0
prior to upgrade) running via StatEt's rj package (with no additional
arguments.) I have a workaround now, and I guess this is no longer an issue
for the wider group. Will post a link to the StatEt group.

cheers

Steven


Now you could restructure your code to not allocate the large vector by:

Rprof()
z <- 1
i <- 0
system.time(while((i <- i + 1) < 1e8) z <- z + 1/i)
z
Rprof(NULL)

Yes - the example is not related to my code, its just a way of recreating a
similar error. I haven't posted my code that causes the error.

Is there a reason that 400 MB should be a problem for RProf? My previous
experience is that Rprof is stable with processes with much larger memory
footprints. Hence why I think the for loop error might be related to the
problems I'm having.

Is there an alternative to Rprof? This is fairly crucial for me right now.
Will try to get setup on 

cheers

Steven
On Mon, Feb 4, 2013 at 7:48 AM, c97sr &lt;sr@&gt; wrote: