Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Another Reverse Complement Question...

by Cristoforo (Curate)
on Jun 04, 2012 at 20:31 UTC ( #974373=note: print w/replies, xml ) Need Help??


in reply to Another Reverse Complement Question...

I don't work with BioPerl, but they do have a reverse complement method, revcom and it can be used like this example:

#!/usr/bin/perl use strict; use warnings; use 5.014; use Bio::PrimarySeq; my $seqobj = Bio::PrimarySeq->new(-seq => 'ACTGTGGCGTCAACTG', -alphabet => 'dna', -id => 'test'); say $seqobj->seq; say $seqobj->revcom->seq; __END__ *** print out ACTGTGGCGTCAACTG CAGTTGACGCCACAGT

But this doesn't do the translation you want: A => T, C => G, G => C and T => A. So, I don't know if this is any help.

Update: After examining the reversed complement sequence, I see indeed it performs the complement as you stated but it also reverses the sequence with the first letter in the original being complemented and last in the reversed sequence, the second in the original complemented and being next to last in the reversed complement sequence, etc.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://974373]
help
Chatterbox?
[LanX]: it's easier to patch then to migrate to a PHP board, there are many semantics like linking , authorisation, templates ,...
[LanX]: I've only seen 30% of the semi professional documentation
[holli]: i was just thinking of the bare content.
[LanX]: Plenty of "templates" realised with CGI-HTML-function
[LanX]: well if you want you can fetch all XML and translate it to another board markup
[moritz]: at this time, a migration could consist of only migrating the rendered HTML of nodes
[moritz]: to a forum software that supports raw HTML input for legacy threads, and uses sane markup for everything else
[holli]: yeah, then vroom will personally stab me in the back at night
[holli]: exactly, moritz
[moritz]: with a big table of redirects to support the old links

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (7)
As of 2017-11-20 19:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:













    Results (292 votes). Check out past polls.

    Notices?