Sub topic 3
How CHOOSE works
This chapter covers the CHOOSE function by itself, before it is connected to a dropdown or to MATCH. It assumes you can write basic formulas in Excel or Google Sheets and know the difference between $A$1 and A1. It also assumes you know how a simple model separates inputs, calculations and outputs, and that you are comfortable with IF. CHOOSE behaves the same way in Excel and Google Sheets.
What CHOOSE does
CHOOSE picks one item from a list, based on a position number. The syntax is:
=CHOOSE(index_num, value1, value2, value3, ...)index_numis the position you want. It must be a number from 1 up to the number of values you supplied.value1, value2, ...are the candidates. Excel accepts up to 254 of them.
The function counts through the values and returns the one at the position given by index_num.
=CHOOSE(2, "Base", "Upside", "Downside")This returns Upside, because "Upside" is the second value in the list.
The function does not know what the values mean. It does not compare anything or look anything up. It only counts. That makes it fast and predictable, but the position must always be correct.
The mental model: a numbered row of boxes
Think of the values as numbered boxes in a row. The index is the number you call out, and CHOOSE hands you the contents of that box.
In a scenario model, the three values are the same driver under three scenarios, for example revenue growth. The index says which scenario is active.
Values can be anything
The values do not have to be typed constants. Each one can be:
- A number or text typed into the formula.
- A cell reference, such as
E12. - Another formula, such as
E12*1.1. - A range, such as
E12:E20. In that caseCHOOSEreturns a reference, so functions likeSUMcan use it.
In financial models, the values are almost always cell references. Typing numbers into the formula would bury assumptions inside calculations, which defeats the purpose of centralized assumptions.
The scenario formula used throughout this tutorial is:
=CHOOSE($C$4, E12, F12, G12)Here C4 holds the scenario index. E12, F12 and G12 hold revenue growth for Base, Upside and Downside. If C4 is 1 the formula returns the value in E12. If C4 is 3 it returns the value in G12.
A worked example
Suppose the assumptions sheet has this layout. Row 12 holds revenue growth. Columns E, F and G are the three scenarios.
| Row | D (Driver) | E (Base) | F (Upside) | G (Downside) |
|---|---|---|---|---|
| 11 | Scenario | Base | Upside | Downside |
| 12 | Revenue growth | 5% | 10% | -2% |
| 13 | Gross margin | 40% | 44% | 35% |
C4 is the scenario index. Place the live value in column H:
=CHOOSE($C$4, E12, F12, G12)Now see what happens as C4 changes:
| C4 | Formula picks | Result |
|---|---|---|
| 1 | E12 | 5% |
| 2 | F12 | 10% |
| 3 | G12 | -2% |
Copy the formula down one row to get gross margin in H13:
=CHOOSE($C$4, E13, F13, G13)Notice the reference styles. $C$4 is absolute, so it stays fixed when you copy the formula to other rows. E12, F12 and G12 are relative, so they move down with the row. This pairing, one fixed index and relative value references, is what makes the formula copyable across every driver.
If you copy the formula to the right instead, the relative references would shift to F12, G12 and H12, which is wrong. Copy down, not across, or lock the columns with $E12, $F12 and $G12.
Why not nested IF?
You could build the same switch with IF:
=IF($C$4=1, E12, IF($C$4=2, F12, G12))This works, but it has drawbacks:
- Each extra scenario adds another nesting level, and the formula becomes harder to read.
- The last
IFsilently treats every other number as scenario 3. An index of 7, or 0, returns the Downside value instead of an error. - It repeats
$C$4=for every branch.
CHOOSE states the intent directly: "pick the nth of these". It also fails loudly when the index is invalid, which is a useful property in a model, as the next section shows.
What CHOOSE does with a bad index
Three behaviors matter in practice.
Out-of-range index. An index below 1 or above the number of values returns #VALUE!.
=CHOOSE(4, "Base", "Upside", "Downside")This returns #VALUE! because there is no fourth value. The same happens with CHOOSE(0, ...). That error propagates into everything that depends on the formula, so you notice the problem immediately instead of getting a quietly wrong forecast.
Decimal index. A fractional index is truncated down to a whole number, not rounded.
=CHOOSE(2.9, "Base", "Upside", "Downside")This returns Upside, because 2.9 becomes 2. A calculation that produces 2.9999 will therefore pick position 2, which may not be what you intended. Indexes should come from MATCH or typed whole numbers, not from arithmetic that can produce fractions.
Text index. Text that looks like a number, such as "2", is converted to a number. Text that is not numeric returns #VALUE!.
=CHOOSE("Upside", E12, F12, G12)This returns #VALUE!. CHOOSE cannot turn a scenario name into a position. The name has to be converted to a number first, and the chapter on MATCH covers how.
A blank cell as the index is treated as 0, so it also returns #VALUE!.
The order of values is the contract
CHOOSE has no labels. Position 2 is "Upside" only because you decided the second argument would be the Upside cell. The scenario list used for the dropdown, the column order on the assumptions sheet and the argument order in every CHOOSE formula must all agree.
Here is a typical mistake. The assumptions columns are ordered Base, Upside, Downside, but one formula was written with the last two swapped:
=CHOOSE($C$4, E12, G12, F12)Selecting Upside (index 2) now returns the Downside value from G12. Nothing shows an error. The model simply gives wrong answers for two of the three scenarios. Because the formula is valid, only a review or a check will catch it. The last chapter of this tutorial covers such checks.
A practical habit helps: write every scenario formula with the same shape, referencing the columns left to right in the same order as the scenario list. Then a reviewer can scan a column of formulas and spot the one that differs.
Using CHOOSE with ranges
Because CHOOSE can return a reference, one formula can switch between whole blocks.
=SUM(CHOOSE($C$4, E12:E20, F12:F20, G12:G20))This sums the nine cells of whichever scenario column is selected. It is useful when a scenario is a block of values, such as monthly revenue across a year.
For most models, though, the cleaner design is one live case row (covered later in this tutorial) with a CHOOSE per driver, and calculations that refer only to that row.
A few practical rules
- Keep the index in one cell and refer to it with an absolute reference such as
$C$4. - Reference assumption cells. Do not type numbers into the
CHOOSEarguments. - Keep scenario order identical everywhere: the dropdown list, the assumption columns and the formulas.
- Treat
#VALUE!fromCHOOSEas a signal about the index, not as something to hide withIFERROR. Wrapping the formula inIFERRORcan turn a broken switch into a plausible-looking zero. - Keep the number of values equal to the number of scenarios. If you add a fourth scenario, every
CHOOSEformula needs a fourth argument.
Common errors at a glance
| Symptom | Likely cause | Fix |
|---|---|---|
| `#VALUE!` in every live case cell | Index is 0, blank, above the number of values, or non-numeric text | Check the index cell and how it is computed |
| `#VALUE!` when passing a scenario name | `CHOOSE` needs a number, not a name | Convert the name to a number first |
| Wrong values for one scenario only | Arguments in a different order from the other formulas | Rewrite so every formula uses the same column order |
| Values change when the formula is copied across | Relative column references shifted | Copy down only, or anchor columns with `$E12` |
| Scenario 2 behaves like scenario 1 | Index computed as a fraction and truncated | Use whole numbers from `MATCH` |
Try it yourself
Build a small test sheet before moving on.
- Type
Base,UpsideandDownsideintoE11:G11. - Enter 5%, 10% and -2% in
E12:G12. - Type
2intoC4. - In
H12, enter=CHOOSE($C$4, E12, F12, G12)and confirm it shows 10%. - Change
C4to 1, 3, 0 and 4 and observe the results.
You should see 5%, -2%, #VALUE! and #VALUE!. Seeing the errors yourself makes them easy to recognize later in a larger model.
Exercise
A model has the formula =CHOOSE($C$4, E12, F12, G12) in H12, with Base in column E, Upside in column F and Downside in column G. C4 contains 3. Which cell does the formula return, and what does it return if C4 contains 2.7?
Show answer
With C4 = 3, the formula returns the value in G12, the Downside assumption. With C4 = 2.7, CHOOSE truncates the index to 2 and returns the value in F12, the Upside assumption. It does not round up to 3.
Exercise
A colleague writes =CHOOSE($C$4, E12, G12, F12) while every other scenario formula uses E, F, G order. The dropdown lists Base, Upside, Downside. What goes wrong when the user selects Upside, and why does Excel show no error?
Show answer
Upside is index 2, so the formula returns the second argument, G12, which holds the Downside value. Excel shows no error because the index is valid and the formula is syntactically correct. CHOOSE only counts positions, so it cannot detect that the arguments are in a different order from the scenario list.
Exercise
What does =CHOOSE("Downside", E12, F12, G12) return, and what must change so the formula returns the Downside value?
Show answer
It returns #VALUE!, because CHOOSE needs a numeric position and "Downside" is not a number. The index must be 3. Use a cell that holds 3, for example one produced by MATCH from the scenario name, instead of the name itself.