msa | R Documentation |
Aligns multiple protein, DNA or CDS sequences using inhouse software.
msa(sequences, ids = names(sequences), seqtype = "prot", method, sfile = FALSE)
sequences |
vector containing the sequences as strings. |
ids |
character vector containing the sequences' ids. |
seqtype |
it should be either "prot" of "dna" or "cds" (see details). |
method |
the software to be used for the alignment, as invoked in your system. For instance, "muscle3" or "clustalo". |
sfile |
if different to FALSE, then it should be a string indicating the path to save a fasta alignment file. |
Either Clustal Omega or MUSCLE must be installed, and their executable be in your system's PATH. If seqtype is set to "cds" the sequences must not contain stop codons and they will be translated using the standard code. Afterward, the amino acid alignment will be used to lead the codon alignment.
Returns a list of four elements. The first one ($seq) provides the sequences analyzed, the second element ($id) returns the identifiers, the third element ($aln) provides the alignment in fasta format and the fourth element ($ali) gives the alignment in matrix format.
## Not run: msa(sequences = c("APGW", "AGWC", "CWGA"),
ids = c("a", "b", "c"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.