Skip to content
Prev 25780 / 63424 Next

Optimization in R

Hi Pat,
On Sat, Aug 04, 2007 at 09:59:57AM +0100, Patrick Burns wrote:
Thanks :)
On the Rosenbrock function (which is very quick to evaluate), here are the
system.time() results:
[1] 0.148 0.000 0.149 0.000 0.000
[1] 0.008 0.000 0.008 0.000 0.000

and the function evaluation counts:
function gradient 
      95       58
function gradient 
     318      100 

So the overhead is clearly much bigger, but still too small to matter for
most (?) applications.

Cheers,
Andrew

PS, my computer is a "Intel(R) Pentium(R) 4 CPU 2.80GHz" with a
1024 KB cache, according to /proc/cpuinfo.