R
Ross
Dear all,
For the sequence below (indeed a single line), when i use the conditional
checking
if ($line =~ /(.*)A{10,}(.*)/ ) {
$tmpline = $1;
}
to try to remove substring after 10 or more consecutive A's, perl seems to
recognize the last poly A's and leave the former ones intact. what can i do?
In general, How to take acton upon a pattern of nth occurrence?
TCCTCAGTGGGAATTCGGCATTACGGCCGGGGCACCACAATGAATGATCATTTTC
TTCTTTGCTCTCCTTGCTATTGCTGCATGCAGCGCCTCTGCGCAGTTTGATGCTG
TTACTCAAGTTTACAGGCAATATCAGCTGCAGCCGCATCTCATGCTGCAGCAACA
GATGCTTAGCCCATGCGGTGAGTTCGTAAGGCAGCAGTGCAGCACAGTGGCAACC
CCCTTCTTCCAATCACCCGTGTTTCAACTGAGAAACTGCCAAGTCATGCAGCAGC
AGTGCTGCCAACAGCTCAGGATGATCGCGCAACAGTCTCACCGCCAGGCCATTAG
TAGTGTTCAGGCGATTGTGCAGCAGCTACAGCTACAACAGTTTGCTGGCGTCTAC
TTCGATCAGACTCAAGCTCAAGCCCAAGCTATGTTGGCCCTAAACTTGCTGTCAA
TATGCGGTATCTACCCAAGCTACAACACTGCTCCCTGTAGCATTCCCACCGTCGG
TGGTATCTGGTACTGAATTGTAGCAGTATAGTAGTACAGGAGAGAAAAATAAAGT
CATGCATCATCGTGTGTGACAAGTTGAAACATCGGGGTGATACAAATCTGAATAA
AAATGTCATGCAAGTTTAAACANNNNANANNNANNNNAAANAAAAAAAAAAAAAA
AAAANANAAAAAAAAAAAAAAAAAAAAAAAAAAANAAAAANAAAAAAAAAAAAAA
AAAAANNNNNNANANNNNNNAAAAAAAAAAAAAAAAANNNNNNNNNNGGGGGGGG
GGGGGGGCGGGAAGAAAAAAAAAAA
For the sequence below (indeed a single line), when i use the conditional
checking
if ($line =~ /(.*)A{10,}(.*)/ ) {
$tmpline = $1;
}
to try to remove substring after 10 or more consecutive A's, perl seems to
recognize the last poly A's and leave the former ones intact. what can i do?
In general, How to take acton upon a pattern of nth occurrence?
TCCTCAGTGGGAATTCGGCATTACGGCCGGGGCACCACAATGAATGATCATTTTC
TTCTTTGCTCTCCTTGCTATTGCTGCATGCAGCGCCTCTGCGCAGTTTGATGCTG
TTACTCAAGTTTACAGGCAATATCAGCTGCAGCCGCATCTCATGCTGCAGCAACA
GATGCTTAGCCCATGCGGTGAGTTCGTAAGGCAGCAGTGCAGCACAGTGGCAACC
CCCTTCTTCCAATCACCCGTGTTTCAACTGAGAAACTGCCAAGTCATGCAGCAGC
AGTGCTGCCAACAGCTCAGGATGATCGCGCAACAGTCTCACCGCCAGGCCATTAG
TAGTGTTCAGGCGATTGTGCAGCAGCTACAGCTACAACAGTTTGCTGGCGTCTAC
TTCGATCAGACTCAAGCTCAAGCCCAAGCTATGTTGGCCCTAAACTTGCTGTCAA
TATGCGGTATCTACCCAAGCTACAACACTGCTCCCTGTAGCATTCCCACCGTCGG
TGGTATCTGGTACTGAATTGTAGCAGTATAGTAGTACAGGAGAGAAAAATAAAGT
CATGCATCATCGTGTGTGACAAGTTGAAACATCGGGGTGATACAAATCTGAATAA
AAATGTCATGCAAGTTTAAACANNNNANANNNANNNNAAANAAAAAAAAAAAAAA
AAAANANAAAAAAAAAAAAAAAAAAAAAAAAAAANAAAAANAAAAAAAAAAAAAA
AAAAANNNNNNANANNNNNNAAAAAAAAAAAAAAAAANNNNNNNNNNGGGGGGGG
GGGGGGGCGGGAAGAAAAAAAAAAA