Skip to main content Skip to complementary content

Choice

Chooses a value from a set of values based on conditions.

The Choice function is used to provide a value according to a condition from a list of conditions. It is similar to a collection of nested IfThenElse functions but more compact.

Any number of ChoiceValue functions are provided as arguments. Each ChoiceValue function provides a condition and value pair; the value is emitted when the first condition is satisfied.

One of the ChoiceValue functions may be marked as a default value and that value is emitted if no other condition is satisfied.

Arguments

Variable arguments Add as many ChoiceValue functions as needed to specify conditions and values.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!