Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^2: Removing nucleotide frm sequence

by space_monk (Chaplain)
on Jun 07, 2013 at 07:42 UTC ( #1037609=note: print w/replies, xml ) Need Help??


in reply to Re: Removing nucleotide frm sequence
in thread Removing nucleotide frm sequence

local $/ = ""; while (<>) { # should have a whole record # split up 4 line record my (@line) = split( "\n"); # change if necessary to check we have a valid record if ($line[0] =~ /^@/) { $line[1] =~ s/([ACGT]{5})$//; $line[3] =~ s/(\w{5})$//; print join("\n", @line); } }
If you spot any bugs in my solutions, it's because I've deliberately left them in as an exercise for the reader! :-)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1037609]
help
Chatterbox?
[LanX]: Corion: and that's the clue how Germany can dominate Handball tournaments, just continuing the domestic league and forbidding the best players of the world to attend :)
LanX (which would be a good scheme for England and football too)
[LanX]: If "Canada will play the Czech Republic for bronze on Saturday", that means Germany will play Syria in disguise...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (11)
As of 2018-02-23 16:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When it is dark outside I am happiest to see ...














    Results (303 votes). Check out past polls.

    Notices?