CHOOSE Function in Excel

✨ Part 1. Introduce:

🔹 Definition: The CHOOSE function in Microsoft Excel is a powerful and versatile function that allows you to return a value from a list of choices based on a given index number. It helps you select and retrieve a specific value from multiple options without using nested IF functions.

🔹 Purpose: The purpose of the CHOOSE function is to simplify decision-making in Excel by providing a concise way to select a value based on a given position (index) within a list. Instead of using multiple nested IF statements, the CHOOSE function allows you to handle different scenarios efficiently.

🔹 Syntax & Arguments: The syntax of the CHOOSE function is as follows:

Excel
=CHOOSE(index_num, value1, [value2], ...)
  • index_num: The index number specifies the value position you want to return. It should be a positive integer (1, 2, 3, etc.).
  • value1, [value2], …: The list of values you want to choose from. You can include up to 254 values separated by commas.

🔹 Explain the Arguments in the function:

  • The index_num argument is essential, as it determines which value from the list of choices will be returned. It corresponds to the position of the desired value in the list.
  • The value1, [value2], ... arguments represent the different options or values you want to choose from. These can be numeric values, text strings, cell references, or other functions.

🔹 Return Value: The CHOOSE function returns the value specified  index_num from the list of choices (value1, [value2], ...). If the index_num is less than 1 or greater than the number of choices provided, the function returns a #VALUE! Error.

🔹 Remarks:

  • The CHOOSE function is handy when you have a known set of options and must select one based on a numeric input or condition.
  • It is crucial to ensure that the index_num is valid, as any errors or mismatches can result in unexpected results or errors.

✨ Part 2. Examples:

🔹 Example 1: Suppose we have a table that lists different products and their corresponding prices. We want to select the price of a product based on the product’s position in the list.

AB
1ProductPrice
2Product A10
3Product B15
4Product C20

In this example, let’s say we want to select the price of “Product B.”

Step 1: Create a new table to display the selected price:

AB
1ProductSelected Price
2Product B

Step 2: In cell B2 of the second table, enter the following formula using the CHOOSE function:

Excel
=CHOOSE(MATCH(A2, 'Sheet1'!A2:A4, 0), 'Sheet1'!B2, 'Sheet1'!B3, 'Sheet1'!B4)

Step 3: The formula will return the price of “Product B” (15) in cell B2.

Explanation: The CHOOSE function is nested with the MATCH function to determine the position (index) of “Product B” in the list. The MATCH function finds the row number in which “Product B” is located (‘Sheet1’!A2:A4), and the CHOOSE function returns the corresponding price from the list (‘Sheet1’!B2:B4).

🔹 Example 2: Consider a scenario with a list of employees and their respective departments. We want to choose the department of a specific employee based on their position in the list.

AB
1EmployeeDepartment
2JohnHR
3SarahFinance
4MichaelIT

In this example, let’s say we want to select the department of “Sarah.”

Step 1: Create a new table to display the selected department:

AB
1EmployeeSelected Department
2Sarah

Step 2: In cell B2 of the second table, enter the following formula using the CHOOSE function:

Excel
=CHOOSE(MATCH(A2, 'Sheet1'!A2:A4, 0), 'Sheet1'!B2, 'Sheet1'!B3, 'Sheet1'!B4)

Step 3: The formula will return the “Sarah” (Finance) department in cell B2.

Explanation: Similar to the previous example, the CHOOSE function is nested with the MATCH function to determine the position (index) of “Sarah” in the list. The MATCH function finds the row number in which “Sarah” is located (‘Sheet1’!A2:A4), and the CHOOSE function returns the corresponding department from the list (‘Sheet1’!B2:B4).

🔹 Example 3: We want to select a specific fruit from a list based on a numeric input representing its position.

A
1Index
22

Suppose we have the following list of fruits:

A
1Fruits
2Apple
3Banana
4Orange

Step 1: Create a new table to display the selected fruit:

AB
1IndexSelected Fruit
22

Step 2: In cell B2 of the second table, enter the following formula using the CHOOSE function:

Excel
=CHOOSE(A2, 'Sheet1'!A2, 'Sheet1'!A3, 'Sheet1'!A4)

Step 3: The formula will return “Banana” (the second fruit in the list) in cell B2.

Explanation: In this example, the CHOOSE function takes the numeric input (the index) from cell A2 and returns the corresponding fruit from the list (‘Sheet1’!A2:A4).

🔹 Example 4: Suppose we have a table of sales data with different products and their corresponding sales figures for each month. We want to calculate the total sales for a specific product based on the selected month.

ABC
1ProductJanFeb
2Product A100150
3Product B200180

Step 1: Create a new table to display the total sales for a specific product based on the selected month:

