Geovisualization Developer's Guide

Dynamic Parameters

Visualizations based on smaller and simpler datasets can use a query that fetches all the data in a single GET request to the Geovisualization REST API. However, when working with a dataset which is more complex or consists of several gigabytes of data, this method may not be practical. It would be more efficient for the query to retrieve only the data that is required for the current viewport.

To do this, you define the query to get the data from the dataset dynamically. That is, the data will be retrieved in subsets after being filtered server-side, according to the parameters in the query's GET request URL. Instead of retrieving all data rows in one action, you only retrieve the data rows you need for each layer in the visualization.

An important point to note is that a client-side (JavaScript) implementation of a stepped parameter allows a smooth, well-defined animation, whereas the back-end implementation with dynamic parameters is only staggering the data retrieval; it is not offering a dedicated animation. Therefore, the JavaScript approach is better suited to smaller datasets and where animation is required, and dynamic parameters are more suitable for larger datasets where animation is less important.

The following is an example of a heat map created with Geovisualization which displays mobile network events in the US. In the example, we filter the data using a query with dynamic parameters. Click the image to view the full code for this example.

Figure 1. A heat map using a query including dynamic parameters (click the image to go to the code example)