Re: [R] Passing function arguments to dataset names

2011-05-23 Thread MatAra
Janko, Thanks a lot for your reply. Option 2 is exactly what I was looking for. Mil gracias! Mateo -- View this message in context: http://r.789695.n4.nabble.com/Passing-function-arguments-to-dataset-names-tp3545567p3545741.html Sent from the R help mailing list archive at Nabble.com.

Re: [R] Passing function arguments to dataset names

2011-05-23 Thread Janko Thyson
Hi Mateo, not sure if I totally get what you're after, but maybe this helps: SharpeRatio.annualized <- function(roc){ print("I'm computing the Sharpe Ratio") return() } MyF <- function(Tic, price){ print("Option 1") expr <- expression(Ratio.Tic <- SharpeRatio.annualized(ro

[R] Passing function arguments to dataset names

2011-05-23 Thread MatAra
Hello, I am stuck in a relatively simple procedure and was wondering if anybody knows the answer. I am a relatively new R user. How do I use an argument of a custom function in the name of a dataset in R? For example, I have the function: MyF <- function(Tic, price){ x

Re: [R] Passing function arguments

2011-02-11 Thread David Winsemius
On Feb 11, 2011, at 6:14 AM, Michael Pearmain wrote: Hi All, Im looking for some help passing function arguments and referencing them, I've made a replica, less complicated function to show my problem, and how i've made a work around for this. However i suspect there is a _FAR_ better w

[R] Passing function arguments

2011-02-11 Thread Michael Pearmain
Hi All, Im looking for some help passing function arguments and referencing them, I've made a replica, less complicated function to show my problem, and how i've made a work around for this. However i suspect there is a _FAR_ better way of doing this. If i do: BuildDecayModel <- function(x = "thi