# MAX / MIN function problem

J

#### johnsmyth67

Good afternoon all:

The following array formula works perfectly.

{=MAX((\$G\$3:\$G\$11939>=\$S3)*(\$G\$3:\$G\$11939<\$S4)*(J\$3:J\$11939))}

However, when I attempt to use the formula shown below, substituting
MIN for MAX, it returns only zeros.

{=MIN((\$G\$3:\$G\$11939>=\$S3)*(\$G\$3:\$G\$11939<\$S4)*(J\$3:J\$11939))}

1. I have confirmed the formula is entered as an array.

2. There are no zeros or negative values in the array.

3. There are no text entries in the array; only positive values.

4. The formulas are supposed to determine the maximum and minimum
values in column J
based on conditions defined in the cells S3 and S4 relative to column
G.

Any help would be most appreciated, as always.

Cheers,
Joseph

T

#### T. Valko

Try this (array entered):

=MIN(IF((\$G\$3:\$G\$11939>=\$S3)*(\$G\$3:\$G\$11939<\$S4),J\$3:J\$11939))

M

#### Mike H

Try array entered

=INDEX(J3:J11,MATCH(MAX(IF((G3:G11>=S3)*(G3:G11<=S4),G3:G11,FALSE)),G3:G11,FALSE),1)

Change max to min for minimum. I shortened the ranges for degugging so
change then back

Mike

J

#### johnsmyth67

Try this (array entered):

=MIN(IF((\$G\$3:\$G\$11939>=\$S3)*(\$G\$3:\$G\$11939<\$S4),J\$3:J\$11939))

--
Biff
Microsoft Excel MVP

- Show quoted text -

Thanks, Biff and Mike. Both solutions work perfectly.

Joseph

T

#### T. Valko

You're welcome. Thanks for the feedback!

--
Biff
Microsoft Excel MVP

Try this (array entered):

=MIN(IF((\$G\$3:\$G\$11939>=\$S3)*(\$G\$3:\$G\$11939<\$S4),J\$3:J\$11939))

--
Biff
Microsoft Excel MVP

- Show quoted text -

Thanks, Biff and Mike. Both solutions work perfectly.

Joseph