Something like sliding = function(df, n, f) ldply(1:(nrow(df) - n + 1), function(k) f(df[k:(k + n - 1), ])
I use the following code to summarize my data, grouped by Compound, Replicate and Mass. summaryDataFrame <- ddply(reviewDataFrame, .(Compound, Replicate, Mass),
I am trying to get ddply to run in parallel on my mac.The code I\'ve used is as follows: library(doMC)
I am trying to compile data from several files using for loops in R开发者_C百科. I would like to get all the data into one table. Following calculation is just an example.
I have written a model that I am fitting to data using ML via the mle2 package. However, I have a large data frame of samples and I would like to fit the model to each replicate, and then retrieve all
I recently discovered the data.table package and was now wondering whether or not I should replace some of my plyr-code. To summarize, I really like plyr and I basically achieved everything I wanted.
I have Date/Time information where I want to get the average, min, max, range of the dates across \"seasons\" grouped by years and the only way I have been slightly successful of doing this is with ta
I am using ddply to aggregate my data but haven\'t found an elegant way to assign colum开发者_运维知识库n names to the output data frame.
I often have data where I want to compare the value of one level of variable with all the other levels of variable.Each time I write code to do this I wish it were easier.Here\'s an example of the pro
I use ddply a lot. I use ordered factors occasionally. Calling ddply on a data frame that contains an ordered factor drops any ordering in the recombined data frame.