Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Maps][docs] add more details to Quantitative data driven styling docs #59553

Merged
merged 9 commits into from
Mar 9, 2020
19 changes: 17 additions & 2 deletions docs/maps/maps-aggregations.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,25 @@
[[maps-aggregations]]
== 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.
Use {ref}/search-aggregations.html[aggregations] to plot large data sets without overwhelming 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