gb_sequence_get {restez} | R Documentation |
Get sequence from GenBank
Description
Return the sequence(s) for a record(s) from the accession ID(s).
Usage
gb_sequence_get(id, dnabin = FALSE)
Arguments
id |
character, sequence accession ID(s) |
dnabin |
Logical vector of length 1; should the sequences be returned using the bit-level coding scheme of the ape package? Default FALSE. |
Details
For more information about the dnabin
format, see ape::DNAbin()
.
Value
named vector of sequences, if no results found NULL
See Also
Other get:
gb_definition_get()
,
gb_fasta_get()
,
gb_organism_get()
,
gb_record_get()
,
gb_version_get()
Examples
library(restez)
restez_path_set(filepath = tempdir())
demo_db_create(n = 5)
(seq <- gb_sequence_get(id = 'demo_1'))
(seqs <- gb_sequence_get(id = c('demo_1', 'demo_2')))
(fasta_dnabin <- gb_sequence_get(id = 'demo_1', dnabin = TRUE))
# delete demo after example
db_delete(everything = TRUE)
[Package restez version 2.1.4 Index]