Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • If a row contains a missing or null value, it is not factored into the calculation. If the entire column contains no values, the function returns a null value.
  • If there is a tie in which the most occurrences of a value is shared between values, then no value the lowest value of the evaluated set of values is returned from the function.
  • When used in a pivot transform, the function is computed for each instance of the value specified in the group parameter. See Pivot Transform.

For a version of this function computed over a rolling window of rows, see ROLLINGMODE Function.

D s
snippetBasic

D lang syntax
RawWrangletrue
Typeref
showNotetrue
WrangleTextpivot value:mode(count_visits) group:postal_code limit:1

...

mode(count_visits)

Output: Returns the mode of the values in the count_visits column.

D s
snippetSyntax

D lang syntax
RawWrangletrue
Typesyntax
showNotetrue
WrangleTextpivot value

...

:

...

mode(function_col_ref) [group:group_col_ref] [limit:limit_count]


ArgumentRequired?Data TypeDescription
function_col_refYstringName of column to which to apply the function

...