Learn R Programming

seqmagick (version 0.1.7)

download_genbank: download_genbank

Description

download genbank or fasta file by accession number

Usage

download_genbank(acc, db = "nuccore", format = "genbank", outfile = NULL, ...)

Value

output file vector

Arguments

acc

accession number(s)

db

supported db, currently 'nuccore'

format

one of 'genbank' or 'fasta'

outfile

output file, by default, acc.gb or acc.fa

...

additional parameters for download.file

Author

Guangchuang Yu

Examples

Run this code
if (FALSE) {
tmpgb <- tempfile(fileext = '.gb')
tmpfa <- tempfile(fileext = '.fa')
download_genbank(acc='AB115403', format='genbank', outfile=tmpgb)
download_genbank(acc='AB115403', format='fasta', outfile=tmpfa)
}

Run the code above in your browser using DataLab