# Introduction to Aggregation

## Overview

As described in the Dimensions documentation, [**Dimensions**](https://help.taglo.io/dimensions) allow you to improve the quality of your Models while reducing complexity, by removing repetition of Calculations.

For instance, you might have several cost items in a business (e.g. Marketing, Salaries, IT, Rent) that you need to perform some common calculations on, such as working capital adjustments.

To do this efficiently, it is best to have these cost items in a single [**Variable**](https://help.taglo.io/variables), in this case using a `Cost Type` or similar Dimension. However, the individual cost items are all calculated differently (e.g. Salaries and Rent), so we cannot use the `Cost Type` Dimension for all Calculations - we need to first calculate the individual items separately, and then bring them together under one Variable. This is where we use **Aggregation**.

## Aggregation Example

<figure><img src="https://2847533834-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FVy65sax6FVoNo2UTlJ0x%2Fuploads%2Ftze8G2JSyui5mZMQjmBg%2Fimage.png?alt=media&#x26;token=6c3c7349-ca5e-45fd-b17f-ccf76d2760b7" alt=""><figcaption><p>Example of a Variable using Aggregation</p></figcaption></figure>

The screenshot above shows the preview for a Variable using Aggregation. The Variable uses a Dimension, `Cost Type` <mark style="color:green;">**(1)**</mark>, with seven children (`Central staff`, `Gym staff`, etc...).

The Variable has a single [**Time Segment**](https://help.taglo.io/variables/time-segments) <mark style="color:green;">**(2)**</mark> that uses an Aggregation [**Formula**](https://help.taglo.io/variables/time-segments/time-segment-setup#formula) in which the Cost Item Variables are referenced.&#x20;

{% hint style="success" %}
Note that the [**Row Summary**](https://help.taglo.io/variables/summaries#row-summary) is set to `Sum`, providing an automatic sum of the seven Variables. This is a much cleaner method of adding these Variables together than creating a dedicated Calculation: (`Central Staff` + `Gym staff + Marketing cost` + `etc...)`
{% endhint %}

The next section explains how to create and configure an Aggregation Variable.
