I am trying to find the delta between two sets of numbers. Some numbers are positive, some negative.

Using the following formula works about 99% of the time:

```
=IF(I18<0,I18+R18,IF(I18>0,I18-R18))
```

However, when `I18`

and `R18`

are negative numbers, I need `I18-R18`

. I have tried multiple `IF`

`AND`

statements, but just can't seem to get this right. Hopefully someone can guide me in the right direction.

`I18`

is zero. – Blackwood May 8 '18 at 16:03`I18`

and`R18`

are negative numbers, I need`I18-R18`

" Are you sure you mean this? I thought you wanted the delta as an absolute difference. If`I18`

is`-2`

and`R18`

is`-1`

, your result is going to be`-1`

. Don't you want a positive number in all cases? – JoL May 8 '18 at 23:27`=ABS(I18)-ABS(R18)`

produce the desired output? – Salman A May 9 '18 at 5:28youwant). Also, a delta between A and B can only be`A+B`

if both A and B are zero. – Dmitry Grigoryev May 9 '18 at 9:14deltausually means thedifferencebetween two numbers, which isalwaysA-B, and unless you want to signify which of the numbers is the greater, you would take the absolute valueabs(A-B). – Mick May 9 '18 at 12:54