get_db {cRegulome}R Documentation

Get cRegulome.db file


This function calls download.file to download the pre-build database file of cRegulome. Additionally, the function checks the validity of the pre-defined URL and whether the database file exists in the current working directory to avoid redownloading it. Typically, users would run this function once at the first time the use the package or to update the database to the latest version.


get_db(test = FALSE, destfile, ...)



A logical, default FALSE. When TRUE downloads a database file with the same structure with a subset of the data for speed.


A character vector for the desired path for the database file. By default, when not specified, is constructed by using tempdir as a directory and the string cRegulome.db.gz


Optional arguments passed to download.file


Downloads a compressed sqlite file to the current working directory. The file is named cRegulome.db.gz by default and it's not advised to change the name to avoid breaking the other functions that calls the database.


## Not run: 
# download a test set of the database
get_db(test = TRUE)

# download the full database file
get_db(test = FALSE)

## End(Not run)

# load the test db file from shipped with the pacakge
db_file <- system.file("extdata", "cRegulome.db", package = "cRegulome")

[Package cRegulome version 0.3.2 Index]