develop_rxclass_data: Develop RxClass Data for a Release

View source: R/develop_rxclass_data.R

develop_rxclass_dataR Documentation

Develop RxClass Data for a Release

Description

Collect, load, and extract RxClass API responses into CONCEPT, CONCEPT_ANCESTOR, and CONCEPT_RELATIONSHIP csvs as part of package installation directory.

Usage

develop_rxclass_data(
  rela_sources = c("DAILYMED", "MESH", "FDASPL", "FMTSME", "VA", "MEDRT", "RXNORM",
    "SNOMEDCT"),
  class_types = c("MESHPA", "EPC", "MOA", "PE", "PK", "TC", "VA", "DISEASE", "DISPOS",
    "CHEM", "SCHEDULE", "STRUCT"),
  prior_version = NULL,
  prior_api_version = "3.1.174",
  open_readme = TRUE
)

Details

ATC classTypes and relaSources are excluded by default, but may be included if desired by adding both 'ATC1-4' to class_types and 'ATC' to rela_sources.

All API responses are cached using both the RxClass Version and API Version as the key. Depending on how much of the API responses are cached, this script can take multiple days if not weeks.

Since the output folder is a timestamp folder, many duplicate versions can be made each time it is run. There is no QA method that will crosscheck a previous version against the current version.

Value

A folder at inst/RxClass API/{version}/omop/{timestamp} containing a README with csvs.


meerapatelmd/setupRxNorm documentation built on Sept. 15, 2022, 9:25 a.m.