ID EN
#Math

SIGN

Excel Functions

Get the sign of a number

Syntax

EXCEL
=SIGN(number)

Arguments

Parameter Description
number The number to get the sign of.

Return Value

One if positive. Negative one if negative. Zero if zero.

Details

The SIGN function returns the sign of a number as +1, -1 or 0. If number is positive, SIGN returns 1. If number is negative, sign returns -1. If number is zero, SIGN returns 0. The SIGN function takes one argument, number, which must be a numeric value. If number is not numeric, SIGN returns a #VALUE! error. SIGN can be used to change negative numbers into positive values like this. For example, with -3 in cell A1, the formula below returns 3: The formula above has no effect on positive numbers, since SIGN will return 1. However, the ABS function provides a simpler solution:

Examples

Examples
EXCEL
=SIGN(5) // returns 1
=SIGN(-3) // returns -1
=SIGN(0) // returns 0
Examples

SIGN can be used to change negative numbers into positive values like this. For example, with -3 in cell A1, the formula below returns 3:

EXCEL
=A1*SIGN(A1)
=-3*-1
=3
Examples

The formula above has no effect on positive numbers, since SIGN will return 1. However, the ABS function provides a simpler solution:

EXCEL
=ABS(A1) // absolute value of A1