ABCD
1ProductMonthTotal SalesSelected Product
2Product AJanProduct B
3Product BFeb

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the IF function:

Excel
=IF(B2="Jan", CHOOSE(2, B2:C2), CHOOSE(3, B2:C2))

Step 3: In cell D2, enter the formula ="Product B" to select “Product B” for the second example.

Explanation: The CHOOSE function is nested with the IF function to conditionally select the appropriate sales figure based on the selected month. If “Jan” is set in cell B2, CHOOSE(2, B2:C2) will return the sales figure for January, and if “Feb” is selected, CHOOSE(3, B2:C2) will produce the sales figure for February.

🔹 Example 5: Consider a table of students’ test scores for different subjects. We want to determine if a student has passed or failed each subject based on the passing score.

ABCD
1StudentMathSciencePassing Score
2John859290
3Sarah788590

Step 1: Create a new table to display if a student has passed or failed each subject:

ABCDE
1StudentMathSciencePassing ScoreResult
2John859290
3Sarah788590

Step 2: In cell E2 of the second table, enter the following formula using the CHOOSE function nested with the IF function:

Excel
=IF(B2>=D2, CHOOSE(1, "Pass", "Fail"), CHOOSE(1, "Fail", "Pass"))

Step 3: Drag the formula to fill the remaining cells in column E.

Explanation: The CHOOSE function is nested with the IF function to determine if a student’s test score is greater than or equal to the passing score. If the score equals or exceeds the passing score, the CHOOSE function returns “Pass,”. If not, it replaces “Fail.”

🔹 Example 6: This example has a table with different discount rates for different customer levels. We want to calculate the discounted price for a specific customer based on their level.

AB
1Customer LevelDiscount Rate
2Silver5%
3Gold10%

Step 1: Create a new table to display the discounted price for a specific customer level:

ABC
1Customer LevelPriceDiscounted Price
2Silver100
3Gold150

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the VLOOKUP function:

Excel
=B2 - (B2 * VLOOKUP(A2, 'Sheet1'!A2:B3, 2, FALSE) / 100)

Step 3: Drag the formula to fill the remaining cells in column C.

Explanation: The VLOOKUP function is nested with the CHOOSE function to retrieve the discount rate based on the customer level from the table on ‘Sheet1’. The CHOOSE function then calculates the discounted price by subtracting the appropriate discount from the original price.

🔹 Example 7: Let’s consider a table with different expenses for different departments. We want to calculate the total costs for a specific department based on the department name.

AB
1DepartmentExpense
2HR1000
3Finance2000

Step 1: Create a new table to display the total expenses for a specific department:

ABC
1DepartmentSelected DepartmentTotal Expenses
2HRFinance
3Finance

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the SUMIF function:

Excel
=SUMIF('Sheet1'!A2:A3, A2, 'Sheet1'!B2:B3)

Step 3: In cell C3, enter the formula =SUMIF('Sheet1'!A2:A3, A3, 'Sheet1'!B2:B3) to calculate the total expenses for the “Finance” department.

Explanation: The CHOOSE function is not directly used in this example, but it demonstrates how other functions (in this case, SUMIF) can be combined to perform specific calculations. The SUMIF function calculates the total expenses for the selected department by summing the costs for the corresponding department on ‘Sheet1’.

🔹 Example 8: Suppose we have a table with different product categories and their respective sales for other regions. We want to find the total sales for a specific category across all regions.

ABCD
1CategoryRegion 1Region 2Region 3
2Category A100150120
3Category B200180160

Step 1: Create a new table to display the total sales for a specific category across all regions:

ABCDE
1CategoryRegion 1Region 2Region 3Total Sales
2Category A
3Category B

Step 2: In cell B2 of the second table, enter the following formula using the CHOOSE function nested with the SUM function:

Excel
=SUM(CHOOSE(COLUMN(B2:D2), B2, C2, D2))

Step 3: Drag the formula to fill the remaining cells in column E.

Explanation: The CHOOSE function is nested with the SUM function to sum the sales for a specific category across all regions. The CHOOSE function selects the sales from the corresponding columns based on the column number (using the COLUMN function) and passes them to the SUM function.

🔹 Example 9: Consider a table of different products and their respective prices for other countries. We want to calculate the price of a specific product for a selected country.

ABCD
1ProductUSACanadaUK
2Product A101512
3Product B201825

Step 1: Create a new table to display the price of a specific product for a selected country:

ABC
1ProductCountryPrice
2Product AUSA
3Product BUK

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the VLOOKUP function:

Excel
=VLOOKUP(A2, 'Sheet1'!A2:D3, CHOOSE(MATCH(B2, 'Sheet1'!B1:D1, 0), 2, 3, 4), FALSE)

