ABS
Last updated
Last updated
The ABS function returns the absolute value of a number (i.e) a number without its sign.
ABS(value) - > number
Arguments | Datatype | Description |
---|---|---|
In the below table, data of demand and inventory are given. Consider a scenario where you want to calculate the absolute difference between demand and inventory.
Parameter | Week 1 | Week 2 | Week 3 | Week 4 | Week 5 |
---|---|---|---|---|---|
To achieve this, the following formula should be written in the [Absolute Difference] node:
ABS
(
[Demand]
-
[Inventory]
)
If ABS is not used the difference between values will be as follows:
value
Number/Node reference
The node or the number for which you want the absolute of.
Demand
110
95
75
78
0
Inventory
85
70
100
80
25
Absolute Difference
25
25
25
2
25
Absolute Difference
25
25
-25
-2
-25