"rowMeans" also works. Alternatives can be timed using "proc.time".

Spencer Graves

[EMAIL PROTECTED] wrote:
Ghosh Mini <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>>

 > Is it possible to find the mean of some rows (of some table) and
 > to put it in new table.

Maybe you want something like this:

apply(mydata[, c("x", "y", "z")], 2, function(x){tapply(x, list(mydata$date), mean, na.rm=TRUE)})

hope this helps,

Chuck Cleland





------------------------------------------------------------------------


______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help

______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to