RPTools

Personal tools
From MapToolDoc

absolutevalue

Contents

absolutevalue() Function

Returns the absolute value of a number. The absolute value of a number is the number without the sign.

Usage

  1. [h: val = absolutevalue(num)]

You can use the following shorthand for this function:

  1. [h: val = abs(num)]

Examples

Negative Number

  1. [r: absolutevalue(-3)]
Returns:
  1. 3


Positive Number

  1. [r: abs(4)]
Returns:
  1. 4


Decimal Number

  1. [r: abs(3.4)]
Returns:
  1. 3.4