Re: [R] selection of outputs from the function

2010-12-25 Thread ufuk beyaztas
Thanks so much Joshua Wiley you are right your function better than mine :) -- View this message in context: http://r.789695.n4.nabble.com/selection-of-outputs-from-the-function-tp3163361p3163853.html Sent from the R help mailing list archive at Nabble.com. _

Re: [R] selection of outputs from the function

2010-12-24 Thread Joshua Wiley
Hi, Another option is to vectorize your function and have the theta() function return the data frame. On my system, this approach was roughly 10x faster than using your original function + for loop and gave identical results. I also made a few other minor changes to your code to make it easier f

Re: [R] selection of outputs from the function

2010-12-24 Thread ufuk beyaztas
Thank so much David ! -- View this message in context: http://r.789695.n4.nabble.com/selection-of-outputs-from-the-function-tp3163361p3163421.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list https://st

Re: [R] selection of outputs from the function

2010-12-24 Thread David Winsemius
On Dec 24, 2010, at 12:58 PM, David Winsemius wrote: On Dec 24, 2010, at 11:56 AM, ufuk beyaztas wrote: Hi Dear All, This is a function which contains Covariance Ratio and Likelihood Distance values (CVRi, LDi). i want to compute the all row's values, that is run this function for nrow

Re: [R] selection of outputs from the function

2010-12-24 Thread David Winsemius
On Dec 24, 2010, at 11:56 AM, ufuk beyaztas wrote: Hi Dear All, This is a function which contains Covariance Ratio and Likelihood Distance values (CVRi, LDi). i want to compute the all row's values, that is run this function for nrow(X) times. The X and Y matrices are; X<- matrix(c(1125

[R] selection of outputs from the function

2010-12-24 Thread ufuk beyaztas
Hi Dear All, This is a function which contains Covariance Ratio and Likelihood Distance values (CVRi, LDi). i want to compute the all row's values, that is run this function for nrow(X) times. The X and Y matrices are; X<-matrix(c(1125,920,835,1000,1150,990,840,650,640,583,570,570,510,555,460,275