|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Calculate recurring instances between cell count - using trigger - URGENT HELP
Hi guys,
Probably my best shot here to finish successfully my graduation with a study I am doing that I am now TOTALLY STUCK. Please read slowly as I will do my best to explain my needs: In the Excel attached there are 27008 rows of random numbers from 0-36 (column B). Each range of numbers is categorized as following: 0 = Color 2 1-6 = Color 3 7-12 = Color 4 13-18 = Color 1 19-24 = Color 5 25-30 = Color 6 31-36 = Color 7 What I need, in the first place, is to count is the number of sequences that only 2 random numbers of the same color appear one after another. Per example: Rows 2-3 4-5 20-24 23-24 etc..... This is the easy part. The "trigger" to stop counting would be a sequence where 3 or more numbers of the same color appear one after another. Per example: Rows 134-136. So in the case that we take a sequence from row 2 to row 136 - the formula would count exactly 17 times that a group of 2 numbers of the same color appeared one after another until a group of 3 numbers of the same color one after another showed up and than the count stops and restarts. The ultimate question of the study would be: out of 27008 rows, the longest sequence that 2 numbers of the same color appeared one after another until a 3 numbers one after another showed up is............. X How do I achieve this? Really I have consulted my professors, computer engineers and many others, with 0 SUCCESS. Please help me. Since I am no Excel programmer feel free to edit my excel and send back. @@@THANK YOU SO MUCH@@@ |
#2
|
||||
|
||||
Cross-posted at: https://www.mrexcel.com/forum/excel-...g-trigger.html
For cross-posting etiquette, please read: http://www.excelguru.ca/content.php?184
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
||||
|
||||
In the attached see columns H:I.
It goes wrong when it finds 4 (or more) in a row, it thinks they're two triplets next to each other. The max is 40, there's only one, lying between triplet at row 6612 above, and triplet at row 6857 below. Any use? |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to trigger a macro on cell *selection* | Larry_1 | Excel Programming | 6 | 12-24-2017 11:09 AM |
Cell drop down boxes URGENT | otuatail | Excel | 2 | 02-26-2015 09:51 AM |
trying to use vlookup to calculate several different situations in one cell | heastlund | Excel | 3 | 11-21-2013 12:38 PM |
Hyperlink in cell to trigger pop up text box | Carpie | Excel Programming | 0 | 08-13-2013 10:33 AM |
A recurring word count macro? | bpanda | Word VBA | 1 | 06-11-2013 07:17 AM |