Skip to content

[DOCS] Adds frequent items agg docs#86037

Merged
szabosteve merged 26 commits intoelastic:masterfrom
szabosteve:frequent_items.agg.docs
May 5, 2022
Merged

[DOCS] Adds frequent items agg docs#86037
szabosteve merged 26 commits intoelastic:masterfrom
szabosteve:frequent_items.agg.docs

Conversation

@szabosteve
Copy link
Copy Markdown
Contributor

@szabosteve szabosteve commented Apr 20, 2022

Overview

This PR adds the frequent items aggregation documentation to the aggregation docs. It has the following content:

  • definition
  • parameter list and description
  • working example using the Kibana e-commerce sample data set.

Preview

Frequent items aggregation

@szabosteve szabosteve added >docs General docs changes :Analytics/Aggregations Aggregations :ml Machine learning v8.2.0 v8.3.0 labels Apr 20, 2022
@szabosteve szabosteve removed the v8.2.0 label Apr 20, 2022
@szabosteve szabosteve requested review from hendrikmuhs and lcawl April 21, 2022 13:28
@szabosteve szabosteve marked this pull request as ready for review April 21, 2022 14:11
@elasticmachine elasticmachine added the Team:Docs Meta label for docs team label Apr 21, 2022
@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/es-docs (Team:Docs)

@elasticmachine elasticmachine added Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) Team:ML Meta label for the ML team labels Apr 21, 2022
@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/es-analytics-geo (Team:Analytics)

@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/ml-core (Team:ML)

Co-authored-by: Lisa Cawley <lcawley@elastic.co>
@szabosteve szabosteve requested review from hendrikmuhs and lcawl April 25, 2022 12:09
szabosteve and others added 2 commits April 26, 2022 08:36
Co-authored-by: Lisa Cawley <lcawley@elastic.co>
@szabosteve szabosteve requested a review from lcawl April 26, 2022 06:40
@hendrikmuhs
Copy link
Copy Markdown

What about an additional advanced example with runtime fields to show how to bucket numeric values, e.g.

GET kibana_sample_data_ecommerce/_search
{
  "runtime_mappings": {
    "price_range": {
      "type": "keyword",
      "script": {
        "source": """
           def bucket_start = (long) Math.floor(doc['taxful_total_price'].value / 50) * 50;
           def bucket_end = bucket_start + 50;
           emit(bucket_start.toString() + "-" + bucket_end.toString());
        """
      }
    }
  },
  "size": 0,
  "aggs": {
    "fi": {
      "frequent_items": {
        "minimum_set_size": 3,
        "fields": [
          {
            "field": "category.keyword"
          },
          {
            "field": "price_range"
          },
          {
            "field": "geoip.city_name"
          }
        ]
      }
    }
  }
}

@szabosteve
Copy link
Copy Markdown
Contributor Author

szabosteve commented Apr 26, 2022

@hendrikmuhs I added the advanced example via aaaf280. It starts at line 183.

@szabosteve szabosteve merged commit e590e90 into elastic:master May 5, 2022
hendrikmuhs pushed a commit that referenced this pull request Jul 26, 2022
add an aggregation called frequent_items, a bucket aggregation which finds frequent item sets. It is a form of association rules mining that identifies items that often occur together. It also helps you to discover relationships between different data points (items).

For more information about usage have a look at #86037.

This implements frequent items using an algorithm called eclat.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Analytics/Aggregations Aggregations >docs General docs changes :ml Machine learning Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) Team:Docs Meta label for docs team Team:ML Meta label for the ML team v8.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants