Home Topics excel Excel MAX function - formula examples to find highest value

Excel MAX function - formula examples to find highest value

Apr 03, 2025 am 10:07 AM

This tutorial explores the Excel MAX function, providing numerous formula examples to find the highest value and highlight the largest number in your spreadsheet. While simple to use, the MAX function offers advanced techniques. This guide covers conditional MAX formulas, extracting the absolute largest value, and more.

  • Creating a MAX Formula
  • Excel MAX Function Examples
    • Finding the Max Value in a Group
    • Max Formula for Non-Adjacent Cells or Ranges
    • Finding the Max Date
    • Conditional MAX Formulas
    • Finding the Max Value, Ignoring Zeros
    • Finding the Largest Number, Ignoring Errors
    • Finding the Absolute Maximum Value
  • Highlighting the Max Value
  • Troubleshooting the Excel MAX Function

The Excel MAX Function

The Excel MAX function identifies the highest value within a specified dataset.

Syntax:

MAX(number1, [number2], ...) where number can be a numeric value, array, named range, or cell/range reference containing numbers. Number1 is required; subsequent arguments are optional.

The MAX function is compatible with all Excel versions (Office 365, 2019, 2016, 2013, 2010, 2007, and earlier).

Creating a MAX Formula

The simplest MAX formula directly inputs numbers: =MAX(1, 2, 3). However, you'll typically use cell and range references.

The quickest method to find the largest value in a range (e.g., A1:A6):

  1. Enter =MAX( in a cell.
  2. Select the number range (A1:A6).
  3. Add the closing parenthesis ).
  4. Press Enter. The formula will be =MAX(A1:A6).

For contiguous rows/columns, Excel's AutoSum feature provides a shortcut:

  1. Select the number cells.
  2. On the Home tab, click AutoSum and choose Max. (Alternatively, use Formulas > AutoSum > Max).

This inserts a MAX formula in the cell below the selection. Ensure a blank cell exists beneath the selected numbers.

Excel MAX function - formula examples to find highest value

Key MAX Function Considerations:

  1. Current Excel versions support up to 255 arguments in a MAX formula.
  2. If no numbers are present, MAX returns zero.
  3. Errors within arguments result in an error return.
  4. Empty cells are ignored.
  5. Direct input of logical values and text numbers are processed (TRUE=1, FALSE=0). References to logical/text values are ignored.

Excel MAX Function Examples

This section demonstrates common MAX function applications. Multiple solutions are often available; experiment to find the best fit for your data.

Finding the Max Value in a Group:

Use a range reference for the group (e.g., C2:E7): =MAX(C2:E7)

Excel MAX function - formula examples to find highest value

Max Formula for Non-Adjacent Cells/Ranges:

For non-contiguous selections, reference each cell/range individually. Use Ctrl-click to select multiple areas: =MAX(C5:E5, C9:E9)

Excel MAX function - formula examples to find highest value

Finding the Max Date:

Dates are treated as serial numbers; use a standard MAX formula: =MAX(C2:C7)

Excel MAX function - formula examples to find highest value

Conditional MAX Formulas:

Several approaches exist for finding the maximum value based on criteria. The following examples use the same dataset: items in B2:B15, sales in C2:C15, and the target item in F1.

  • Excel MAX IF Formula (Array Formula): =MAX(IF(B2:B15=F1, C2:C15)) (Ctrl Shift Enter)

  • Non-Array MAX IF Formula: =SUMPRODUCT(MAX((B2:B15=F1)*(C2:C15)))

  • MAXIFS Function (Excel 2019 and Office 365): =MAXIFS(C2:C15, B2:B15, F1)

Excel MAX function - formula examples to find highest value

Get Max Value, Ignoring Zeros:

This is a conditional MAX variation. Use "not equal to 0" in MAXIFS or MAX IF criteria. This is primarily useful with negative numbers. For example, to find the lowest (most negative) discount in C2:C7:

  • MAX IF (Array Formula): =MAX(IF(C2:C70, C2:C7)) (Ctrl Shift Enter)
  • MAXIFS: =MAXIFS(C2:C7,C2:C7,"0")

Excel MAX function - formula examples to find highest value

Find Highest Value, Ignoring Errors:

Errors in referenced cells propagate to the MAX function. Solutions include:

  • MAX IF with ISERROR (Array Formula): =MAX(IF(ISERROR(A1:B5),"",A1:B5)) (Ctrl Shift Enter)
  • MAX IF with IFERROR (Array Formula): =MAX(IFERROR(A1:B5,"")) (Ctrl Shift Enter)
  • MAXIFS (Limited Use): =MAXIFS(A1:B5,A1:B5,">=0") (Only works if at least one non-negative number exists)
  • AGGREGATE Function: =AGGREGATE(4, 6, A1:B5) (4=MAX, 6=ignore errors)

