[R] Counterpart for Matlab's 'feval'?

2005-06-24 Thread Fredrik Thuring
Hi! I've just begun writing a program that searches for the minimum of a function with golden section search. In order to do this in a nice way I need a function that takes a function name and an argument and returns the function value for that argument, i .e just like Matlab's 'feval'. Is

Re: [R] Counterpart for Matlab's 'feval'?

2005-06-24 Thread Robin Hankin
Hello Fredrik do.call() constructs and executes a function call from the name of the function and a list of arguments to be passed to it. R's equivalent to fminsearch is optim() and that of fmin is optimize() HTH [neither of these are in R-and-octave2.txt, which I really really ought

Re: [R] Counterpart for Matlab's 'feval'?

2005-06-24 Thread Prof Brian Ripley
On Fri, 24 Jun 2005, Fredrik Thuring wrote: I've just begun writing a program that searches for the minimum of a function with golden section search. In order to do this in a nice way I need a function that takes a function name and an argument and returns the function value for that

Re: [R] Counterpart for Matlab's 'feval'?

2005-06-24 Thread Dimitris Rizopoulos
://www.student.kuleuven.ac.be/~m0390867/dimitris.htm - Original Message - From: Fredrik Thuring [EMAIL PROTECTED] To: r-help@stat.math.ethz.ch Sent: Friday, June 24, 2005 11:14 AM Subject: [R] Counterpart for Matlab's 'feval'? Hi! I've just begun writing a program that searches

Re: [R] Counterpart for Matlab's 'feval'?

2005-06-24 Thread Barry Rowlingson
Robin Hankin wrote: I've just begun writing a program that searches for the minimum of a function with golden section search. In order to do this in a nice way I need a function that takes a function name and an argument and returns the function value for that argument, i .e just like