# Find max absolute of two numbers and retain it's original sign.

Experts,
I am trying to find the absolute highest value of two columns and store it in the third column. The only catch here is the value stored in the third column should retain it's original sign.
For example, for the values -0.1430000060 and -0.1410000030 when I run =MAX(ABS(A1:B1)), it returns 0.1430000060 without the - sign. Any suggestions?
Sample.xlsx
###### Who is Participating?

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Commented:
Are the numbers always negative as in your example? If so, you're not looking for the highest, but the lowest and you can just use the MIN function.

=MIN(A1:B1)
0
Author Commented:
The numbers can be either positive or negative. Sorry, the sample I chose contains only negative, it is a pretty huge file running into several hundred thousands of rows.
0
Commented:
OK, as you're only comparing 2 columns, you can use a simple IF statement to compare the absolute values...

=IF(ABS(A1)>ABS(B1), A1, B1)
0

Experts Exchange Solution brought to you by

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Author Commented:
Thank you, Wayne!
0
###### It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Excel

From novice to tech pro — start learning today.