The Mode function finds the value (or values) repeated more often than any other in a value series.
The Mode function requires the following input:
- d0 - The set of data values for which the Mode is calculated.
The Mode function accepts the following parameters:
- Alignments... (One or More, Optional) – Hierarchy placeholders to be used as the alignment axis. Input values are grouped by the specified hierarchy values, and the mode calculated for each group: e.g., MODE($Quantity$, $Country$) calculates the mode for each country.
The Mode function generates the following output:
- Mode - One or more values representing the mode of the input values (for each group when using alignment parameters).
This can include multiple values if they each occur the same number of times, and mode values are therefore not repeated in every row when used in a formula measure.
When used in a formula visualization where there are multiple mode values, they will be aggregated according to the aggregator setting of the measure, which is Sum by default. You can change the aggregator to Minimum or Maximum instead, for example, to choose which mode to display.