rcrowley/go-metrics — pull request #99 by Dieterbe (2014-11-21 00:04:05+00:00)
Title: add windowsample

a very simple sampler, just retains all data since the last snapshot. the more data between snapshots, the more data it needs to process.
don't run multiple independent reporters that take independent snapshots or you'll get unexpected results, as documented.

with those caveats in mind, it seems to work fine for me.
we might want to address those issues later though. i just needed to get something working for use case #10
we could also implement the sliding window variant of the forward decay filter, but that was a bit over my head for now.