View source: R/write_sequences.r
write_sequences | R Documentation |
Write sequences to a file
write_sequences(seq, file = "", format = NULL, ...) write_fasta(seq, file = "", nchar = 80) write_nexus(seq, file = "", datatype = NULL, missing = NULL, gap = NULL)
seq |
a named vector of sequences |
file |
a character string naming a file |
format |
**optional** write sequences in this format, currently supported formats are 'fasta' and 'nexus' |
... |
**optional** parameters passed to the underlying function |
nchar |
**optional** a number of characters per line |
datatype |
**optional** the type of data |
missing |
**optional** symbol representing missing data |
gap |
**optional** symbol representing a gap in aligned sequence |
seq1 = c("A" = "AAA", "B" = "BBB", "C" = "CCC") fasta = tempfile(fileext = ".fasta") write_fasta(seq1, fasta) seq2 = read_fasta(fasta) identical(seq1, seq2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.