FW: [Biojava-l] Newbie Question 2: Searching Sequences for regular expressions

Michael L. Heuer heuermh@acm.org
Wed, 23 Oct 2002 18:25:18 -0400 (EDT)


Hello Mark, Andy

Keith added a CharSequence wrapper around SymbolList to the src-1.4
repository, so with the java 1.4 version of biojava you can do something
like

SymbolList s1 = { AANNNNTGG };
SymbolList s2 = { some long seq };

Pattern p = Pattern.compile( MotifTools.createRegex(s1) );

SymbolListCharSequence charSeq = new SymbolListCharSequence(s2);

Matcher m = p.matcher(charSeq);

if (m.matches()) { ... }

   michael


On Thu, 24 Oct 2002, Schreiber, Mark wrote:

> Sorry meant to forward this to the list...
>
> -----Original Message-----
> From: Schreiber, Mark
> Sent: Thursday, 24 October 2002 11:09 a.m.
> To: 'andy hammer'
> Subject: RE: [Biojava-l] Newbie Question 2: Searching Sequences for
> regular expressions
>
>
> To clarify...
>
> There is not yet any formal RE parser that works on biojava Symbol
> objects. You can replicate the behaivour by making a Markov chain and
> using it to parse any input to see if it matches (or even how well it
> matches).
>
> A class that takes some kind of Symbolic representation of an RE and
> makes  the appropriate Markov chain would be cool though, anyone got a
> spare day or too?
>
> - Mark
>
>
> > -----Original Message-----
> > From: andy hammer [mailto:ahammer@genetics.utah.edu]
> > Sent: Thursday, 24 October 2002 10:58 a.m.
> > To: biojava-l@biojava.org
> > Subject: [Biojava-l] Newbie Question 2: Searching Sequences
> > for regular expressions
> >
> >
> > Is there any way to search a sequence for a regular expression?
> >
> > Andy Hammer
> > University of Utah
> > Human Genetics _______________________________________________
> > Biojava-l mailing list  -  Biojava-l@biojava.org
> > http://biojava.org/mailman/listinfo/biojava-l
> >
> =======================================================================
> Attention: The information contained in this message and/or attachments
> from AgResearch Limited is intended only for the persons or entities
> to which it is addressed and may contain confidential and/or privileged
> material. Any review, retransmission, dissemination or other use of, or
> taking of any action in reliance upon, this information by persons or
> entities other than the intended recipients is prohibited by AgResearch
> Limited. If you have received this message in error, please notify the
> sender immediately.
> =======================================================================
> _______________________________________________
> Biojava-l mailing list  -  Biojava-l@biojava.org
> http://biojava.org/mailman/listinfo/biojava-l
>