Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Match Last Occurrence of two numbers and Count to Previous Occurence
Hi All,
Thank you very much for taking the time to provide various formulas. I need to find /match the LAST time two specific numbers appeared together and Count the number of Rows between the LAST time they appeared together back to their PREVIOUS appearance together. I have a table of numbers that spans nine Columns (A-I)and 400+ Rows (20- 480). I have made the table a Dynamic Range called "Numbers". Each Row contains numbers in ascending order. Is there a formula that can check for two specific numbers Row by Row through the (nine column) Range "Numbers" and Return the Row Count of their LAST appearance together back to their PREVIOUS appearance together, from the Dynamic Range "Numbers"? Columns A-I = Dynamic Range "Numbers" Rows 20-480 Example sample data from Range "Numbers": ROW20 51 58 59 65 69 72 73 76 79 ROW31 50 51 58 72 73 76 79 80 81 ROW50 50 52 60 62 68 69 70 75 76 ROW75 53 54 59 60 62 69 70 72 73 ROW80 50 51 58 59 70 71 72 73 76 ROW83 51 53 65 67 68 69 78 80 81 ROW94 51 52 58 60 61 65 67 72 73 ROW99 50 53 57 62 63 68 70 71 73 Example Criteria: Locate when 72 AND 73 LAST appeared together and Count back to their PREVIOUS appearance together to get the required Count; i.e. the number of Rows in between the LAST appearance and the PREVIOUS appearance. Count from the Row above LAST appearance to the Row before PREVIOUS appearance. Expected Result: 72 AND 73 LAST Appear=ROW99 PREVIOUS Appear=ROW94(Count From Row98 To Row95) Count=4 50 AND 51 LAST Appear=ROW80 PREVIOUS Appear=ROW31(Count From Row79 To Row32) Count=48 68 AND 69 LAST Appear=ROW83 PREVIOUS Appear=ROW50(Count From Row82 To Row51) Count=32 80 AND 81 LAST Appear=ROW83 PREVIOUS Appear=ROW31(Count From Row82 To Row32) Count=51 Regards, Sam -- Message posted via http://www.officekb.com |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Count and Sum Total occurrances of two specific numbers | Excel Worksheet Functions | |||
Count 350 SS numbers, exclude duplicates | Excel Discussion (Misc queries) | |||
count cells with unique numbers | Excel Worksheet Functions | |||
Count Consecutive Numbers in a Row | Excel Worksheet Functions | |||
count a group of numbers but do not count duplicates | Excel Worksheet Functions |