[Bioperl-l] A perl regex query

bioperl-list at superfrink.net bioperl-list at superfrink.net
Tue Sep 18 16:16:48 UTC 2007


On Tue, 18 Sep 2007, Nathan Haigh wrote:

> An even better way is to use the array as Spiros suggested, but you
> should then be able to use that in the regex like this:
>
> my @ra_bad_terms = (  '-D-', 'Cyclic-' );
> $string =~ s/@ra_bad_terms//g;

I didn't know one could do that.  I couldn't get it to work so I asked 
around.  In case anyone else read it and thought about using that code it 
might only work in Perl 6.

Regards,
Chad



More information about the Bioperl-l mailing list