Obtain historical time period for pattern

Kishan

Well-known Member
Joined
Mar 15, 2011
Messages
1,648
Office Version
  1. 2010
Platform
  1. Windows
Using Excel 2000

Hi,

I got patterns data in cells C6:C85
In the cells E5:G5 I got 3 patterns,
In the cell C4 got 1 pattern X|X|1, what I want look this pattern from C6:C85 and get historical time period for the following patterns are listed in E5:G5

For example after the X|X|1 following pattern X|1|2 do have historical period 7 from the C6 place 7 in the under X|1|2 in G6

For example after the X|X|1 following pattern X|1|1 do have historical period 12 from the C6 place 12 in the under X|1|1 in E6

And so on for the rest.........

Example data...


Book1
ABCDEFGH
1
2
3
4X|X|1
5PattX|1|1X|1|XX|1|2
6X|1|112187
71|1|12341
81|1|12764
91|1|X3367
101|X|X5180
11X|X|157
12X|1|27
131|2|1
14X|1|X
151|X|X
16X|X|1
17X|1|112
181|1|1
191|1|1
201|X|X
21X|X|X
22X|X|1
23X|1|X18
241|X|1
25X|1|1
261|X|X
27X|X|1
28X|1|123
291|1|1
301|X|X
31X|X|1
32X|1|127
331|X|1
34X|1|1
351|1|X
361|X|X
37X|X|1
38X|1|133
391|1|1
401|1|1
411|2|1
421|1|X
431|X|X
44X|X|X
45X|X|1
46X|1|241
471|2|1
482|1|1
491|1|1
501|1|2
511|2|1
522|1|1
531|1|X
541|X|X
55X|X|1
56X|1|151
571|1|1
581|1|2
591|2|X
602|X|X
61X|X|1
62X|1|157
631|1|2
641|2|2
652|2|1
662|1|X
671|X|X
68X|X|1
69X|1|264
701|2|X
71X|X|1
72X|1|267
731|2|X
742|X|2
751|X|1
76X|1|2
771|2|1
782|1|1
791|1|1
801|1|1
811|1|X
821|X|X
83X|X|X
84X|X|1
85X|1|280
86
87
Sheet4


Thank you in advance

Regards,
Kishan
 
Last edited:

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
Please need help, I do appreciate better if can have VBA otherwise formula if it is a easy

Regards,
Kishan
 
Upvote 0
Your question is not clear: you mention
get historical time period
but there is no indication as to what this relates to, there no column with title "Time period" there are no time values on the example, so we are just trying to guess what you want. My guess is "42" the answer to everything. I hope that helps
 
Last edited:
Upvote 0
Using Excel 2000

Hi,

I got patterns data in cells C6:C85
In the cells E5:G5 I got 3 patterns,
In the cell C4 got 1 pattern X|X|1, what I want look this pattern from C6:C85 and get historical time period for the following patterns are listed in E5:G5

For example after the X|X|1 following pattern X|1|2 do have historical period 7 from the C6 place 7 in the under X|1|2 in G6

For example after the X|X|1 following pattern X|1|1 do have historical period 12 from the C6 place 12 in the under X|1|1 in E6

And so on for the rest.........

Example data...

Thank you in advance

Regards,
Kishan

Hi!

If I understand correctly what you want, maybe the Array Formula below can helps.

Use Ctrl+Shift+Enter to enter the formula

=IF(ROWS(E$6:E6)>SUM(($C$6:$C$85=E$5)*($C$5:$C$84=$C$4)),"",
SMALL(IF($C$6:$C$85=E$5,IF($C$5:$C$84=$C$4,ROW($C$6:$C$85)-ROW($C$6)+1)),ROWS(E$6:E6)))


Ps: I don't have Excel 2000 in my computer, I tested the formula above in Excel 2003 and it works.

Markmzz
 
Last edited:
Upvote 0
Your question is not clear: you mention but there is no indication as to what this relates to, there no column with title "Time period" there are no time values on the example, so we are just trying to guess what you want. My guess is "42" the answer to everything. I hope that helps
Hi offthelip, C4 Pattern X|X|1 is the key pattern, which I wanted to look in column C starting from cell C6 to down, basing to this key pattern I wanted to look 3 patterns which are in cells E5:G5 after who much time appears below the Key Pattern X|X|1

So if you see below the key pattern "X|X|1", X|1|2 has appeared in row 12 calculating time from C6 time period is = 7, so far result period 7 is shown below the pattern X|1|2 in the cell G7 = 7

Next if you see below the key pattern "X|X|1", X|1|1 has appeared in row 17 calculating time from C6 time period is = 12, so far result period 12 is shown below the pattern X|1|1 in the cell E7 = 12

In other words you can say who much time is being delayed each pattern is listed in cells E5:G5 below the key pattern X|X|1 in the column C From Cell C6

Hope this helps

Thank you for looking in it.

Have a nice weekend

Kind Regards,
Kishan


 
Upvote 0
Hi!

If I understand correctly what you want, maybe the Array Formula below can helps.

Use Ctrl+Shift+Enter to enter the formula

=IF(ROWS(E$6:E6)>SUM(($C$6:$C$85=E$5)*($C$5:$C$84=$C$4)),"",
SMALL(IF($C$6:$C$85=E$5,IF($C$5:$C$84=$C$4,ROW($C$6:$C$85)-ROW($C$6)+1)),ROWS(E$6:E6)))


Ps: I don't have Excel 2000 in my computer, I tested the formula above in Excel 2003 and it works.

Markmzz
Hi markmzz,

Thank you for giving a formula it is working flawless, and giving a result as request

Have a nice weekend

Kind Regards,
Kishan :)

 
Upvote 0
Hi markmzz,

Thank you for giving a formula it is working flawless, and giving a result as request

Have a nice weekend

Kind Regards,
Kishan :)

Hi Kishan,

You are welcome.

I'm glad to help and thanks for the feedback.

By the way, have a nice weekend too.

Markmzz
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,169
Members
453,021
Latest member
Justyna P

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
Back
Top