Create a new local SQL database from downloaded files. Currently only GenBank/nucleotide/nuccore database is supported.

db_create(db_type = "nucleotide", min_length = 0, max_length = NULL,
  alt_restez_path = NULL)

Arguments

db_type

character, database type

min_length

Minimum sequence length, default 0.

max_length

Maximum sequence length, default NULL.

alt_restez_path

Alternative restez path if you would like to use the downloads from a different restez path.

Details

All .seq.gz files are added to the database. A user can specify sequence limit sizes for those sequences to be added to the database -- smaller databases are faster to search.

Alternatively, a user can use the alt_restez_path to add the files from an alternative restez file path. For example, you may wish to have a database of all environmental sequences but then an additional smaller one of just the sequences with lengths below 100 bp. Instead of having to download all environmental sequences twice, you can generate multiple restez databases using the same downloaded files from a single restez path.

This function will not overwrite a pre-existing database. Old databases must be deleted before a new one can be created. Use db_delete with everything=FALSE to delete an SQL database.

Connections/disconnections to the database are made automatically.

See also

Examples

# NOT RUN {
library(restez)
restez_path_set(filepath = 'path/for/downloads/and/database')
db_download()
db_create()
# }