readALNfile | R Documentation |
Helper functions to read and/or write the files from Clustal, for Multiple Sequence Alignments (MSA)
readALN(file)
readNEXUS(file)
writeALN( aln, outfile, line.width = 60, title, capitalize = NULL, blankMissingFlanks = FALSE,
fastaToo = FALSE)
file , outfile |
full pathname to existing Clustal output file. Or a full pathname for a file to be written to. |
aln |
a MSA alignment object, as returned ba MAFFT. See |
line.width |
integer number of characters to write per line of output. |
capitalize |
Optional. Either a logical, or a character string in "uppper", "lower", controlling how the aligned characters are case converted or not. |
blankMissingFlanks |
logical, should the hyphens that denote gap characters at the very beginning and ending flanks of the MSA, which are only due to missing sequence instead of true insertions or deletions, be represented as blanks instead. |
fastaToo |
logical, should the sequences in the |
These function facilitate manipulation of MSA results as R objects.
For readNEXUS
, a character matrix, with a single letter for each element. The rownames
are the names of the sequences submitted to Clustal.
For readALN
, a list:
alignment |
a character matrix with a single letter for each element. |
consensus |
the 'consensus string' from below the MSA elements. |
pct.conserved |
numeric vector of the amount of sequence similarity along the MSA, expressing each column position as the percentage of rows that contain the most commonly observed character. |
For writeALN
, one or two files written to disk.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.