Pivot Grid examples

This example shows how to create several PivotGrids using the same Store. In this case we have a dataset
detailing the eye color, left/right handedness, height, gender, iq and birth decade of 800 (fictional) people.

The example code is not minified, so it's readable.

Counting occurrences

Let's start simple with a count of the number of people born per decade.

Finding averages

PivotGrid can be used to easily find averages in large datasets. Here we ask it for the average height of people
in each decade, broken down by gender and handedness.

In this example we also use a, turning our calculated heights (which are decimals) into feet and inches notation.

Finding maximums

It's also easy gather minimum and maximum values in PivotGrid. Here we determine the maximum IQ per birth decade and
handedness. Note that we don't have to specify left and top axes - in this case we are summarizing purely through a top axis.