ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Min with a match? (https://www.excelbanter.com/excel-discussion-misc-queries/160917-min-match.html)

Laury

Min with a match?
 
I have a working formula to find a min. value w/in a criteria set. Part of
the criteria is that the dates need to be within plus or minus 30 days of the
original date.
=MIN(IF(($D$9:$D$16=$D5)*(($A5-($A$9:$A$16))<31)*(($A5-($A$9:$A$16))-31),$B$9:$B$16," "))

Now I need to find the lowest min in the same set, AND it has to match in
both the <31 days and the -31 days. So, for ex: If the orig min value were
$2.50 on 3/1/07 - I need to now verify that 2.50 exists on both sides of the
timeframe (i.e. 2.50 on 2/15/07 and 2.50 on 3/15/07). If not, then I need to
return the closest to the min value that does exist in both. Can this be
done with a formula? I don't know how to write code. Any help would be
greatly appreciated.


All times are GMT +1. The time now is 12:40 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com