R growth rate calculation week over week on daily timeseries data
问题 I'm trying to calculate w/w growth rates entirely in R. I could use excel, or preprocess with ruby, but that's not the point. data.frame example date gpv type 1 2013-04-01 12900 back office 2 2013-04-02 16232 back office 3 2013-04-03 10035 back office I want to do this factored by 'type' and I need to wrap up the Date type column into weeks. And then calculate the week over week growth. I think I need to do ddply to group by week - with a custom function that determines if a date is in a