in reply to Create the reverse complement DNA sequence without pattern matching and reverse built-in function?
Could some kind soul explain how "reverse complement" works? Is is not the same as "reverse? -- ie, is NOT one word or the other redundant?
Update: Has been explained! See below and the replies from BrowserUK and kcott
And if that's a bit fuzzy around the edges (yeah, it is, IMO), code to illustrate why I'm puzzled with OP's use of the phrase "reverse complement" and its adoption by others:
#!/usr/bin/perl use 5.016; use warnings; # 1075463 my $seq="ACGGGAGGACGGGAAAATTACTACGGCATTAGC"; say "Initial \$seq is: $seq"; say "Reverse sequence is: " . reverse($seq); my @seq = split(/\b/, $seq); my $comp; while (@seq) { $comp .= pop(@seq); } print "Complement is: $comp\n"; my $reverse = reverse($comp); print "Reverse complement is:$reverse\n"; =head OUTPUT: Initial $seq is: ACGGGAGGACGGGAAAATTACTACGGCATTAGC Reverse sequence is: CGATTACGGCATCATTAAAAGGGCAGGAGGGCA Complement is: ACGGGAGGACGGGAAAATTACTACGGCATTAGC # per OP's use, + I think Reverse complement is:CGATTACGGCATCATTAAAAGGGCAGGAGGGCA =cut
On-line dictionaries tend to mention the mathematics use only in geometric terms. Is my understanding that the OP's phrase would be better written and less ambiguous using just one of its two terms?
Update:
/me headslaps! Duh! Ignored the "double helix" fundamental! Thanks, obeisances and + +s to both BrowserUK and kcott.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Create the reverse complement (OT: meaning / use of "reverse complement")
by kcott (Archbishop) on Feb 19, 2014 at 17:48 UTC | |
|
Re^2: Create the reverse complement (OT: meaning / use of "reverse complement")
by BrowserUk (Patriarch) on Feb 19, 2014 at 17:02 UTC |