Feature update – scatter charts

Scatter Charts

There are now two types of charts you can make in GuidedTrack: bar and scatter. We’ll go over the latter here, but you can find instructions for making bar charts in the GuidedTrack manual.

Here’s how scatter charts look:


When users hover their mouse over any of the above data plots, a small box pops up with additional information. For example, if users hover their mouse over the 1993 data point, it reads, “First year of school.” (the above is just a static image, but you can try it yourself here).

The code for this works similarly to bar charts. You need the *chart keyword and an optional title for your chart. You also need the *type keyword (in this case it should say: *type: scatter). Third is the *data keyword. Your data should be organized in this general format: *data: [[x1, y1], [x2, y2], [x3, y3], [etc…]]

In our example, there are five data points. Each data point is surrounded by [brackets]. The value of the x-axis is written first (in our case, that’s the year) and second is the y-axis (e.g. centimeters). Commas separate the values within each data point and they separate data points from each other. Additional brackets surround the entire dataset.

If you remember learning about collections previously, then this dataset can also be thought of as a collection of smaller collections. Variables can also be subbed in.

The *rollover keyword is optional. If you include it, you must have as many entries as there are data points. The first rollover text, (i.e. “Toddler”) corresponds to the first data point (i.e. [1989, 100]), and so on. Rollovers provide additional text that users can view when they hover over the corresponding data point.