Excel MAX function - formula examples to find highest value

Finding the Absolute Maximum Value:

For positive and negative numbers, find the largest absolute value:

  • Array Formula: =MAX(ABS(A1:B5)) (Ctrl Shift Enter)
  • Regular Formula: =MAX(MAX(A1:B5), -MIN(A1:B5)) or =MAX(MAX(A1:B5), ABS(MIN(A1:B5)))

Excel MAX function - formula examples to find highest value

Return Maximum Absolute Value with Sign:

To retain the original sign: =IF(ABS(MAX(A1:B5))>ABS(MIN(A1:B5)), MAX(A1:B5), MIN(A1:B5))

Excel MAX function - formula examples to find highest value

Highlighting the Max Value

Conditional formatting offers a visual way to identify the largest number.

Highlight Highest Number in a Range:

Use Excel's built-in "Top or Bottom Ranked Values" rule.

Highlight Max Value in Each Row/Column:

Create a custom rule using a MAX formula (e.g., =C2=MAX($C2:$E2) for rows, =C2=MAX(C$2:C$7) for columns).

Excel MAX function - formula examples to find highest value Excel MAX function - formula examples to find highest value

Troubleshooting the Excel MAX Function

  • MAX Returns Zero: Check for text-formatted numbers. Use =ISNUMBER(A1) to verify numeric data.
  • MAX Returns Errors: Examine referenced cells for errors. Use error-handling techniques (like AGGREGATE) to manage errors.

This comprehensive guide provides a solid foundation for utilizing the Excel MAX function effectively. Remember to adapt these examples to your specific data and requirements.

The above is the detailed content of Excel MAX function - formula examples to find highest value. 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

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.

Undress AI Tool

Undress AI Tool

Undress images for free

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)

Hot Topics

Java Tutorial
1655
14
PHP Tutorial
1252
29
C# Tutorial
1226
24
How to use Flash Fill in Excel with examples How to use Flash Fill in Excel with examples Apr 05, 2025 am 09:15 AM

This tutorial provides a comprehensive guide to Excel's Flash Fill feature, a powerful tool for automating data entry tasks. It covers various aspects, from its definition and location to advanced usage and troubleshooting. Understanding Excel's Fla

MEDIAN formula in Excel - practical examples MEDIAN formula in Excel - practical examples Apr 11, 2025 pm 12:08 PM

This tutorial explains how to calculate the median of numerical data in Excel using the MEDIAN function. The median, a key measure of central tendency, identifies the middle value in a dataset, offering a more robust representation of central tenden

Excel shared workbook: How to share Excel file for multiple users Excel shared workbook: How to share Excel file for multiple users Apr 11, 2025 am 11:58 AM

This tutorial provides a comprehensive guide to sharing Excel workbooks, covering various methods, access control, and conflict resolution. Modern Excel versions (2010, 2013, 2016, and later) simplify collaborative editing, eliminating the need to m

How to spell check in Excel How to spell check in Excel Apr 06, 2025 am 09:10 AM

This tutorial demonstrates various methods for spell-checking in Excel: manual checks, VBA macros, and using a specialized tool. Learn to check spelling in cells, ranges, worksheets, and entire workbooks. While Excel isn't a word processor, its spel

Excel: Group rows automatically or manually, collapse and expand rows Excel: Group rows automatically or manually, collapse and expand rows Apr 08, 2025 am 11:17 AM

This tutorial demonstrates how to streamline complex Excel spreadsheets by grouping rows, making data easier to analyze. Learn to quickly hide or show row groups and collapse the entire outline to a specific level. Large, detailed spreadsheets can be

Absolute value in Excel: ABS function with formula examples Absolute value in Excel: ABS function with formula examples Apr 06, 2025 am 09:12 AM

This tutorial explains the concept of absolute value and demonstrates practical Excel applications of the ABS function for calculating absolute values within datasets. Numbers can be positive or negative, but sometimes only positive values are neede

Google Spreadsheet COUNTIF function with formula examples Google Spreadsheet COUNTIF function with formula examples Apr 11, 2025 pm 12:03 PM

Master Google Sheets COUNTIF: A Comprehensive Guide This guide explores the versatile COUNTIF function in Google Sheets, demonstrating its applications beyond simple cell counting. We'll cover various scenarios, from exact and partial matches to han

How to convert Excel to JPG - save .xls or .xlsx as image file How to convert Excel to JPG - save .xls or .xlsx as image file Apr 11, 2025 am 11:31 AM

This tutorial explores various methods for converting .xls files to .jpg images, encompassing both built-in Windows tools and free online converters. Need to create a presentation, share spreadsheet data securely, or design a document? Converting yo

See all articles