[R] using matrix data for function
Bing Zhang
bih at ornl.gov
Wed Sep 17 20:02:58 CEST 2003
Hi All,
I have a function, f(x,y)
I have a matrix of data, m, with the 1st column is x and the 2nd column is y
What's the best way to get f(x,y) for each row of the matrix?
I tried
result<-f(m[,1],m[,2]) but it doesn't work.
Thanks!
Bing
---------------------------------
1060 Commerce Park
Oak Ridge National Laboratory
P.O. Box 2008, MS 6480
Oak Ridge, TN 37831-6480
Phone: 865-241-0761
Email: zhangb at ornl.gov
More information about the R-help
mailing list