Re: [R] zoo:rollapply by multiple grouping factors

2011-04-04 Thread Mark Novak
Thank you very much Gabor! It looks like that's gonna work wonderfully. I didn't even know 'ave' existed. For others out there: I only needed to add a comma: dat[,c("Site", "Plot", "Sp")] Small follow up Q: Is there any reason to use 'aggregate' vs. 'ave' in general? -mark On 4/3/1

Re: [R] zoo:rollapply by multiple grouping factors

2011-04-04 Thread Gabor Grothendieck
On Mon, Apr 4, 2011 at 3:40 PM, Mark Novak wrote: > Thank you very much Gabor!  It looks like that's gonna work wonderfully.  I > didn't even know 'ave' existed. > > For others out there:  I only needed to add a comma:   dat[,c("Site", > "Plot", "Sp")] Actually, if dd is a data frame dd[, ix] and

Re: [R] zoo:rollapply by multiple grouping factors

2011-04-03 Thread Gabor Grothendieck
On Sun, Apr 3, 2011 at 11:58 AM, Mark Novak wrote: > # Hi there, > # I am trying to apply a function over a moving-window for a large number of > multivariate time-series that are grouped in a nested set of factors.  I > have spent a few days searching for solutions with no luck, so any > suggesti

[R] zoo:rollapply by multiple grouping factors

2011-04-03 Thread Mark Novak
# Hi there, # I am trying to apply a function over a moving-window for a large number of multivariate time-series that are grouped in a nested set of factors. I have spent a few days searching for solutions with no luck, so any suggestions are much appreciated. # The data I have are for the