Functions to support other functions.

example_dat(
  types = c("omim_id", "orphanet_id", "decipher_id", "hpo_id", "gene"),
  rm_types = NULL
)

get_data(
  file,
  tag = "latest",
  repo = "neurogenomics/KGExplorer",
  save_dir = cache_dir(),
  add_version = FALSE,
  overwrite = TRUE
)

messager(..., v = Sys.getenv("VERBOSE") != "FALSE", parallel = FALSE)

report_filter(g1, g2, cols, suffix = "remain after filtering.")

report_missing(dat, id_col, report_col)

stopper(..., v = TRUE)

Arguments

types

Types of IDs to include in the data.

file

Can be one of the following:

  • "ontology"Creates an ontology_DAG R object by importing the OBO file directly from the official uPheno GitHub repository.

  • "bestmatches"Returns a merged table with the best matches between human and non-human homologous phenotypes (from multiple species). Distributed by the official uPheno GitHub repository.

  • "upheno_mapping"Return a merged table with matches between human and non-human homologous phenotypes (from multiple species). Distributed by the Monarch Initiative server.

tag

tag for the GitHub release to which this data should be attached.

repo

Repository name in format "owner/repo". Defaults to guess_repo().

save_dir

Directory to save a file to.

add_version

Add the release version to the returned object's attributes

overwrite

Should any local files of the same name be overwritten? default TRUE.

...

Not used at this time.

v

Whether to print messages or not.

parallel

Whether to enable message print when wrapped in parallelised functions.

Value

Merged data.

data.table

Path to downloaded file or the object itself (when ".rds" format).

Null

Null

Functions

  • example_dat(): utils_ Example data

    Construct an example data.table containing diseases, phenotype, and/or genes.

  • get_data(): utils_ Get remote data

    Download remotely stored data via pb_download.

  • messager(): utils_ Print messages

    Conditionally print messages. Allows developers to easily control verbosity of functions, and meet Bioconductor requirements that dictate the message must first be stored to a variable before passing to message.

  • report_filter(): utils_

  • report_missing(): utils_

  • stopper(): utils_ Stop messages

    Conditionally print stop messages. Allows developers to easily control verbosity of functions, and meet Bioconductor requirements that dictate the stop message must first be stored to a variable before passing to stop.

Examples

dat <- example_dat()