国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

Home Topics excel CHOOSE function in Excel with formula examples

CHOOSE function in Excel with formula examples

Apr 07, 2025 am 10:02 AM

This tutorial explores the versatile Excel CHOOSE function, demonstrating its syntax, basic usage, and advanced applications beyond its initial appearance. While seemingly simple, combining CHOOSE with other functions unlocks powerful capabilities. The core function retrieves a value from a list based on its position.

  • Excel CHOOSE Function: Syntax and Basic Uses
  • Advanced Applications of the CHOOSE Function:
    • Replacing Nested IF Statements
    • Generating Random Data
    • Performing Left Lookups (alternative to VLOOKUP limitations)
    • Calculating the Next Working Day
    • Retrieving Custom Day/Month Names from Dates

Excel CHOOSE Function: Syntax and Basic Uses

The CHOOSE function returns a value from a list, determined by its index number. Available in Excel 365, 2019, 2016, 2013, 2010, and 2007, its syntax is:

CHOOSE(index_num, value1, [value2], ...)

  • index_num: (Required) The position (1 to 254) of the desired value. Can be a number, cell reference, or formula.
  • value1, value2, ...: (Required and Optional) Up to 254 values to choose from. Can be numbers, text, cell references, formulas, or named ranges.

Example: =CHOOSE(3, "Mike", "Sally", "Amy", "Neal") returns "Amy" (3rd value).

CHOOSE function in Excel with formula examples

Key Considerations:

  1. Value limit: A maximum of 254 values are allowed.
  2. index_num range: Must be between 1 and the number of values; otherwise, a #VALUE! error occurs.
  3. Fractional index_num: Truncated to the nearest whole number.

Advanced Applications of the CHOOSE Function

These examples showcase CHOOSE's power when combined with other functions:

1. Replacing Nested IF Statements:

Instead of complex nested IF statements, CHOOSE offers a concise alternative for conditional value returns.

Example: Assign grades based on scores:

Result Score Range
Poor 0 - 50
Satisfactory 51 - 100
Good 101 - 150
Excellent >150

Nested IF: =IF(B2>=151, "Excellent", IF(B2>=101, "Good", IF(B2>=51, "Satisfactory", "Poor")))

CHOOSE Alternative: =CHOOSE((B2>=0) (B2>=51) (B2>=101) (B2>=151), "Poor", "Satisfactory", "Good", "Excellent")

CHOOSE function in Excel with formula examples

This leverages TRUE/FALSE values (1/0) to determine the index. Error handling (e.g., IFERROR) can prevent #VALUE! errors if no condition is met.

2. Generating Random Data:

Combine CHOOSE with RANDBETWEEN to create random data selections.

Example: Generate random exam results:

=CHOOSE(RANDBETWEEN(1,4), "Poor", "Satisfactory", "Good", "Excellent")

CHOOSE function in Excel with formula examples

Note: RANDBETWEEN is volatile; results change with worksheet updates. Use "Paste Special" to fix values.

3. Left VLOOKUP:

Circumvent VLOOKUP's limitation of searching only the leftmost column using CHOOSE.

Example: Retrieve scores given student names (score column is to the left of names).

=VLOOKUP(E1,CHOOSE({1,2}, B2:B5, A2:A5),2,FALSE)

CHOOSE function in Excel with formula examples

CHOOSE swaps the column order within the VLOOKUP's table_array argument.

4. Determining the Next Working Day:

Calculate the next workday (Monday-Friday).

=TODAY() CHOOSE(WEEKDAY(TODAY()),1,1,1,1,1,3,2)

CHOOSE function in Excel with formula examples

This adds the appropriate number of days based on the current day of the week.

5. Custom Day/Month Names:

Retrieve day or month names in custom formats.

Day: =CHOOSE(WEEKDAY(A2),"Su","Mo","Tu","We","Th","Fr","Sa")

Month: =CHOOSE(MONTH(A2), "Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec")

CHOOSE function in Excel with formula examples

These examples highlight the CHOOSE function's flexibility and potential for creating efficient and readable Excel formulas. Download the practice workbook for hands-on experience.

The above is the detailed content of CHOOSE function in Excel with formula examples. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undress AI Tool

Undress AI Tool

Undress images for free

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)