choose
Purpose
The function is used to find the first, the last, the shortest or the longest result in a specific document range.
Arguments
The function accepts one required argument which can be a string or a pdl-function.
The function accepts the following optional named parameters:
-
mode:=shortest/longest/first/last matches the shortest/longest/first/last argument’s result respectively.
-
scope:=sentence/line/paragraph/text limits the search range to a sentence/line/paragraph/text respectively. By default scope:=text.
It is possible to mix mode values to specify a search, using an underscore ("_"): shortest_first, last_longest.