Copyright | (c) Dominik Schrempf 2021 |
---|---|
License | GPL-3.0-or-later |
Maintainer | dominik.schrempf@gmail.com |
Stability | unstable |
Portability | portable |
Safe Haskell | None |
Language | Haskell2010 |
Creation date: Thu May 16 07:58:50 2019.
The different universal codes. - https://www.ncbi.nlm.nih.gov/Taxonomy/Utils/wprintgc.cgi?mode=c - http://www.bioinformatics.org/sms2/genetic_code.html - https://en.wikipedia.org/wiki/Genetic_code
Synopsis
- newtype Codon a = Codon (a, a, a)
- fromVecUnsafe :: Vector v a => v a -> Codon a
- data UniversalCode
- translate :: UniversalCode -> Codon Nucleotide -> AminoAcidS
- translateX :: UniversalCode -> Codon NucleotideX -> AminoAcidS
- translateI :: UniversalCode -> Codon NucleotideI -> AminoAcidI
Documentation
Codons are triplets of characters.
Codon (a, a, a) |
fromVecUnsafe :: Vector v a => v a -> Codon a Source #
Unsafe conversion from vector with at least three elements; only the first three elements are used, the rest is discarded.
data UniversalCode Source #
Universal codes.
Instances
translate :: UniversalCode -> Codon Nucleotide -> AminoAcidS Source #
Translate a codon to amino acids including translation stops.
translateX :: UniversalCode -> Codon NucleotideX -> AminoAcidS Source #
Translate a codon to amino acids including translation stops. Translate codons including gaps to amino acid gaps. Be careful, single or two character gaps can lead to a reading frame shift and hence, the translated sequence may be bogus.
translateI :: UniversalCode -> Codon NucleotideI -> AminoAcidI Source #
Translate a codon to amino acids including translation stops. Translate gap triplets to amino acid gaps, and triplets including unknowns to amino acid unknowns. Be careful, also translates other IUPAC characters to amino acid Xs!