← Back to team overview

graphite-dev team mailing list archive

Re: [Question #136529]: Can Graphite bin data points?

 

Question #136529 on Graphite changed:
https://answers.launchpad.net/graphite/+question/136529

    Status: Open => Answered

chrismd proposed the following answer:
Yup. In fact I just added this feature about 3 weeks ago for our sales
monitoring and it works very nicely.

There is a new function called summarize() that works as follows.

summarize(path.to.my.metric,"15min")

This will 'bin' the metric into 15-minute periods. You could do "1h" for
hourly periods, '1d' for daily, etc...

This is only in trunk right now but it will be in the next release which
I'm going to put out before the new year.

One important caveat to explain some weird looking (but technically
correct) behavior of this function is that the most recent 'bin' will
start to grow from zero on up as time goes on and the oldest bin will
shrink down to zero as well. This is because only the datapoints covered
by the requested time range of the graph will get put into the bins and
so the first & last generally only cover partial intervals (assuming
you're time range is relative, this would not be an issue if you're
using an absolute time range).

-- 
You received this question notification because you are a member of
graphite-dev, which is an answer contact for Graphite.