in reply to Re^2: unique sequences
in thread unique sequences
Sorry, I didn't test the code well enough. I thought the capturing parenthesis would capture the look-behind pattern as well. This code will do what I originally intended:
Updated (thanks Cristoforo)
while ( $line =~ / (?<= .{9} [ATCG]{10} G ) G /gsx ) { my $match = substr $line, $+[ 0 ] - 21, 21; print $KMERS '>crispr_', ++$count, "\n$match\n" unless $unique_data{ $match }++; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: unique sequences
by AnomalousMonk (Archbishop) on Dec 11, 2017 at 21:25 UTC | |
Re^4: unique sequences
by Cristoforo (Curate) on Dec 11, 2017 at 19:39 UTC |
In Section
Seekers of Perl Wisdom