Skip to content

Commit

Permalink
[Maps][docs] add more details to Quantitative data driven styling
Browse files Browse the repository at this point in the history
  • Loading branch information
nreese committed Mar 6, 2020
1 parent 91a5b17 commit 6d8b936
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 4 deletions.
17 changes: 16 additions & 1 deletion docs/maps/maps-aggregations.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,24 @@
== Plot big data without plotting too much data

Use {ref}/search-aggregations.html[aggregations] to plot large data sets without overwhemling your network or your browser.
When using aggregations, the documents stay in Elasticsearch and only the calculated values for each group are returned to your computer.

Aggregations group your documents into buckets and calculate metrics for each bucket.
Your documents stay in Elasticsearch and only the metrics for each group are returned to your computer.
Use metric aggregations for <<maps-vector-style-data-driven, data driven styling>>. For example, use the count aggregation to shade world countries by web log traffic.

You can add the following metric aggregations:

* *Average aggregation* computes the average of numeric values that are extracted from the aggregated documents.

* *Count aggregation* calculates the count of the number of aggregated documents.

* *Max aggregation* keeps track and returns the maximum value among the numeric values extracted from the aggregated documents.

* *Min aggregation* keeps track and returns the minimum value among numeric values extracted from the aggregated documents.

* *Sum aggregation* sums up numeric values that are extracted from the aggregated documents.

* *Unique count aggregation* calculates an approximate count of distinct values.

Use aggregated layers with document layers to show aggregated views when the map shows larger
amounts of the globe and individual documents when the map shows smaller regions.
Expand Down
12 changes: 9 additions & 3 deletions docs/maps/vector-style.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,17 @@ image::maps/images/vector_style_dynamic.png[]

Quantitative data driven styling symbolizes features from a range of numeric property values.

To ensure symbols are consistent as you pan, zoom, and filter the map, quantitative data driven styling uses {ref}/search-aggregations-metrics-extendedstats-aggregation.html[extended_stats aggregation] to retrieve statistical metadata.
Property values are fit from the domain range to the style range on a linear scale.
For example, lets symbolize <<add-sample-data, Kibana sample web log>> documents by size.
The smallest feature will have a symbol radius of 1, and the largest feature will have a symbol radius of 24.
The sample web logs `bytes` field ranges from 0 to 18,000.
The `bytes` property value for each feature will be fit on a linear scale from the range 0 to 18,000 to the style range 1 to 24.

Click the gear icon image:maps/images/gear_icon.png[] to configure extended_stats. Set *Sigma* to a smaller value to minimize outliers by moving the range minimum and maximum closer to the average. Clear the *Calculate range from indices* checkbox to turn off the extended_stats aggregation request.
To ensure symbols are consistent as you pan, zoom, and filter the map, quantitative data driven styling uses {ref}/search-aggregations-metrics-extendedstats-aggregation.html[extended_stats aggregation] to retrieve statistical metadata. Extended_stats is not available for numeric property values from <<maps-aggregations, metric aggregations>> count, sum, and unique count.

NOTE: When the *Calculate range from indices* checkbox is cleared, symbols might be inconsistent as users pan, zoom, and filter the map. Without extended_stats, the range is calulated with data from the local layer. The range is recalulcated when layer data changes.
Click the gear icon image:maps/images/gear_icon.png[] to configure extended_stats. Set *Sigma* to a smaller value to minimize outliers by moving the range minimum and maximum closer to the average. Clear the *Calculate range from indices* checkbox to turn off the extended_stats aggregation request. The gear icon is not available for numeric property values from <<maps-aggregations, metric aggregations>> count, sum, and unique count.

NOTE: When extended_stats is not being used, symbols might be inconsistent as users pan, zoom, and filter the map. Without extended_stats, the range is calculated with data from the local layer. The range is re-calculated when layer data changes.

[role="screenshot"]
image::maps/images/extended_stats_config.png[]
Expand Down

0 comments on commit 6d8b936

Please sign in to comment.