We should be ashamed of ourselves. All the web resources for reverse complementing a piece of DNA are straight from the 90s, requiring a round trip to the server and opening a new window. We can do better. (I'm not linking to any examples on purpose).
Please post a piece of HTML that computes the reverse complement for DNA entered into a textarea that dynamically displays the result using client side javascript. This should not require a form submit and therefore work without a server. Bonus points for handling degenerate characters correctly and preserving FASTA header lines.
Personally, I think we should be ashamed with ourselves if we have to use a web-browser to reverse complement a sequence.
check this out: http://www.ualberta.ca/~stothard/javascript/rev_comp.html
+1 This is a real javascript implementation. It opens a window, which may look like a CGI behavior. That website is really good. The developer has put a lot of efforts.
OK, so its client side but its not dynamic, right?
You mean copy and paste of sequence in the Textarea form should automatically generate reserve complement? Or if I keep on typing sequences in the Textarea should keep on generating reserve strand?
Personally I do not like another window with results popping out at the other corner of the screen but this is probably a matter of taste.
If you need to reverse complement a sequence as part of an application/pipeline, or if the sequence is large, I agree with GWW - you shouldn't consider a web solution (too slow, consumes network bandwidth). For once-off small tasks, I see nothing wrong with a web tool for convenience. @Casbon, if people are going to use the tool for small sequences, I don't think there is an urgent need for a completely client-side solution - savings are minimal. Out of interest, why are you asking the community to write this? Do you intend to make it available on a server?
When we look for troubles in alignments etc., having a web page like this would be convenient.
Writing a code reverse complement may look trivial, but if you do not want your tool to be substandard, please consider the features that a current user normally expacts: the correct handling of nucleotide ambiquity codes, preserving upper/lowercase, handling spaces/numbers/newlines/FASTA header as expected and the like.