[SciPy-User] scikits.timeseries: Using convert on hourly and minutely data aggregates forward?

Maarten Smoorenburg meelmaarten@gmail....
Tue Mar 29 10:20:10 CDT 2011


I am very happy with the scikits.timeseries package, but have some issues
when I convert the data from 1 frequency to another if these frequencies are
higher than daily. More exactly: I do not like it that data is aggregated

For example: I have constructed a TimeSeries with Minutely frequency and 1
data point every 10 minutes and all other timestamps masked out. In this
case the data for example at time stamp 09:10 contains measurements between
09:01 and 09:10 that are summed (typical logger data of a rain gauge). If I
know want to compute hourly values from this object, using the convert
function with func=mean, the new TimeSeries object will have stored the
average value observed between 08:50 and 09:49 at time stamp 09:00.

I observed that the same happens if one computes the daily average from
hourly values. I see that this can be very useful, but would not like to use
it as my default procedure though.

I here would need however to have the data average computed over the hour
before 09:00 and after. I can do this of course by shifting the TimeSeries
50 minutes before do the çonvert step, but this is no so convenient and
error prone if one has to deal with many different frequencies of sampling.

So the question is: Is it possible with the scikits.timeseries package to
perform the aggregation function over the 'past' instead of over the

Thanks a lot for the help!

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20110329/ba5e5eff/attachment-0001.html 

More information about the SciPy-User mailing list