# Group By

## Overview

The Group By Node allows you to easily group your data by one or more columns and perform various aggregate functions such as sum, average, or count. This functionality is crucial for generating summarized views of your data and is often a vital step before further analysis or visualization.

<figure><img src="/files/vpcm5JjtyEpIjqYFxtjW" alt=""><figcaption></figcaption></figure>

## Settings

#### Group rows by

Select a column to group by. To choose multiple columns, click the "+ Then group by" link and select another one. Additionally, you can tailor the sorting order for each column individually.

#### Set values to

Select columns to perform aggregation. You can select multiple columns with the "+ Add value" link.

{% hint style="info" %}
Read more about the available aggregation functions [here](/data-transformation/formulas/aggregate-functions.md).
{% endhint %}

There are two options for creating aggregations:

1. Predefined aggregation functions. Follow these steps:
   1. Select the column you want to use as a basis for the aggregation.
   2. Choose an aggregation function from the list.
2. Custom Formula. Enable the "Custom Formula" toggle to use a custom formula. With this option, you can define any custom expression that should return an aggregation function.

<br>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.tomat.ai/data-transformation/transforms/group-by.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
