Skip to main content

reverse_complement

Function reverse_complement 

Source
pub fn reverse_complement(seq: &[u8]) -> Vec<u8> 
Expand description

Reverse complement of a nucleotide sequence, as DNA.

assert_eq!(reverse_complement(b"ACGTn"), b"nACGT");
assert_eq!(reverse_complement(b"ACGU"), b"ACGT"); // uracil becomes thymine