Skip to content
Prev 277829 / 398506 Next

Apply functions along "layers" of a data matrix

On 11/18/2011 01:05 PM, saschaview at gmail.com wrote:
Hi,

This seems like a job for plyr!

library(plyr)
ddply(daf, .(rep), summarise, mn = mean(v1))

hope this helps,
Paul