Skip to content
Permalink
Browse files

Add external documentation for Rolling Window Reducer.

PiperOrigin-RevId: 283444635
Change-Id: I6a84483ac6c2c5b9d4fee5f0b4c6c3856b99cc6d
  • Loading branch information
timford committed Dec 3, 2019
1 parent b2a3f4e commit 484d6b6861c6ae241ec17a3d2fafe5d0158f46e2
@@ -0,0 +1,28 @@
# Rolling Window Reducer

## Overview

The Rolling Window Reducer is a library that allows you to smoothen
predownsampled data or extract aggregate data from it.

The Reducer works similarly to a rolling average:

1. A window moves from the first point to the last point in your data set with
a step size specified in the `RWRConfig` protobuf.

1. For each step we perform the calculation specified (eg. sum, count or mean)
on all the points within the window.

1. A new `SamplePoint` is created. This `SamplePoint` has an `input_value`
(x-val) as the middle of the window and a `KeyedValue` (y-value) as the
window parameter the user is interested in.

Details of the configurable parameters of the Rolling Window Reducer are
provided in the
[rolling_window_reducer.proto](../proto/helpers/rolling_window_reducer/rolling_window_reducer.proto).

## Example

An example of the use of the Rolling Window Reducer to create a synthetic QPS
metric can be found in the
[Go Quickstore example](../examples/go_quickstore/example_test.go).
@@ -26,7 +26,8 @@
// with an input_value (x-val) as the middle of the window and a KeyedValue
// (y-value) as the window parameter the user is interested in is created.
//
// See go/mako-rwr for more information.
// See https://github.com/google/mako/blob/master/docs/ROLLING_WINDOW_REDUCER.md
// for more information.

syntax = "proto2";

0 comments on commit 484d6b6

Please sign in to comment.
You can’t perform that action at this time.