Function Description
| Category | Description |
|---|---|
| Syntax | MEDIAN(number) |
| Function | Returns the median of the number values for the current analysis dimension. |
| Parameter | number: the numeric values used to calculate the median |
| Number of Parameters | 1 |
| Parameter Type | Number |
| Return Value Type | Number |
| Notes | Aggregate functions can be used only when you add a metric to a chart. They cannot be used in analysis tables. |
Examples
When the date field in Row Dimension is set to day granularity, the metric MEDIAN([Sales Volume]) returns the median sales volume for each day.
When the date field in Row Dimension is set to month granularity, the metric MEDIAN([Sales Volume]) returns the median sales volume for each month.
To calculate the median contract amount for each year, use the formula MEDIAN([Contract Amount]).

If you change the dimension to year-month granularity, the chart shows the median contract amount for each month.
