# Aggregated Calculated Columns

Canonical page: https://www.adaptabletools.com/docs/handbook-calculated-column-aggregated

- Aggregated Calculated Columns show a value that is derived dynamically from __multiple, distinct rows__

Most Calculated Columns use a [Standard Scalar](https://www.adaptabletools.com/docs/handbook-calculated-column-standard/index.md), basing the calculated value on other cells in the row.

However Calculated Column values can also be derived dynamically from **multiple, distinct rows**.

In this use case the Expression is of type [Aggregation](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md).

Like a Standard Scalar Expression, the Aggregated Scalar Expression returns a single scalar value.

Aggregated Scalar Expressions can accept Scalar Expressions as inputs

Each value returned is calculated by aggregating multiple rows and columns in the grid.

A Calculated Column's Aggregated Scalar Expression updates in real time when a referenced grid value changes

## Aggregation Operations

The following Aggregation operations are supported by AdapTableQL:

- `SUM`: sums the values of the specified columns
- `PERCENTAGE`: calculates the percentage of the specified columns (using `SUM` as default)

- `AVG`: calculates average of specified columns (optional `WEIGHT` parameter supports [Weighted Averages](https://www.adaptabletools.com/docs/handbook-aggregation-weighted-average/index.md))
- `MIN`: returns the minimum value of the specified columns

- `MAX`: returns the maximum value of the specified columns

- Aggregated Calculated Columns do not evaluate automatically when using the [Server-Side Row Model](https://www.adaptabletools.com/docs/dev-guide-row-models-server-overview/index.md) — the client may not have all the rows required for the aggregation

See [Server-Side Row Model - Calculated Columns](https://www.adaptabletools.com/docs/dev-guide-row-models-server-calculated-columns/index.md) and [Calculated Columns](https://www.adaptabletools.com/docs/handbook-calculated-column/index.md#server-side-row-model) for which types work on the client and how to evaluate on the server.

### Defining an Aggregated Calculated Column

There are 5 properties that you need to provide when defining an Aggregated Calculated Column:

This `ColumnId` value is used to reference the Column in AdapTable State and in other objects (e.g. [Layouts](https://www.adaptabletools.com/docs/handbook-layouts/index.md)).

This value is used to refer to the Column in AdapTable UI.
It only needs to be provided if the `ColumnId` value is unsuitable.

The [Aggregation Expression](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md) evaluated by [AdapTableQL](https://www.adaptabletools.com/docs/adaptable-ql-expression/index.md) across multiple rows.

It is the `Expression` string of the Calculated Column and uses one of the aggregation operations (`SUM`, `AVG`, `MIN`, `MAX`, `PERCENTAGE`) - AdapTable infers from the text that the column is aggregated.

By default an Aggregation Expression evaluates across **every** row in the grid.

Add a `GROUP_BY([column])` clause inside the expression to evaluate the aggregation against **subsets** of rows — one bucket per distinct value of the grouping column. Each row then sees the aggregated value for its own group.

In the second example, `GROUP_BY([language])` means each row receives the average watcher count for its own language.

The Data Type of the Calculated Column should be provided in `CalculatedColumnSettings`.

It is a [Cell Data Type](https://www.adaptabletools.com/docs/dev-guide-aggrid-cell-data-types/index.md) value and the object's only mandatory property. Common values are `number`, `text` or `date`.

Additional Settings for the Calculated Column (other than mandatory `DataType`) can be provided, including:

- `Filterable`
- `Pivotable`
- `Sortable`
- `Groupable`

```tsx [[1,4, "ColumnId"],[1,13, "ColumnId"],[2,5, "FriendlyName"],[2,14, "FriendlyName"],[3,6, "Expression"],[3,15, "Expression"],[4,15, "GROUP_BY"],[5,8, "DataType"],[5,17, "DataType"],[6,9, "Resizable"],[6,18, "Resizable"]]
CalculatedColumn: {
  CalculatedColumns: [
    {
      ColumnId: 'sum-watchers',
      FriendlyName: 'Sum Watchers',
      Expression: 'SUM{[github_watchers]}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
    {
      ColumnId: 'avg-watchers-by-lang',
      FriendlyName: 'Avg Watchers by Language',
      Expression: 'AVG{[github_watchers], GROUP_BY([language])}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
  ],
},
```

**Example: Calculated Columns: Aggregated**

Calculated Columns: Aggregated Scalar Expressions

- This demo contains 5 Calculated Columns that use [Aggregation Expressions](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md) - all on the `Github Watchers` Column:
  - `Sum Watchers` - sums all the values
  - `Average Watchers` - average of all the values
  - `Min Watchers` - Minimum of the values
  - `Max Watchers` - Maximum of  the values
  - `% Watchers` - Percentage of  the values
- Note these Calculated Columns do not use grouping - see demo below for an example using Groups
### Expand to see the Aggregation Scalar Expressions

```ts
CalculatedColumn: {
 CalculatedColumns: [
    {
      ColumnId: 'sum-watchers',
      FriendlyName: 'Sum Watchers',
      Expression: 'SUM{[github_watchers]}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
    {
      ColumnId: 'average-watchers',
      FriendlyName: 'Avg. Watchers',
      Expression: 'AVG{[github_watchers]}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
    {
      ColumnId: 'min-watchers',
      FriendlyName: 'Min Watchers',
      Expression: 'MIN{[github_watchers]}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
    {
      ColumnId: 'max-watchers',
      FriendlyName: 'Max Watchers',
      Expression: 'MAX{[github_watchers]}',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
    {
      ColumnId: 'percentage-watchers',
      FriendlyName: '% Watchers',
      Expression: 'PERCENTAGE([github_watchers])',
      CalculatedColumnSettings: {
        DataType: 'number',
        Resizable: true,
      },
    },
  ],
},
```

- Update a cell in the `Github Watchers` column and see how all 5 Calculated Columns update

Demo project (Vanilla); the files without a marker are shown below:

```text
src/
  adaptableOptions.ts
  agGridModules.ts     [template]
  columnDefs.ts        [template]
  gridOptions.ts       [template]
  index.ts             [template]
  onAdaptableReady.ts  [template]
  rowData.ts           [template]
  styles.css           [template]
index.html             [template]
package.json           [template]
tsconfig.json          [template]
```

Files marked `[template]` are the same in every demo; see the [demo template](https://www.adaptabletools.com/llms/demo-template.md#vanilla).

**`src/adaptableOptions.ts`**

```ts
import {AdaptableOptions} from '@adaptabletools/adaptable';
import {WebFramework} from './rowData';

export const adaptableOptions: AdaptableOptions<WebFramework> = {
  primaryKey: 'id',
  adaptableId: 'Aggregated Calculated Columns',
  initialState: {
    Dashboard: {
      ModuleButtons: ['CalculatedColumn'],
      PinnedToolbars: ['Layout'],
    },
    StatusBar: {
      StatusBars: [
        {
          Key: 'Center Panel',
          StatusBarPanels: ['Layout', 'CalculatedColumn'],
        },
      ],
    },
    Theme: {CurrentTheme: 'dark'},
    Layout: {
      CurrentLayout: 'Standard Layout',
      Layouts: [
        {
          Name: 'Standard Layout',
          TableColumns: [
            'language',
            'github_watchers',
            'sum-watchers',
            'average-watchers',
            'min-watchers',
            'max-watchers',
            'percentage-watchers',
            'name',
          ],
          AutoSizeColumns: true,
        },
      ],
    },
    CalculatedColumn: {
      CalculatedColumns: [
        {
          ColumnId: 'sum-watchers',
          FriendlyName: 'Sum Watchers',
          Expression: 'SUM{[github_watchers]}',
          CalculatedColumnSettings: {
            DataType: 'number',
            Resizable: true,
          },
        },
        {
          ColumnId: 'average-watchers',
          FriendlyName: 'Avg. Watchers',
          Expression: 'AVG{[github_watchers]}',
          CalculatedColumnSettings: {
            DataType: 'number',
            Resizable: true,
          },
        },
        {
          ColumnId: 'min-watchers',
          FriendlyName: 'Min Watchers',
          Expression: 'MIN{[github_watchers]}',
          CalculatedColumnSettings: {
            DataType: 'number',
            Resizable: true,
          },
        },
        {
          ColumnId: 'max-watchers',
          FriendlyName: 'Max Watchers',
          Expression: 'MAX{[github_watchers]}',
          CalculatedColumnSettings: {
            DataType: 'number',
            Resizable: true,
          },
        },
        {
          ColumnId: 'percentage-watchers',
          FriendlyName: '% Watchers',
          Expression: 'PERCENTAGE([github_watchers])',
          CalculatedColumnSettings: {
            DataType: 'number',
            Resizable: true,
          },
        },
      ],
    },
    FormatColumn: {
      FormatColumns: [
        {
          Name: 'formatColumn-sum-watchers',
          Scope: {
            ColumnIds: [
              'sum-watchers',
              'average-watchers',
              'min-watchers',
              'max-watchers',
              'percentage-watchers',
            ],
          },
          Style: {
            FontStyle: 'Italic',
          },
          DisplayFormat: {
            Formatter: 'NumberFormatter',
            Options: {
              FractionDigits: 2,
            },
          },
        },
      ],
    },
  },
};
```

### Using `GROUP_BY`

An Aggregation Scalar Function can also be applied to a **set** of rows, rather than to the entire grid.

This is done by using the `GROUP_BY` [AdapTableQL Expression Function](https://www.adaptabletools.com/docs/adaptable-ql-expression-functions/index.md).

This allows for much more powerful Expressions than displayed in the example above, becauase you can have multiple sets of Aggregations.

See the AdapTableQL Guide to [Aggregation Expressions](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md) for more information and examples

**Example: Calculated Columns: Aggregated with GROUP_BY**

Calculated Columns: Aggregated, Grouped Scalar Expressions

- This demo contains 3 Calculated Columns that use [Aggregation Expressions](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md)
- All are based on the `Github Watchers` Column and all use **grouping** on the `Language` Column:
  - `Sum Watchers` - sums all the values
  - `Average Watchers` - average of all the values
  - `% Watchers` - Percentage of  the values
- It also contains another Aggregated Scalar Calculated Column - `Open/Closed Issues Percentage by Language` 
  - This calculates the percentage of open and closed issues of all the repos in the grid, **grouped** by language 
  - It's a slightly contrived example, but showcases how to calculate a percentage based on aggregated values from other columns
### Expand to see the Aggregation Scalar Expressions

```ts
CalculatedColumn: {
  CalculatedColumns: [
    {
      FriendlyName: 'Popularity',
      ColumnId: 'githubPopularity',
      Expression: '[github_watchers] + [github_stars]',
    },
    {
      FriendlyName: 'Subscribers Ratio',
      ColumnId: 'subscribersRatio',
      Expression: 'PERCENTAGE([github_watchers])',
    },
    {
      ColumnId: 'average-popularity-by-lang',
      FriendlyName: 'Avg. Popularity by Lang',
      Expression: 'AVG{[githubPopularity], GROUP_BY([language])}',
      CalculatedColumnSettings: { DataType: 'number' },
    },
    {
      ColumnId: 'percentage-issues-by-lang',
      FriendlyName: 'Open/Closed Issues % by Lang',
      Expression: 'PERCENTAGE([open_issues_count], SUM{[closed_issues_count], GROUP_BY([language])})',
      CalculatedColumnSettings: { DataType: 'number' },
    },
  ],
},
```

- Update a cell in the `Github Watchers` column and see how the Calculated Columns update

Demo project (Vanilla); the files without a marker are shown below:

```text
src/
  adaptableOptions.ts
  agGridModules.ts     [template]
  columnDefs.ts        [template]
  gridOptions.ts       [template]
  index.ts             [template]
  onAdaptableReady.ts  [template]
  rowData.ts           [template]
  styles.css           [template]
index.html             [template]
package.json           [template]
tsconfig.json          [template]
```

Files marked `[template]` are the same in every demo; see the [demo template](https://www.adaptabletools.com/llms/demo-template.md#vanilla).

**`src/adaptableOptions.ts`**

```ts
import {AdaptableOptions} from '@adaptabletools/adaptable';
import {WebFramework} from './rowData';

export const adaptableOptions: AdaptableOptions<WebFramework> = {
  primaryKey: 'id',
  adaptableId: 'Aggregated GroupBy Calculated Columns',
  initialState: {
    Dashboard: {
      ModuleButtons: ['CalculatedColumn'],
      PinnedToolbars: ['Layout'],
    },
    StatusBar: {
      StatusBars: [
        {
          Key: 'Center Panel',
          StatusBarPanels: ['Layout', 'CalculatedColumn'],
        },
      ],
    },
    Theme: {CurrentTheme: 'dark'},
    Layout: {
      CurrentLayout: 'Standard Layout',
      Layouts: [
        {
          Name: 'Standard Layout',
          TableColumns: [
            'language',
            'github_watchers',
            'sum-watchers-by-lang',
            'avg-watchers-by-lang',
            'percentage-watchers-by-lang',
            'percentage-issues-by-lang',
            'name',
          ],
        },
        {
          Name: 'Grouped',
          TableColumns: [
            'language',
            'github_watchers',
            'sum-watchers-by-lang',
            'avg-watchers-by-lang',
            'percentage-watchers-by-lang',
            'percentage-issues-by-lang',
            'name',
          ],
          RowGroupedColumns: ['language'],
        },
      ],
    },
    CalculatedColumn: {
      CalculatedColumns: [
        {
          ColumnId: 'sum-watchers-by-lang',
          FriendlyName: 'Sum Watchers by Lang',
          Expression: 'SUM{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'avg-watchers-by-lang',
          FriendlyName: 'Avg Watchers by Lang',
          Expression: 'AVG{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'percentage-watchers-by-lang',
          FriendlyName: '% Watchers by Lang',
          Expression: 'PERCENTAGE([github_watchers], SUM{[github_watchers], GROUP_BY([language])})',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'percentage-issues-by-lang',
          FriendlyName: 'Open/Closed Issues % by Lang',
          Expression: 'PERCENTAGE([open_issues_count], SUM{[closed_issues_count], GROUP_BY([language])})',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
      ],
    },
    FormatColumn: {
      FormatColumns: [
        {
          Name: 'formatColumn-sum-watchers-by-lang',
          Scope: {
            ColumnIds: [
              'sum-watchers-by-lang',
              'avg-watchers-by-lang',
              'percentage-watchers-by-lang',
              'percentage-issues-by-lang',
            ],
          },
          Style: {
            FontStyle: 'Italic',
          },
          DisplayFormat: {
            Formatter: 'NumberFormatter',
            Options: {
              FractionDigits: 2,
            },
          },
        },
      ],
    },
  },
};
```

## Grouped Rows

The values in Aggregation Calculated Columns can be used when summarising data for [Grouped Rows](https://www.adaptabletools.com/docs/handbook-grouping-rows/index.md).

AdapTable will ensure that if the Grid contains Aggregated Calculated Columns and Grouped Rows, the "aggFunc" summaries will display normally.

### A note on terminology

The terminology here can be confusing because "Aggregation" and "Grouping" can mean different things by AG Grid and AdapTable depending on the context.

**Grouping**

- AdapTable here uses Grouping to describe how it performs the Aggregation Scalar calculation on different sets of rows by using the `GROUP_BY` keyword
- AG Grid uses Grouping to mean when it visually groups the rows using [Row Grouping](https://www.adaptabletools.com/docs/handbook-grouping-rows/index.md)

**Aggregation**

- AdapTable uses it to describe the calculation performed on multiple rows to evaluate Calculated Column Cells
- AG Grid uses the term (also known as 'aggfunc') to mean the the "summary" data displayed in Grouped Rows

**Example: Calculated Columns: Aggregated with Row Grouping**

Calculated Columns: Aggregated Scalar Expressions in Row Groups

- This demo contains 4 Calculated Columns that use [Aggregation Expressions](https://www.adaptabletools.com/docs/adaptable-ql-expression-aggregation/index.md) based on the `Github Watchers` Column
- Like in the demo above all the Aggregated Scalar Expressions use `GROUP_BY` on the `Language` Column
- We have also created a Layout which contains [Row Grouping](https://www.adaptabletools.com/docs/handbook-grouping-rows/index.md) on the Language Column
- The Layout also contains 4 AG Grid `aggFunc` summaries each connected to an AdapTable Aggregated Expression:
  - `SumByLang` - uses a `SUM` AdapTable Aggregated Expression and a `sum` AG Grid aggFunc
  - `AvgByLang` - uses a `AVG` AdapTable Aggregated Expression and a `avg` AG Grid aggFunc
  - `MinByLang` - uses a `MIN` AdapTable Aggregated Expression and a `min` AG Grid aggFunc
  - `MaxByLang` - uses a `MAX` AdapTable Aggregated Expression and a `max` AG Grid aggFunc
- We have created an [AG Grid Column Group](https://www.adaptabletools.com/docs/handbook-grouping-columns/index.md) to display the 4 Calculated Columns as a set

- Update a cell in the `Github Watchers` Column and note how the 4 Calculated Columns update and so does the AG Grid agg summary

Demo project (Vanilla); the files without a marker are shown below:

```text
src/
  adaptableOptions.ts
  agGridModules.ts     [template]
  columnDefs.ts
  gridOptions.ts       [template]
  index.ts             [template]
  onAdaptableReady.ts  [template]
  rowData.ts           [template]
  styles.css           [template]
index.html             [template]
package.json           [template]
tsconfig.json          [template]
```

Files marked `[template]` are the same in every demo; see the [demo template](https://www.adaptabletools.com/llms/demo-template.md#vanilla).

**`src/adaptableOptions.ts`**

```ts
import {AdaptableOptions} from '@adaptabletools/adaptable';
import {WebFramework} from './rowData';

export const adaptableOptions: AdaptableOptions<WebFramework> = {
  primaryKey: 'id',
  adaptableId: 'Aggregated Row Grouped Calculated Columns',
  initialState: {
    Dashboard: {
      ModuleButtons: ['CalculatedColumn'],
      PinnedToolbars: ['Layout'],
    },
    StatusBar: {
      StatusBars: [
        {
          Key: 'Center Panel',
          StatusBarPanels: ['Layout', 'CalculatedColumn'],
        },
      ],
    },
    Theme: {CurrentTheme: 'dark'},
    Layout: {
      CurrentLayout: 'Grouped',
      Layouts: [
        {
          Name: 'Standard Layout',
          TableColumns: [
            'language',
            'github_watchers',
            'sum-watchers-by-lang',
            'avg-watchers-by-lang',
            'min-watchers-by-lang',
            'max-watchers-by-lang',
            'name',
          ],
        },
        {
          Name: 'Grouped',
          TableColumns: [
            'name',
            'github_watchers',
            'sum-watchers-by-lang',
            'avg-watchers-by-lang',
            'min-watchers-by-lang',
            'max-watchers-by-lang',
          ],
          RowGroupedColumns: ['language'],
          SuppressAggFuncInHeader: true,
          TableAggregationColumns: [
            {
              ColumnId: 'sum-watchers-by-lang',
              AggFunc: 'sum',
            },
            {
              ColumnId: 'avg-watchers-by-lang',
              AggFunc: 'avg',
            },
            {
              ColumnId: 'min-watchers-by-lang',
              AggFunc: 'min',
            },
            {
              ColumnId: 'max-watchers-by-lang',
              AggFunc: 'max',
            },
          ],
          ColumnSizing: {
            name: {Width: 100},
            github_watchers: {Width: 150},
            'sum-watchers-by-lang': {Width: 100},
            'avg-watchers-by-lang': {Width: 100},
            'min-watchers-by-lang': {Width: 100},
            'max-watchers-by-lang': {Width: 100},
          },
        },
      ],
    },
    CalculatedColumn: {
      CalculatedColumns: [
        {
          ColumnId: 'sum-watchers-by-lang',
          FriendlyName: 'Sum',
          Expression: 'SUM{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'avg-watchers-by-lang',
          FriendlyName: 'Avg',
          Expression: 'AVG{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'min-watchers-by-lang',
          FriendlyName: 'Min',
          Expression: 'MIN{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
        {
          ColumnId: 'max-watchers-by-lang',
          FriendlyName: 'Max',
          Expression: 'MAX{[github_watchers], GROUP_BY([language])}',
          CalculatedColumnSettings: {
            DataType: 'number',
          },
        },
      ],
    },
    FormatColumn: {
      FormatColumns: [
        {
          Name: 'formatColumn-sum-watchers-by-lang',
          Scope: {
            ColumnIds: [
              'sum-watchers-by-lang',
              'avg-watchers-by-lang',
              'min-watchers-by-lang',
              'max-issues-by-lang',
            ],
          },
          Style: {
            FontStyle: 'Italic',
          },
        },
        {
          Name: 'formatColumn-avg-watchers-by-lang',
          Scope: {
            ColumnIds: ['avg-watchers-by-lang'],
          },
          DisplayFormat: {
            Formatter: 'NumberFormatter',
            Options: {
              FractionDigits: 2,
            },
          },
        },
      ],
    },
  },
};
```

**`src/columnDefs.ts`**

```ts
import {ColDef, ColGroupDef} from 'ag-grid-enterprise';

export const columnDefs: (ColDef | ColGroupDef)[] = [
  {
    field: 'name',
    cellDataType: 'text',
  },
  {
    field: 'language',
    cellDataType: 'text',
    enablePivot: true,
    enableRowGroup: true,
  },
  {
    field: 'github_stars',
    headerName: 'GitHub Stars',
    cellDataType: 'number',
    enableValue: true,
  },
  {
    field: 'github_watchers',
    headerName: 'GitHub Watchers',
    cellDataType: 'number',
    enableValue: true,
  },
  {
    headerName: 'Github Watchers Aggregations (Grouped by Language)',
    marryChildren: true,
    children: [
      {
        field: 'sum-watchers-by-lang',
        headerName: 'Sum',
        type: ['calculatedColumn'],
        cellDataType: 'number',
      },
      {
        field: 'avg-watchers-by-lang',
        headerName: 'Avg',
        type: ['calculatedColumn'],
        cellDataType: 'number',
      },
      {
        field: 'min-watchers-by-lang',
        headerName: 'Min',
        type: ['calculatedColumn'],
        cellDataType: 'number',
      },
      {
        field: 'max-watchers-by-lang',
        headerName: 'Max',
        type: ['calculatedColumn'],
        cellDataType: 'number',
      },
    ],
  },
  {
    field: 'week_issue_change',
    headerName: 'Issue Change',
    cellDataType: 'number',
    enableValue: true,
  },
  {
    field: 'open_pr_count',
    headerName: 'Open PRs',
    cellDataType: 'number',
  },
  {
    field: 'closed_pr_count',
    headerName: 'Closed PRs',
    cellDataType: 'number',
  },
  {
    field: 'open_issues_count',
    headerName: 'Open Issues',
    cellDataType: 'number',
    columnGroupShow: 'closed',
  },
  {
    field: 'closed_issues_count',
    headerName: 'Closed Issues',
    cellDataType: 'number',
    columnGroupShow: 'closed',
  },
  {
    field: 'license',
    cellDataType: 'text',
    editable: false,
    enablePivot: true,
    enableRowGroup: true,
  },

  {field: 'has_wiki', headerName: 'Has Wiki', cellDataType: 'boolean'},
  {
    field: 'has_projects',
    headerName: 'Has Projects',
    cellDataType: 'boolean',
  },
  {field: 'has_pages', headerName: 'Has Pages', cellDataType: 'boolean'},
  {
    field: 'description',
    cellDataType: 'text',
    sortable: false,
    columnGroupShow: 'closed',
  },
  {
    field: 'id',
    cellDataType: 'number',
    hide: true,
    editable: false,
  },
];
```
