The absolute value of a number can be defined as its numerical distance from zero. This mathematical concept plays an important role in mathematics, and even physics.

Although determining the absolute value of a number is simple, it can become a burden when you're dealing with high quantities. Fortunately, Excel has an exclusive function for this application.

What Are Absolute Values and the ABS Function in Excel?

ABS is an Excel function that takes in a number, and then outputs the absolute value of that number. The ABS function can only be used with numerical values. You can feed the number directly, or input a cell or range that contains the number.

=ABS(number)

The absolute value of a number is, in a way, the number without its negative sign. If X is positive, its absolute value will equal X itself. If X is negative, its absolute value will equal -X, which is a positive number.

Absolute values of some numbers in Excel

You can see some numbers and their absolute values in the image above. Note that the absolute values of 5 and -5 are both 5.

How to Get the Absolute Value of a Number With ABS in Excel

ABS is a straightforward function. It takes in a single argument, which is the number you want the absolute value for. You just need to know where and when to use it in Excel.

Numbers in an Excel spreadsheet

In this sample spreadsheet, we have the positions of some players in a game. This game is played only on the X-axis, and the players all start from the zero point. The goal is to calculate each player's distance from the base point.

Since the positions are all on the X-axis, each player's distance from the base is actually the absolute value of their position.

  1. Select a cell where you want to display the absolute value.
  2. Go to the formula bar, and enter the formula below:
    =ABS(B2)
  3. Press Enter.
  4. Grab the fill handle and drop it into the cells below.
Calculating distance with ABS in Excel

This formula uses the ABS function to return the absolute value of the number in cell B2. The player's position is in B2, and the absolute value of their position equals their distance from zero.

How to Get the Absolute Value of a Matrix With ABS in Excel

You can also use the ABS function to get the absolute of a matrix in Excel. Matrices are arrays of numbers, and you can perform mathematical functions on matrices in Excel. The steps to get the absolute value of a matrix are the same as with single numbers, except that you need to input the matrix range.

  1. Select the first cell in the new matrix where you want to display absolute values.
  2. Go to the formula bar and enter the formula below:
    =ABS(A2:C4)
  3. Press Enter.
Getting the absolute value of a matrix with ABS in Excel

This formula is similar to the previous one. The only difference is that rather than a single cell, it feeds the A2:C4 range to the ABS function.

Absolute Efficiency With Excel's ABS Function

Excel and its functions make tough tasks easy, but they can also work their magic on easy tasks to make them easier. Calculating the absolute value of a number is something that you can do at a glance, but that doesn't hold very well once you're dealing with arrays of numerical values or matrices.

Excel's ABS function has one purpose, and that is to output the absolute value of a number. This function works with ranges as well, so you can swiftly get the absolute value of a matrix with ABS. Now that you've added the ABS function to your repertoire, you're well on your path to absolutely mastering Excel.