Not quite sure what you are aiming at, but looking at ?mapply or ?expand.grid 
could be helpful

        Benno

On Jul 20, 2012, at 1:05 PM, carla moreira wrote:

> 
> Hi,
> 
> I would like to evaluate a function, with 3 arguments, for instance, 
> 
> myfunc<-function(a,b,c) { sqrt(a)-exp(b)+4*c
>                                                }
> 
> How to execute  myfunc(x,y,z), for all x, all y and all z, where x,y,z are
> vectors?
> 
> Thank you very much in advance
> 
> 
> 
> --
> View this message in context: 
> http://r.789695.n4.nabble.com/Execute-a-function-tp4637182.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
> 

Benno Pütz
Statistical Genetics
MPI of Psychiatry
Kraepelinstr. 2-10
80804 Munich, Germany
T: ++49-(0)89-306 22 222
F: ++49-(0)89-306 22 601




        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to