MAX help?

ecarney14

New Member
Joined
Sep 21, 2006
Messages
42
My simplified data set looks like this: ( the real one is much more confusing)

Time Ch. 16
1 1
2 0
3 2
4 1
5 6
6 7
7 8
8 7
9 5
10 0

I know that the max is 8, and the minimum is really 0. But what I want my macro to do. Is determine that the data goes up then comes down again before hitting the max point. Is there a way to determine that 2 is a max point, and to take the values in between 2 and 8 in order to find the minimum point, 1.

Eventually I would like to use the minimum, 1, in a formula later. As long as I can get the macro to identify it, I can figure it out from there though.

Thanks for any help.
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"

Krishnakumar

Well-known Member
Joined
Feb 28, 2003
Messages
2,615
Hi,

A formula based approach..
Book1
ABCD
2111
320
432
541
656
767
878
987
1095
11100
Sheet2


Formulain C2,

=MIN(INDEX(B2:B11,MATCH(0,B2:B11,0)+1):INDEX(B2:B11,MATCH(0,INDEX(B2:B11,MATCH(0,B2:B11,0)+1):INDEX(B2:B11,MATCH(9.999999999E+307,B2:B11)),0)-1))

HTH
 

ecarney14

New Member
Joined
Sep 21, 2006
Messages
42
wow. how did you come up with that. i am going to check and see if it works for other data. but whz the 9.999e307?

thanks though
 

Forum statistics

Threads
1,137,341
Messages
5,680,922
Members
419,945
Latest member
Carrie Sellers

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top