# AggregationFunctionProperty

An aggregation function aggregates values from a dimension or measure.

This is a union type structure. For this structure to be valid, only one of the attributes can be defined.

- Source: Generated code
- Type last changed: v2.95.0 · 7 Sep 2023

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_quicksight as quicksight } from 'aws-cdk-lib';
const aggregationFunctionProperty: quicksight.CfnDashboard.AggregationFunctionProperty = {
  attributeAggregationFunction: {
    simpleAttributeAggregation: 'simpleAttributeAggregation',
    valueForMultipleValues: 'valueForMultipleValues',
  },
  categoricalAggregationFunction: 'categoricalAggregationFunction',
  dateAggregationFunction: 'dateAggregationFunction',
  numericalAggregationFunction: {
    percentileAggregation: {
      percentileValue: 123,
    },
    simpleNumericalAggregation: 'simpleNumericalAggregation',
  },
};
```

## Properties

- `attributeAggregationFunction`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnDashboard.AttributeAggregationFunctionProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_quicksight.CfnDashboard.AttributeAggregationFunctionProperty.html) — Aggregation for attributes.

- `categoricalAggregationFunction`: string — Aggregation for categorical values.

  - `COUNT` : Aggregate by the total number of values, including duplicates.
  - `DISTINCT_COUNT` : Aggregate by the total number of distinct values.

- `dateAggregationFunction`: string — Aggregation for date values.

  - `COUNT` : Aggregate by the total number of values, including duplicates.
  - `DISTINCT_COUNT` : Aggregate by the total number of distinct values.
  - `MIN` : Select the smallest date value.
  - `MAX` : Select the largest date value.

- `numericalAggregationFunction`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnDashboard.NumericalAggregationFunctionProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_quicksight.CfnDashboard.NumericalAggregationFunctionProperty.html) — Aggregation for numerical values.
