Nothing
## ----include = FALSE----------------------------------------------------------
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
message = FALSE
)
## -----------------------------------------------------------------------------
library(dbparser)
## -----------------------------------------------------------------------------
drugbank <- parseDrugBank(
system.file("extdata", "drugbank_record_biotech.xml", package = "dbparser"))
## -----------------------------------------------------------------------------
show_dvobject_metadata(drugbank)
## -----------------------------------------------------------------------------
metadata <- get_source_metadata(drugbank)
fields <- c("source", "release", "release_date", "source_url",
"licence_url", "parser")
data.frame(field = fields,
value = vapply(fields, function(f) as.character(metadata[[f]]), ""),
row.names = NULL)
## -----------------------------------------------------------------------------
cat(strwrap(metadata$attribution), sep = "\n")
## -----------------------------------------------------------------------------
metadata$files[[1]]
## -----------------------------------------------------------------------------
hgnc_dir <- system.file("extdata", "hgnc", package = "dbparser")
hgnc <- parseHGNC(file.path(hgnc_dir, "hgnc_complete_set.txt"),
withdrawn_path = file.path(hgnc_dir, "withdrawn.txt"),
release = "2026-10",
retrieved_at = "2026-10-16")
sapply(hgnc, dim)
## -----------------------------------------------------------------------------
pd1 <- hgnc$gene_name[hgnc$gene_name$name == "PD1", ]
genes <- hgnc$gene[, c("hgnc_id", "symbol", "name")]
names(genes)[3] <- "approved_name"
merge(pd1, genes, by = "hgnc_id")
## -----------------------------------------------------------------------------
hgnc$withdrawn[hgnc$withdrawn$withdrawn_symbol == "CBBM",
c("hgnc_id", "withdrawn_symbol", "merged_into_symbol")]
## -----------------------------------------------------------------------------
hgnc_metadata <- get_source_metadata(hgnc)
fields <- c("source", "release", "retrieved_at", "licence",
"licence_url")
data.frame(field = fields,
value = vapply(fields,
function(f) as.character(hgnc_metadata[[f]]), ""),
row.names = NULL)
cat(strwrap(hgnc_metadata$attribution), sep = "\n")
hgnc_metadata$files[[1]]
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.