Description Usage Arguments Details Value Examples
load_db()
is a simple front-end to DBI functions which can be
used to load tables from a ukbschemas database (or in fact, any database;
see DBI::DBI-package).
1 |
file |
Full path to an SQLite database, or |
db |
A (possibly disconnected) database connection, or |
load_db()
will attempt to open an SQLite database from file
file
or from connection db
. It will throw errors if the file is not a
valid databse or it is impossible to create a valid connection from db
.
Tables are read with DBI::dbReadTable and converted to data frames of
class tbl_df
(see tibble::tibble). The database connection is always
closed before the function returns its result.
A named list with elements of class tbl_df
, containing the tables
from db
.
1 2 3 4 5 | ## Not run:
db <- ukbschemas_db(path = tempdir())
sch <- load_db(db = db)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.