bitnuc

Function encode

Source
pub fn encode(
    sequence: &[u8],
    ebuf: &mut Vec<u64>,
) -> Result<(), NucleotideError>
Expand description

Encode a sequence into a buffer of 2-bit encoded nucleotides.

§Arguments

  • sequence - The nucleotide sequence to encode.
  • ebuf - The buffer to write the encoded nucleotides to.

§Errors

If the sequence cannot be encoded, an error is returned.