read.names.sql | R Documentation |
Take an NCBI names file, keep only scientific names and convert it to a SQLite table
read.names.sql(nameFile, sqlFile = "nameNode.sqlite", overwrite = FALSE)
nameFile |
string giving the path to an NCBI name file to read from (both gzipped or uncompressed files are ok) |
sqlFile |
a string giving the path where the output SQLite file should be saved |
overwrite |
If TRUE, delete names table in database if present and regenerate |
invisibly returns a string with path to sqlfile
https://ftp.ncbi.nih.gov/pub/taxonomy/
read.nodes
namesText<-c(
"1\t|\tall\t|\t\t|\tsynonym\t|",
"1\t|\troot\t|\t\t|\tscientific name\t|",
"2\t|\tBacteria\t|\tBacteria <prokaryotes>\t|\tscientific name\t|",
"2\t|\tMonera\t|\tMonera <Bacteria>\t|\tin-part\t|",
"2\t|\tProcaryotae\t|\tProcaryotae <Bacteria>\t|\tin-part\t|"
)
tmpFile<-tempfile()
writeLines(namesText,tmpFile)
sqlFile<-tempfile()
read.names.sql(tmpFile,sqlFile)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.