Functions to Work with Sequence Data
Return one- or three-letter abbreviations of amino acids; count nucleotides in nucleic acid sequences, calculate DNA and RNA complements of nucleic acid sequences.
1 2 3
numeric, 1 to return one-letter, 3 to return three-letter abbreviations for amino acids
character, which amino acids to name
data frame, counts of nucleic-acid bases
character, target type of nucleic acid (DNA or RNA)
aminoacids returns the one-letter abbreviations (
nchar=1) or the three-letter abbreviations (
nchar=3) or the names of the neutral amino acids (
nchar="") or the names of the amino acids with ionized side chains (
The output includes 20 amino acids in alphabetic order by 1-letter abbreviation (the order used in
which is provided, indicating the desired amino acids (either as 1- or 3-letter abbreviations or names of the neutral amino acids).
nucleic.formula returns a string representation of the chemical formula for each nucleic-acid composition contained in
The names of the bases are indicated by the column names of
At present, the formula is computed as the sum of the chemical formulas of the bases themselves, with no contribution from polymerization (dehydration) or phosphorylation.
nucleic.complement calculates the complement of the base composition given in
type specifies the type of nucleic acid of the complement - DNA (A, G, C, T) or RNA (A, G, C, U).
count.aa for counting amino acids or nucleic-acid bases in a sequence;
protein.formula for calculating the chemical formulas of proteins.
1 2 3 4 5 6 7 8
## count nucleobases in a sequence bases <- count.aa("ACCGGGTTT", type="DNA") # the DNA complement of that sequence DNA.comp <- nucleic.complement(bases) # the RNA complement of the DNA complement RNA.comp <- nucleic.complement(DNA.comp, type="RNA") # the formula of the RNA complement (bases only) nucleic.formula(RNA.comp) # C40H42N32O11
Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.