Re: [R] Aggregate records to 10min

2016-01-17 Thread Fankhauser GEP Data Consulting
Hi Jim, Thanks a lot! It works now. I didn't remember how to access the datetimes in w10min. names(...) is the solution! Rolf Jim Lemon wrote: Hi Rolf, If I get the above, perhaps if you change the names of w10min after applying the calculation: raindata<-data.frame(value=round(runif(60,0,

[R] Aggregate records to 10min

2016-01-16 Thread Rolf Fankhauser
Hi I would like to aggregate a rainfall series with 1min records (timestamp and value of 0.1mm from a tipping bucket raingauge) to 10min values by summing up the values. # ptime is a POSIXlt datetime value with tz="GMT" t10min <- 600*floor(as.integer(as.POSIXct(data$ptime))/600) w10min <- ta