Calculating Max & Min in a negative numbes

S

srpavar

i Have a worksheet with these number, when i select maximum from this list
below it give -40.34, i want to -55.25 as maximum and the same for Minimum,
how to get with the formula, can anyone pl help.
-48.94
-53.39
-54.54
-55.25
-49.52
-40.34
Max -40.34
Min -55.25
 
M

Mike H

=MAX(ABS(A1:A6))
=MIN(ABS(A1:A6))

Both of which must be array entered with
Ctrl+Shift+Enter

Mike
 
S

Stefi

Max: =MAX(ABS(A1:A6)) as an array formula confirmed with Ctrl+Shift+Enter
Min: =MIN(A1:A6) as a normal formula
Regards,
Stefi


„srpavar†ezt írta:
 
M

Mike H

That changes the number to absolute so use this instead

=MIN(ABS(A1:A6))*-1
=MAX(ABS(A1:A6))*-1

Once again array entered

Mike
 
S

Spiky

i Have a worksheet with these number, when i select maximum from this list
below it give -40.34, i want to -55.25 as maximum and the same for Minimum,
how to get with the formula, can anyone pl help.
-48.94
-53.39
-54.54
-55.25
-49.52
-40.34
Max -40.34
Min -55.25

Nobody else asked.

Why do you want a simple MIN and MAX to be the same? That has got to
be incorrect no matter what field you are in. If you want to reverse
them to show the ABS of the number as MIN/MAX, then Mike's formulas
are good. But they shouldn't be the same.
 
J

joeu2004

That changes the number to absolute so use this instead
=MIN(ABS(A1:A6))*-1
=MAX(ABS(A1:A6))*-1
Once again array entered

That presumes that you know you want a negative result. If that's the
case, you might as well simply reverse MIN and MAX. That is, for
negative numbers, the "largest" number (magnitude) is simply
MIN(A1:A6), and the "smallest" number (magnitude) is MAX(A1:A6). No
array-entry required.

What you might have had in mind was something like the following
(committed with ctrl-shift-Enter):

=min(abs(A1:A6))*sign(A1)
=max(abs(A1:A6))*sign(A1)

That persumes that all the signs of A1:A6 are the same, so it does no
matter which one we look at. Of course, the OP's question makes
little sense if we don't make this assumption in the first place.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top