View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips Bob Phillips is offline
external usenet poster
 
Posts: 380
Default MIN and MAX Functions

With mine it is simple

=MIN(IF((rng1=cond1)*(rng2=cond2)*(rng3=cond3),rng 4))

This is the problem with yours, as the tests resolve to 1/0, and when
multipiled by the value range there are still zeroes of which the min of
that is always 0.

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"Epinn" wrote in message
...
No idea how to write the MIN formula.

Epinn

"Epinn" wrote in message
...
Bob,

I made some modification to the formula and I got the correct result.

(1) I took out the extra closing bracket.
(2) I took out IF. This is based on what I have learned from SUMPRODUCT and
Boolean.
(3) I had to replace the comma with *. I don't understand why. For
SUMPRODUCT either * or comma would have worked in a case like this. But for
MAX and SUM I have to use * instead of comma to get the correct result.
This is my discovery for today.

=MAX((A1:A10="y")*(B1:B10=1)*(C1:C10="DeptA")*(D1: D10)) committed with CSE.

Appreciate guidance.

Epinn

"Bob Phillips" wrote in message
...
=MAX(IF(rng=cond1)*(rng2=cond2)*(rng3=cond3),rng4) )

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.

Just substitute actual ranges for rng1, 2, 3 and 4 (they must be the same
size), and your test values (enclose in quotation marks if strings).

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"Leslie" wrote in message
...
How do I find the MIN and MAX of data based on 3 different conditions?
--
Thanks,
Leslie