TrendBarRingBuffer based in ideas from CoalescingRingBuffer