Step 3: Drag the formula to fill the remaining cells in column C.

Explanation: The CHOOSE function is nested with the MATCH function to find the column number corresponding to the selected country. The VLOOKUP function then retrieves the price of the specified product for the chosen country from the table on ‘Sheet1’.

🔹 Example 10: Suppose we have a table with different investments and their respective returns for other years. We want to calculate the total return for a specific investment based on the selected year.

ABCD
1Investment202020212022
2Investment A5%10%8%
3Investment B8%12%15%

Step 1: Create a new table to display the total return for a specific investment based on the selected year:

ABCDE
1InvestmentYearTotal ReturnSelected InvestmentSelected Year
2Investment A2021Investment B2022
3Investment B2022

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the IF and VLOOKUP functions:

Excel
=IF(B2=2020, CHOOSE(2, B2:D2), IF(B2=2021, CHOOSE(3, B2:D2), CHOOSE(4, B2:D2)))

Step 3: In cell C3, enter the formula =VLOOKUP(B3, 'Sheet1'!A2:D3, 2, FALSE) to calculate the total return for Investment B in the year 2022.

Explanation: The CHOOSE function is nested with the IF function to select the appropriate range of returns based on the selected year. The CHOOSE function will return the corresponding return percentage for the chosen investment depending on the year set.

🔹 Example 11: Let’s consider a table with different expenses for different categories, and we want to determine the highest expense among them.

AB
1CategoryExpense
2Utilities1000
3Office Supplies800
4Travel1200

Step 1: Create a new table to display the highest expense among the categories:

AB
1Highest Expense
2

Step 2: In cell B2 of the second table, enter the following formula using the CHOOSE function nested with the MAX function:

Excel
=CHOOSE(MATCH(MAX('Sheet1'!B2:B4), 'Sheet1'!B2:B4, 0), "Utilities", "Office Supplies", "Travel")

Step 3: The formula will return “Travel” (the category with the highest expense) in cell B2.

Explanation: The CHOOSE function is nested with the MATCH function to find the position (index) of the most increased cost in the list of charges on ‘Sheet1’. The MAX function determines the highest expense value among the categories, and the CHOOSE function returns the corresponding category name.

🔹 Example 12: In this example, we want to determine the letter grade for a specific student based on their test score.

AB
1StudentScore
2John85
3Sarah78
4Michael92

Step 1: Create a new table to display the letter grade for each student:

ABC
1StudentScoreLetter Grade
2John85
3Sarah78
4Michael92

Step 2: In cell C2 of the second table, enter the following formula using the CHOOSE function nested with the IF function:

Excel
=CHOOSE(IF(B2>=90, 1, IF(B2>=80, 2, IF(B2>=70, 3, IF(B2>=60, 4, 5)))), "A", "B", "C", "D", "F")

Step 3: Drag the formula to fill the remaining cells in column C.

Explanation: The CHOOSE function is nested with multiple IF functions to determine the letter grade based on the test score. The CHOOSE function returns the corresponding letter grade (A, B, C, D, or F) depending on the score range.

These examples demonstrate how the CHOOSE function can be nested with different functions to perform various calculations and decision-making tasks in Excel. Combining the CHOOSE function with other functions allows you to create more advanced and dynamic formulas to handle various spreadsheet scenarios.

✨ Part 3. Tips and Tricks:

  • Validating Index: Always ensure that the index number provided to the CHOOSE function is within the valid range (1 to the number of values provided). The function will return an error if the index is out of range.
  • Dynamic Range: To create more dynamic formulas with the CHOOSE function, consider using the INDEX and ROW functions to dynamically define the range of values. This can be especially helpful when dealing with large datasets or when the number of choices can change.
  • Avoid Nested CHOOSE: While the CHOOSE function helps select values from a list, avoid nesting multiple CHOOSE functions excessively. It can make your formulas hard to read and maintain.
  • Data Consistency: Ensure that the list of values provided to the CHOOSE function is consistent regarding data type and format. Mixing different data types may lead to unexpected results.
  • Valid for Dropdown Lists: The CHOOSE function can be combined with the Data Validation feature in Excel to create dynamic dropdown lists that allow users to select values from a predefined list quickly.
  • Combining with INDEX and MATCH: The CHOOSE function can be more powerful when combined with INDEX and MATCH functions to retrieve values based on specific criteria.

The CHOOSE function is a handy tool that simplifies decision-making and value selection in Excel. It can be an efficient alternative to nested IF statements when dealing with multiple options. Always ensure that the index is valid and that the list of choices is consistent to get accurate and reliable results.

Leave a Comment