ReferenceFunctionsLookup Functions
CHOOSE
CHOOSE: Returns one value from a list using a 1-based index.
Summary
CHOOSE selects from value1, value2, ... based on index_num.
Remarks
index_numis 1-based and is truncated to an integer.- Indexes less than 1 or greater than the number of choices return
#VALUE!. - Errors in
index_numare propagated. - The selected argument is returned as-is, including non-text/non-numeric values.
Examples
Select a label
Grid
| Cell | Value | |
|---|---|---|
| No inputs on Sheet1. | ||
Formula
=
Result
Not evaluated yet.
Expected
Medium
Use numeric choices
Grid
| Cell | Value | |
|---|---|---|
| No inputs on Sheet1. | ||
Formula
=
Result
Not evaluated yet.
Expected
30
Related functions
FAQ
How are decimal index_num values handled?
The index is truncated toward zero before selection, so CHOOSE(2.9,...) selects the second argument.
What error do I get for index_num 0 or too large?
CHOOSE returns #VALUE! when index_num is less than 1 or greater than the number of provided choices.
Runtime metadata
Category
Lookup
Signature
CHOOSE(arg1: Number, arg2: Any)Arity
min 2, max 2
Arguments
arg1Number · Scalar · coercion NumberStrict
arg2repeating 1Any · Scalar
Caps
PURELOOKUP
Source