473,405 Members | 2,310 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

what is often before a pattern ?

Hello,

i'm looking for a way to detect sequence objects which are often before
a pattern.

say for example some list like:

a = "a0 a1 a2 a3 a4 myPatternMatchHere".split()
b = "a5 a2 a4 myPatternMatchHere".split()
c = "a6 a7 a2 a3 a8 a4 myPatternMatchHere".split()
d = "a9 a10 a2 myPatternMatchHere".split()

a2 a3 a4 is the most interesting because it appears 2 times upon 4, and
overlap a2 a4, and we have some clues that a2 is also important as it
appears 4/4.

maybe have you some suggestions or idioms where i should look after

best.

Jun 8 '06 #1
2 1126
jo******@yahoo.fr wrote:
Hello,

i'm looking for a way to detect sequence objects which are often before
a pattern.

say for example some list like:

a = "a0 a1 a2 a3 a4 myPatternMatchHere".split()
b = "a5 a2 a4 myPatternMatchHere".split()
c = "a6 a7 a2 a3 a8 a4 myPatternMatchHere".split()
d = "a9 a10 a2 myPatternMatchHere".split()

a2 a3 a4 is the most interesting because it appears 2 times upon 4, and
overlap a2 a4, and we have some clues that a2 is also important as it
appears 4/4.

maybe have you some suggestions or idioms where i should look after

best.


Look into suffix trees.

http://www.csse.monash.edu.au/~lloyd...S/Tree/Suffix/

--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/
Jun 8 '06 #2

thanks, i 've checked, it may fit.

i also find something about a longest common sequence which may be of
interest, but i was unable to adapt it for list (words) rather than
characters :(

Jun 10 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

220
by: Brandon J. Van Every | last post by:
What's better about Ruby than Python? I'm sure there's something. What is it? This is not a troll. I'm language shopping and I want people's answers. I don't know beans about Ruby or have...
28
by: joe | last post by:
I have a simple .NET application with two or three listViews which are filled with icons and when the user click on the proper item, they display the related images. I use "image = null ; " for all...
23
by: Xah Lee | last post by:
The Concepts and Confusions of Pre-fix, In-fix, Post-fix and Fully Functional Notations Xah Lee, 2006-03-15 Let me summarize: The LISP notation, is a functional notation, and is not a...
12
by: Adrian | last post by:
The code below was taken from an example. All the "noise" in the example was thrown out. This is supposedly according to the bridge pattern. What in the code (which lines) represent the bridge...
5
by: Jim in Arizona | last post by:
Can someone tell me what the difference is, if any, there is between a Software Architect and a Software Developer? TIA, Jim
3
by: alacrite | last post by:
You have higher level, lower level, and those languages in between. Generally speaking higher level languages are considered more productive at the cost of a slower runtime. While lower level...
4
by: joe | last post by:
Curious if this type of construct has a name, or is a recognized design pattern: class Function { public: Function() { // do loads of work here in the Constructor, store result in m_result }...
5
by: Matthew Zhou | last post by:
I check the ISO 9899 standard, \r (carriage return) Movesthe active position to the initial position of the current line. What does it do? How to input? I tried to use Flex to check this...
18
by: Xah Lee | last post by:
What are OOP's Jargons and Complexities Xah Lee, 20050128 Classes, Methods, Objects In computer languages, often a function definition looks like this: subroutine f (x1, x2, ...) {...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.