Chapter 7. Aggregations for Data Analysis

In the previous chapter, we discussed the querying side of Elasticsearch again. We learned how the Lucene TF/IDF algorithm works and how to use Elasticsearch scripting capabilities. We handled multilingual data and influenced document scores with boosts. We used synonyms to match words that have the same meaning and we used Elasticsearch Explain API to see how document scores were calculated. By the end of this chapter, you will have learned the following topics:

  • What are aggregations
  • How the Elasticsearch aggregation engine works
  • How to use metrics aggregations
  • How to use buckets aggregations
  • How to use pipeline aggregations


Introduced in Elasticsearch 1.0, aggregations are the heart of data analytics ...

Get Elasticsearch Server - Third Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.