Skip to content
Prev 127987 / 398500 Next

Newton method iteration problem

On Fri, 26 Oct 2007, Charles C. Berry wrote:

            
Not quite.

I neglected to mention that I added a 'maxIter' variable that terminates 
the while loop after a few dozen passes.

Your loop will not terminate otherwise (unless you are uncommonly lucky).

There are lots of tricks for the unwary in writing optimization software.

So it is best to leave the details to the experts whenever possible.

Fortunately, R has well crafted optimizers available to the user. :-)
Charles C. Berry                            (858) 534-2098
                                             Dept of Family/Preventive Medicine
E mailto:cberry at tajo.ucsd.edu	            UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/  La Jolla, San Diego 92093-0901