diff --git a/DESCRIPTION b/DESCRIPTION index 5901b15..17662b2 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,10 +1,11 @@ Package: cdiscdata Title: Versioned CDISC Standards Reference Data -Version: 0.1.0 +Version: 0.2.0 Authors@R: person("Bill", "Denney", email = "wdenney@humanpred.com", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-5759-428X")) -Description: Provides versioned CDISC Controlled Terminology (SDTM, ADaM) +Description: Provides versioned CDISC Controlled Terminology (SDTM, ADaM), + SDTM Model/SDTMIG and ADaMIG implementation-guide variable metadata, and Define-XML schemas (XSD) and CDISC XSLT stylesheets. Uses a validity-date design to store all historical CT versions compactly without redundant row duplication. Intended as a shared data @@ -18,7 +19,9 @@ Suggests: covr, pkgdown, knitr, - rmarkdown + rmarkdown, + callr, + pkgbuild LazyData: true LazyDataCompression: xz Encoding: UTF-8 @@ -26,4 +29,4 @@ Config/testthat/edition: 3 URL: https://github.com/humanpred/cdiscdata, https://humanpred.github.io/cdiscdata/ BugReports: https://github.com/humanpred/cdiscdata/issues VignetteBuilder: knitr -RoxygenNote: 7.3.3 +Config/roxygen2/version: 8.1.0 diff --git a/NAMESPACE b/NAMESPACE index da9eb8e..aa2a9fa 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -1,9 +1,11 @@ # Generated by roxygen2: do not edit by hand export(available_ct_versions) +export(build_domain_spec) export(cdiscdata_versions) export(get_ct) export(get_dataset) +export(get_ig) export(list_datasets) export(schema_path) export(stylesheet_path) diff --git a/NEWS.md b/NEWS.md index 159cbdb..8b2c216 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,127 @@ +# cdiscdata 0.2.0 + +## Classed conditions and coverage + +* Every error and warning `get_ig()` and `build_domain_spec()` raise is now + classed (e.g. `cdiscdata_error_ig_version_unavailable`, + `cdiscdata_error_no_ig_variables`, `cdiscdata_warning_adsl_ignored`), so + they can be caught or asserted on by class rather than by matching + message text. Implemented with a small internal `.cdiscdata_abort()`/ + `.cdiscdata_warn()` helper rather than a new dependency (e.g. rlang), to + keep the package's zero-runtime-dependency design. +* `build_domain_spec()` is now at 100% line coverage; two defensive checks + (an SDTMIG/ADaMIG version with no rows for the requested domain/dataset - + not reachable via the public API with the currently bundled `ig_sdtm`/ + `ig_adam`, since every version there has PP/SUPPQUAL/BDS rows) are + exercised directly via mocking `get_ig()`. + +## CT refresh + +* Added the 2026-09-25 NCI SDTM and ADaM CT releases (previous latest: + 2026-03-27), while keeping every historical release already bundled. + - SDTM CT 2026-09-25: 41 new/changed codelists, 765 new/changed terms. + - ADaM CT 2026-09-25: 2 new/changed codelists, 11 new/changed terms. +* Fixed a parser bug (`data-raw/utils_nci.R`) that had silently left + `codelist_name` `NA` for every row of `ct_sdtm`/`ct_adam` for every NCI + release from 2012 onward (`codelist_name` and `codelist_code` are used to + look up a codelist by name, e.g. by `get_ig()`/`build_domain_spec()`, so + this previously made resolving PKPARMCD/PKPARM/PKUNIT - or any other + codelist by name - unreliable). The header-row detection this relied on + assumed the NCI source file repeats a codelist's own C-code in both its + "Code" and "Codelist Code" columns; from 2012 on, NCI instead leaves + "Codelist Code" blank on that row, which the previous logic never + matched. All bundled historical releases were re-parsed from scratch with + the fix (re-downloading the ~110 archived releases involved, now cached + as raw text going forward so a future parser fix would not need to). A + handful of older (2007-2010, plus one 2017) archival releases have + further, rarer source-data quirks this could not fully resolve; the + *current* release is verified clean, and the historical gap is bounded by + `tests/testthat/test-data_integrity.R` rather than silently tolerated. +* Fixed `list_archive_dates()`, which had been silently returning zero + dates: NCI rebuilt evs.nci.nih.gov as a JavaScript single-page app at some + point in 2024-2025, so the Archive/ directory URL this scraped for file + names now serves that app's empty HTML shell instead of a plain listing. + It now calls the JSON API the app itself uses + (`GET /ftp1/folder?folder=`) instead; see the comment above + `list_archive_dates()` in `data-raw/utils_nci.R` for that API's one + limitation (no working pagination past 1000 entries) and why it does not + affect finding every release date in practice. `fetch_current_release_date()` + (previously reading NCI's Publication Date Stamp file, which changed + format at least twice - a bare date, then "SDTM Terminology YYYY-MM-DD", + then, as of 2026, a small table - and 403'd from GitHub Actions in + between) was replaced with a derivation from this same, now-working + archive listing (`origin/main` PR "fix/nci-stamp-403-fallback", merged + into this branch). +* Investigated a reported gap in `available_ct_versions()` - SDTM CT + appeared to be missing the 2024-06, 2024-12, 2025-06, 2025-12, and + 2026-06 quarterly releases. Verified directly against NCI's own file + listing (not assumed): none of these five releases exist for either + SDTM or ADaM - NCI shifted SDTM CT from quarterly to semi-annual + (March/September) releases starting in 2024, and ADaM CT has never been + reliably quarterly (gaps of 266-448 days recur from 2017 on, long before + 2024). There was nothing to backfill. Added + `tests/testthat/test-data_integrity.R` gap tests calibrated to each + type's actual verified history (200 days for SDTM, 500 days for ADaM; + not a single ~120-day bound, which would flag the genuine 2024-on + semi-annual gaps as failures) plus a freshness check, so a release that + is *actually* skipped or a fetch workflow that silently stops running + would still fail loudly. +* Verified `PKPARMCD` (C85839), `PKPARM` (C85493), and `PKUNIT` (C85494) + are present in the 2026-09-25 release and returned by `get_ct("sdtm")`. + +## Attach-only bug fix + +* Fixed `get_ct()`, `get_dataset()`, `list_datasets()`, + `cdiscdata_versions()`, and `available_ct_versions()` to work via + `cdiscdata::` alone, without `library(cdiscdata)` first. Lazy-loaded + package data (`ct_sdtm`, `ct_adam`, `ig_sdtm`, `ig_adam`, + `datasets_catalogue`) is only wired into the search path when the package + is *attached*; loading just the namespace (as `::` does) left an + unqualified reference to that data unresolved, even from inside the + package's own functions - e.g. `cdiscdata::get_ct("sdtm")` without a + prior `library()` call errored with `object 'datasets_catalogue' not + found`. Fixed via an internal `.pkg_data()` helper that loads a dataset + explicitly with `utils::data()`, independent of attach state. Verified by + a dedicated test (`tests/testthat/test-attach.R`) that builds and + installs the package into a fresh library and calls it via `callr::r()` + in a brand-new subprocess with no `library()` call. + +## New: implementation-guide (IG) variable metadata + +* Added `ig_sdtm`: SDTM Model Findings general-observation-class variables + (versions 1.4-1.7), plus the SDTMIG PP domain and the generic SUPP-- + qualifier structure (version 3.2 only - see + `data-raw/ig_source/README.md` for why no newer SDTMIG version's PP/SUPP-- + tables were available to source). +* Added `ig_adam`: ADaMIG ADSL (subject-level) and BDS (Basic Data + Structure, used by ADPP) variable tables, for versions 1.0, 1.1, and 1.2. +* Added `get_ig(standard, version)`, mirroring `get_ct()`. +* Added `build_domain_spec(domain, ig_version, ct_version, adsl)`, returning + a ready-to-use variable spec (name, label, type, length, core, order, + source, codelist id) for `"PP"`, `"SUPPPP"` (via the generic SUPP-- + structure), or `"ADPP"` (via the generic BDS structure, joined against CT + for codelist ids). For `"ADPP"`, `adsl = TRUE` (the default) also unions + in the ADaMIG ADSL variables - a real ADPP carries ADSL's subject-level + variables alongside its own BDS variables - marked `source = "ADSL"` and + `core = "Perm"` (ADSL's own Core reflects requirements for ADSL itself, + not for merging a variable into ADPP, which is always optional); a + variable defined by both tables (e.g. `STUDYID`, `USUBJID`) keeps its BDS + version rather than being duplicated. `adsl = FALSE` returns the BDS + variables alone, as before. Neither table carries PP's own variables + (`PPTESTCD` and the rest) forward into ADPP; that remains a downstream + derivation choice, not IG metadata this function sources. +* `get_ig()`/`ig_sdtm`'s SDTMIG-3.2-only coverage of the PP domain and + SUPP-- structure is now called out explicitly in `get_ig()`'s + documentation, including the specific known gaps versus a newer SDTMIG + (`PPANMETH`, `EPOCH`, `PTAETORD` not yet added; SDTMIG 3.2 still has + `PPDTC`, not the later `PPPDTC` rename). +* IG metadata is transcribed from CDISC's own published SDTM + Model/SDTMIG/ADaMIG specification tables, copied read-only (with + attribution) from Bill Denney's private Rsdtm package - see + `data-raw/ig_source/README.md`. This supersedes the package's original + plan to leave all IG metadata to a separate `cdiscapi` package; the + README has been updated accordingly. + # cdiscdata 0.1.0 * First release of `cdiscdata`. diff --git a/R/available_versions.R b/R/available_versions.R index 601e82e..445cd6e 100644 --- a/R/available_versions.R +++ b/R/available_versions.R @@ -9,7 +9,7 @@ #' available_ct_versions("adam") available_ct_versions <- function(type = c("sdtm", "adam")) { type <- match.arg(type) - tbl <- switch(type, sdtm = ct_sdtm, adam = ct_adam) + tbl <- switch(type, sdtm = .pkg_data("ct_sdtm"), adam = .pkg_data("ct_adam")) # valid_from must never be NA — enforced at ingestion time in data-raw/ dates <- sort(unique(tbl$valid_from), decreasing = TRUE) as.character(dates) diff --git a/R/build_domain_spec.R b/R/build_domain_spec.R new file mode 100644 index 0000000..13889a9 --- /dev/null +++ b/R/build_domain_spec.R @@ -0,0 +1,154 @@ +#' Build a variable specification for PP, SUPPPP, or ADPP +#' +#' Combines \code{\link{get_ig}} (variable name, label, type, core, order) +#' with \code{\link{get_ct}} (codelist id lookup) into a single, ready-to-use +#' variable specification for one of the three PK datasets. \code{PP} and +#' \code{SUPPPP} draw on the SDTMIG (\code{SUPPPP} from the generic SUPP-- +#' structure, since CDISC has no domain-specific SUPPPP table); \code{ADPP} +#' draws on the ADaMIG BDS (Basic Data Structure) table, since ADPP is a BDS +#' dataset and CDISC has no ADPP-specific table either, optionally unioned +#' with the ADaMIG ADSL table (see \code{adsl} below), since a real ADPP +#' also carries ADSL's subject-level variables. +#' +#' This does not add PP-inherited traceability variables (\code{PPTESTCD}, +#' \code{PPTEST}, and the rest of PP's variables that a BDS dataset built +#' from PP typically carries forward). Neither the ADaMIG BDS nor ADSL +#' tables define those; which of PP's variables to carry into ADPP, and +#' under what names, is a downstream derivation choice (e.g. admiral's own +#' conventions), not IG metadata this function can source. +#' +#' @param domain One of \code{"PP"}, \code{"SUPPPP"}, or \code{"ADPP"}. +#' @param ig_version IG version to use: an SDTMIG version (for \code{PP}/ +#' \code{SUPPPP}) or an ADaMIG version (for \code{ADPP}). +#' \code{NULL} uses the newest available for that IG. +#' @param ct_version CT version to resolve codelist ids against; passed to +#' \code{\link{get_ct}}. \code{NULL} uses the newest available. +#' @param adsl For \code{domain = "ADPP"} only: whether to union in the +#' ADaMIG ADSL variables (default \code{TRUE}), since a real ADPP dataset +#' carries ADSL's subject-level variables (treatment, demographics, ...) +#' alongside its own BDS variables. \code{FALSE} returns the BDS variables +#' alone. Ignored (with a warning) for \code{domain != "ADPP"}. +#' @return A data frame with columns \code{variable}, \code{label}, +#' \code{type}, \code{length}, \code{core}, \code{order}, \code{source} +#' (\code{"SDTMIG"} for \code{PP}/\code{SUPPPP}; \code{"BDS"} or +#' \code{"ADSL"} for \code{ADPP}), and \code{codelist_id} (the codelist's +#' CT C-code, e.g. \code{"C85839"} for PPTESTCD's PKPARMCD codelist; +#' \code{NA} when the variable has no codelist or the referenced codelist +#' name is not found in the CT version used). ADSL-sourced \code{ADPP} rows +#' have \code{core} forced to \code{"Perm"} regardless of their Core +#' designation in ADSL itself: from ADPP's perspective, merging in an +#' ADSL variable is a common but optional choice, not a requirement ADSL's +#' own Core reflects. +#' @export +#' @examples +#' build_domain_spec("PP") +#' build_domain_spec("SUPPPP") +#' build_domain_spec("ADPP") # BDS + ADSL (default) +#' build_domain_spec("ADPP", adsl = FALSE) # BDS only +build_domain_spec <- function(domain = c("PP", "SUPPPP", "ADPP"), + ig_version = NULL, ct_version = NULL, + adsl = TRUE) { + domain <- match.arg(domain) + if (domain != "ADPP" && !isTRUE(adsl)) { + .cdiscdata_warn( + "`adsl` is ignored for domain != \"ADPP\".", + "adsl_ignored" + ) + } + + if (domain %in% c("PP", "SUPPPP")) { + ig_domain <- if (domain == "PP") "PP" else "SUPPQUAL" + sdtmig_all <- get_ig("sdtm") + sdtmig_all <- sdtmig_all[sdtmig_all$source == "SDTMIG", ] + version <- .resolve_ig_version(ig_version, sdtmig_all$version, "SDTMIG") + sub <- sdtmig_all[sdtmig_all$domain == ig_domain & sdtmig_all$version == version, ] + if (nrow(sub) == 0L) { + .cdiscdata_abort( + paste0("No SDTMIG '", ig_domain, "' variables found for version '", version, "'."), + "no_ig_variables" + ) + } + ct <- get_ct("sdtm", version = ct_version) + sub$source <- "SDTMIG" + codelist_id <- .lookup_codelist_id(sub$codelist, ct) + } else { + adamig_all <- get_ig("adam") + version <- .resolve_ig_version(ig_version, adamig_all$version, "ADaMIG") + bds <- adamig_all[adamig_all$dataset == "BDS" & adamig_all$version == version, ] + if (nrow(bds) == 0L) { + .cdiscdata_abort( + paste0("No ADaMIG BDS variables found for version '", version, "'."), + "no_ig_variables" + ) + } + bds$source <- "BDS" + ct_adam <- get_ct("adam", version = ct_version) + + if (isTRUE(adsl)) { + adsl_tbl <- adamig_all[adamig_all$dataset == "ADSL" & adamig_all$version == version, ] + # ADSL and BDS both define several shared base variables (STUDYID, + # USUBJID, ...); a real ADPP carries each once, so ADSL contributes + # only the variables BDS does not already define, keeping BDS's + # version (and its own Core) for anything in both. + adsl_tbl <- adsl_tbl[!adsl_tbl$variable %in% bds$variable, ] + adsl_tbl$source <- "ADSL" + adsl_tbl$core <- "Perm" + adsl_tbl$order <- max(bds$order) + seq_len(nrow(adsl_tbl)) + sub <- rbind(bds, adsl_tbl) + # ADSL variables carried from SDTM DM (SEX, RACE, AGEU, ...) reuse + # SDTM's codelists, not ADaM's much smaller CT; ADaM CT is checked + # first (matching the BDS-only behaviour), SDTM CT second. + ct_sdtm <- get_ct("sdtm", version = ct_version) + codelist_id <- .lookup_codelist_id(sub$codelist, ct_adam) + fallback <- is.na(codelist_id) & !is.na(sub$codelist) + codelist_id[fallback] <- .lookup_codelist_id(sub$codelist[fallback], ct_sdtm) + } else { + sub <- bds + codelist_id <- .lookup_codelist_id(sub$codelist, ct_adam) + } + } + + data.frame( + variable = sub$variable, + label = sub$label, + type = sub$type, + length = sub$length, + core = sub$core, + order = sub$order, + source = sub$source, + codelist_id = codelist_id, + stringsAsFactors = FALSE + ) +} + +# Resolve ig_version = NULL to the newest version present in `versions` +# (numeric comparison via package_version, so "1.10" would correctly rank +# above "1.9"); abort with the available list on an unknown explicit version. +.resolve_ig_version <- function(ig_version, versions, label) { + avail <- sort(unique(versions)) + if (is.null(ig_version)) { + return(as.character(max(package_version(avail)))) + } + if (!ig_version %in% avail) { + .cdiscdata_abort( + paste0( + "Version '", ig_version, "' is not available for ", label, ". ", + "Available versions: ", paste(avail, collapse = ", "), "." + ), + "ig_version_unavailable" + ) + } + ig_version +} + +# Map codelist submission values (e.g. "PKPARMCD") to their CT C-code (e.g. +# "C85839") via the codelist header rows (term_code is NA for those). +# NA in `codelist_names` (no codelist referenced) and names not found in +# this CT version (e.g. a codelist introduced in a CT release older/newer +# than the one used) both resolve to NA, not an error: the caller decides +# whether an unresolved codelist id is acceptable. +.lookup_codelist_id <- function(codelist_names, ct) { + headers <- ct[is.na(ct$term_code), ] + headers <- headers[!duplicated(headers$codelist_name), ] + headers$codelist_code[match(codelist_names, headers$codelist_name)] +} diff --git a/R/cdiscdata_versions.R b/R/cdiscdata_versions.R index c43eaaf..3463693 100644 --- a/R/cdiscdata_versions.R +++ b/R/cdiscdata_versions.R @@ -8,5 +8,5 @@ cdiscdata_versions <- function() { cat_cols <- c("dataset", "type", "description", "latest", "n_versions", "last_updated") - datasets_catalogue[, cat_cols] + .pkg_data("datasets_catalogue")[, cat_cols] } diff --git a/R/data.R b/R/data.R index 61ab6fd..111151b 100644 --- a/R/data.R +++ b/R/data.R @@ -35,6 +35,88 @@ #' @source \url{https://evs.nci.nih.gov/ftp1/CDISC/ADaM/} "ct_adam" +#' SDTM implementation-guide variable metadata +#' +#' Versioned SDTM Model and SDTMIG variable metadata: the Model's Findings +#' general-observation-class variables (versions 1.4-1.7), the SDTMIG PP +#' domain, and the SDTMIG generic SUPP-- qualifier structure (used for +#' SUPPPP; version 3.2 only - see \code{data-raw/ig_source/README.md} for +#' why no newer SDTMIG version's PP/SUPP-- tables were available to source). +#' Use \code{\link{get_ig}} to retrieve it, and +#' \code{\link{build_domain_spec}} to build a ready-to-use PP/SUPPPP/ADPP +#' variable spec from it (joined to CT for codelist ids). +#' +#' @format A data frame with columns: +#' \describe{ +#' \item{source}{\code{"SDTM_MODEL"} or \code{"SDTMIG"}.} +#' \item{version}{SDTM Model version (\code{"1.4"}-\code{"1.7"}) for +#' \code{source == "SDTM_MODEL"} rows; SDTMIG version (\code{"3.2"}) for +#' \code{source == "SDTMIG"} rows. The two are independent numbering +#' systems; see \code{\link{get_ig}}.} +#' \item{class}{General observation class, e.g. \code{"Findings"}. +#' \code{NA} for \code{SDTMIG} rows.} +#' \item{domain}{\code{"PP"} or \code{"SUPPQUAL"} for \code{SDTMIG} rows. +#' \code{NA} for \code{SDTM_MODEL} rows.} +#' \item{order}{Row order within its source table, as published.} +#' \item{variable}{Variable name, e.g. \code{"PPTESTCD"}.} +#' \item{label}{Variable label.} +#' \item{type}{\code{"Char"} or \code{"Num"}.} +#' \item{role}{CDISC variable role, e.g. \code{"Topic"}. \code{NA} for +#' ADaM rows (not applicable, and not present in \code{ig_adam}).} +#' \item{core}{SDTMIG Core designation (\code{"Req"}/\code{"Exp"}/ +#' \code{"Perm"}). \code{NA} for \code{SDTM_MODEL} rows (the model does +#' not designate Core; that is an IG-level concept).} +#' \item{codelist}{Codelist submission value referenced by this variable +#' (e.g. \code{"PKPARMCD"}), parsed from the IG's free-text +#' "Controlled Terms" column. Look up its codelist C-code via +#' \code{\link{get_ct}}'s \code{codelist_name}/\code{codelist_code} +#' columns, as \code{\link{build_domain_spec}} does. \code{NA} when the +#' variable has no codelist, or the column instead names a format +#' (e.g. "ISO 8601") or an unspecified extensible list ("*").} +#' \item{length}{Maximum character length, when the IG text states one +#' explicitly (e.g. PPTESTCD's 8-character limit); \code{NA} otherwise, +#' since CDISC implementation guides do not otherwise publish a Length +#' column (length is a sponsor/define.xml choice).} +#' \item{notes}{CDISC Notes / Description text for the variable.} +#' } +#' @source \url{https://github.com/humanpred/Rsdtm}; see +#' \code{data-raw/ig_source/README.md} for full attribution. +"ig_sdtm" + +#' ADaM implementation-guide variable metadata +#' +#' Versioned ADaMIG variable metadata: the ADSL (subject-level) variable +#' table and the generic BDS (Basic Data Structure) variable table (used for +#' ADPP, a BDS-structured dataset), for ADaMIG versions 1.0, 1.1, and 1.2. +#' Use \code{\link{get_ig}} to retrieve it, and +#' \code{\link{build_domain_spec}} to build a ready-to-use ADPP variable +#' spec from it (joined to CT for codelist ids). +#' +#' @format A data frame with columns: +#' \describe{ +#' \item{dataset}{\code{"ADSL"} or \code{"BDS"}.} +#' \item{version}{ADaMIG version, e.g. \code{"1.2"}.} +#' \item{category}{The Rsdtm source file's variable-category name (e.g. +#' \code{"ADSL_Treatment_Variables"}, \code{"Timing_Variables_BDS_Datasets"}), +#' kept for provenance; ADaMIG itself does not group these tables this +#' way.} +#' \item{order}{Row order within its category file, as published.} +#' \item{variable}{Variable name, e.g. \code{"AVAL"}.} +#' \item{label}{Variable label.} +#' \item{type}{\code{"Char"} or \code{"Num"}.} +#' \item{core}{ADaMIG Core designation (\code{"Req"}/\code{"Exp"}/ +#' \code{"Perm"}/\code{"Cond"}).} +#' \item{codelist}{Codelist submission value referenced by this variable, +#' parsed the same way as \code{\link{ig_sdtm}}'s \code{codelist} +#' column; see there for details and caveats.} +#' \item{length}{Maximum character length when the IG text states one +#' explicitly; \code{NA} otherwise. See \code{\link{ig_sdtm}}.} +#' \item{notes}{CDISC Notes text for the variable.} +#' } +#' @source \url{https://github.com/humanpred/Rsdtm}; see +#' \code{data-raw/ig_source/README.md} for full attribution. +"ig_adam" + #' Datasets catalogue #' #' Metadata about all datasets bundled in \code{cdiscdata}, including CT diff --git a/R/get_dataset.R b/R/get_dataset.R index 3549be4..45abc68 100644 --- a/R/get_dataset.R +++ b/R/get_dataset.R @@ -26,7 +26,8 @@ get_dataset <- function(name, version = NULL) { )) } - cat_row <- datasets_catalogue[datasets_catalogue$dataset == name, ] + catalogue <- .pkg_data("datasets_catalogue") + cat_row <- catalogue[catalogue$dataset == name, ] switch(cat_row$type, "CT" = .get_ct_dataset(name, version), @@ -37,7 +38,7 @@ get_dataset <- function(name, version = NULL) { # Internal: filter CT table to a specific version date .get_ct_dataset <- function(name, version) { - tbl <- get(name, envir = asNamespace("cdiscdata")) + tbl <- .pkg_data(name) ct_type <- if (grepl("sdtm", name, fixed = TRUE)) "sdtm" else "adam" version_date <- .resolve_ct_version(version, ct_type) tbl[tbl$valid_from <= version_date & diff --git a/R/get_ig.R b/R/get_ig.R new file mode 100644 index 0000000..161fd68 --- /dev/null +++ b/R/get_ig.R @@ -0,0 +1,53 @@ +#' Retrieve CDISC implementation-guide variable metadata +#' +#' Mirrors \code{\link{get_ct}}, but for implementation-guide (IG) variable +#' metadata rather than controlled terminology. Unlike CT, which uses a +#' single validity-date timeline per standard, \code{ig_sdtm} bundles two +#' independently-versioned sources (the SDTM Model and the SDTMIG; see +#' \code{\link{ig_sdtm}}), so there is no single "latest" snapshot to default +#' to: \code{version = NULL} returns every source and version, for the +#' caller to filter further (by \code{source}/\code{domain}/\code{class} for +#' \code{ig_sdtm}, or \code{dataset}/\code{category} for \code{ig_adam}). +#' \code{\link{build_domain_spec}} does this filtering for the PP, SUPPPP, +#' and ADPP datasets specifically. +#' +#' \strong{SDTMIG coverage.} The SDTMIG PP domain and the generic SUPP-- +#' structure are only available at version 3.2, because that is as far as +#' the Rsdtm source this package copies from goes (see +#' \code{data-raw/ig_source/README.md}); no newer SDTMIG's PP/SUPP-- tables +#' were available to source. As a result, PP variables CDISC added or +#' renamed after SDTMIG 3.2 are absent from \code{ig_sdtm} - notably +#' \code{PPANMETH}, \code{EPOCH}, and \code{PTAETORD} (added later), and the +#' \code{PPDTC} to \code{PPPDTC} rename (SDTMIG 3.2 still has \code{PPDTC}). +#' Sourcing a newer SDTMIG - via a CDISC Library API key or a newer public +#' transcription - would close this gap. +#' +#' @param standard One of \code{"sdtm"} or \code{"adam"}. +#' @param version A version string present in the \code{version} column +#' (e.g. \code{"3.2"} for SDTMIG, \code{"1.7"} for the SDTM Model, +#' \code{"1.2"} for ADaMIG). \code{NULL} (the default) returns all +#' versions. +#' @return A data frame: \code{\link{ig_sdtm}} or \code{\link{ig_adam}}, +#' optionally filtered to one version. +#' @export +#' @examples +#' get_ig("sdtm") +#' get_ig("sdtm", version = "3.2") +#' get_ig("adam", version = "1.2") +get_ig <- function(standard = c("sdtm", "adam"), version = NULL) { + standard <- match.arg(standard) + tbl <- .pkg_data(paste0("ig_", standard)) + if (is.null(version)) return(tbl) + + avail <- sort(unique(tbl$version)) + if (!version %in% avail) { + .cdiscdata_abort( + paste0( + "Version '", version, "' is not available for standard '", standard, "'. ", + "Available versions: ", paste(avail, collapse = ", "), "." + ), + "ig_version_unavailable" + ) + } + tbl[tbl$version == version, ] +} diff --git a/R/list_datasets.R b/R/list_datasets.R index d7ebd62..458d077 100644 --- a/R/list_datasets.R +++ b/R/list_datasets.R @@ -6,5 +6,5 @@ #' @examples #' list_datasets() list_datasets <- function() { - datasets_catalogue + .pkg_data("datasets_catalogue") } diff --git a/R/utils.R b/R/utils.R index b441e37..ab5c925 100644 --- a/R/utils.R +++ b/R/utils.R @@ -2,7 +2,44 @@ # Suppress R CMD check notes about lazy-loaded package data objects # that are not visible to the static checker. -utils::globalVariables(c("ct_sdtm", "ct_adam", "datasets_catalogue")) +utils::globalVariables(c("ct_sdtm", "ct_adam", "ig_sdtm", "ig_adam", "datasets_catalogue")) + +# Retrieve one of the package's own lazy-loaded datasets (ct_sdtm, ct_adam, +# datasets_catalogue, ...) regardless of whether cdiscdata is attached. +# +# LazyData promises are only wired into the *search path* when a package is +# attached with library()/require(); loading just the namespace (as `::` +# does, and as every other package's `pkg::fun()` call does) does not make +# an unqualified reference to a lazy dataset resolve, even from inside the +# package's own functions defined in that namespace. utils::data() with an +# explicit envir sidesteps this: it reads the installed data directory +# directly from the package's installation metadata, independent of +# attach/namespace-load state, so it works identically from `library()`, +# `cdiscdata::fn()`, and a fresh callr::r() session with `::` alone. +.pkg_data <- function(name) { + e <- new.env(parent = emptyenv()) + utils::data(list = name, package = "cdiscdata", envir = e) + e[[name]] +} + +# Signal a classed error/warning without adding a runtime dependency (e.g. +# rlang) just for condition classes. `class` is a short suffix, prefixed +# with "cdiscdata_error_"/"cdiscdata_warning_" so every condition this +# package raises is findable by class (tryCatch/testthat::expect_error(..., +# class = ...)) without depending on exact message text. +.cdiscdata_abort <- function(message, class) { + stop(structure( + class = c(paste0("cdiscdata_error_", class), "error", "condition"), + list(message = message, call = sys.call(-1L)) + )) +} + +.cdiscdata_warn <- function(message, class) { + warning(structure( + class = c(paste0("cdiscdata_warning_", class), "warning", "condition"), + list(message = message, call = sys.call(-1L)) + )) +} # Validate that a data frame has all required columns. # Returns the data frame invisibly on success; stops on failure. diff --git a/README.md b/README.md index 6480705..32287a7 100644 --- a/README.md +++ b/README.md @@ -11,13 +11,22 @@ with zero runtime dependencies. It bundles: - **Controlled Terminology (CT)**: all historical SDTM and ADaM CT releases from the [NCI EVS FTP site](https://evs.nci.nih.gov/ftp1/CDISC/), stored compactly using a validity-date design (one row per term-state, not one copy per release). + Current as of the 2026-09-25 NCI release. +- **Implementation-guide (IG) variable metadata**: SDTM Model and SDTMIG + variable tables (the Findings general-observation-class variables, the PP + domain, and the generic SUPP-- structure used for SUPPPP) and ADaMIG ADSL + and BDS variable tables (BDS covers ADPP, a BDS-structured dataset). See + `get_ig()` and `build_domain_spec()`. - **Define-XML XSD schemas**: for validating `define.xml` files (versions 2.0 and 2.1). - **XSLT stylesheets**: for rendering `define.xml` as HTML (versions 2.0 and 2.1). -All data are sourced exclusively from publicly available, license-free sources. -Data that require a CDISC Library API key (SDTM IG, ADaM IG) will be handled by -a separate `cdiscapi` package. +CT, Define-XML schemas, and XSLT stylesheets are sourced exclusively from +publicly available, license-free sources, with no CDISC Library API key +needed. IG variable metadata is sourced from CDISC's own published SDTM +Model/SDTMIG/ADaMIG specification tables (also without an API key) - see +[Data sources](#data-sources) below, which supersedes this package's +original plan to leave all IG metadata to a separate `cdiscapi` package. ## Installation @@ -65,6 +74,23 @@ The validity-date design means historical data is stored without duplication: each row carries a `valid_from` date and an `valid_to` date (`NA` = still current). `get_ct()` reconstructs the state of any release on the fly. +### Implementation-guide variable metadata + +``` r +# All SDTM Model + SDTMIG variable metadata (every source and version) +ig_sdtm <- get_ig("sdtm") + +# Just the SDTMIG PP domain +pp_ig <- get_ig("sdtm", version = "3.2") +pp_ig <- pp_ig[pp_ig$domain == "PP", ] + +# A ready-to-use variable spec (name, label, type, length, core, order, +# codelist id) for PP, SUPPPP, or ADPP, joined to CT for codelist ids +build_domain_spec("PP") +build_domain_spec("SUPPPP") +build_domain_spec("ADPP") +``` + ### Define-XML schemas and stylesheets ``` r @@ -98,7 +124,7 @@ packages (e.g. `cdisclib`, `defineauto`). Key design decisions: |----------|-----------| | Zero runtime dependencies | Easier deployment in locked/air-gapped environments; CRAN friendly | | Validity-date CT storage | Compact representation of all historical releases without row duplication | -| Public data only | No API key or license required to install or use the package | +| No CDISC Library API key required | CT, schemas, and stylesheets are public domain / open-source licensed; IG metadata is transcribed from CDISC's published specification documents (see Data sources) | | Per-release RDS cache in `data-raw/raw/` | Fast incremental rebuilds; preserves full audit trail | ## Data sources @@ -107,14 +133,16 @@ packages (e.g. `cdisclib`, `defineauto`). Key design decisions: |------|--------|---------| | SDTM CT | [NCI EVS FTP](https://evs.nci.nih.gov/ftp1/CDISC/SDTM/) | Public domain | | ADaM CT | [NCI EVS FTP](https://evs.nci.nih.gov/ftp1/CDISC/ADaM/) | Public domain | +| SDTM Model / SDTMIG / ADaMIG variable metadata | CDISC's published specification documents, transcribed via [Bill Denney's Rsdtm package](https://github.com/humanpred/Rsdtm) (private); see `data-raw/ig_source/README.md` for full provenance/attribution | CDISC published standards | | Define-XML 2.1 schema | [cdisc-org/DataExchange-RWD-Lineage](https://github.com/cdisc-org/DataExchange-RWD-Lineage) | Apache 2.0 | | Define-XML 2.0 schema | [dbosak01/defineR](https://github.com/dbosak01/defineR) | MIT | | XSLT stylesheets | [cdisc-org/data-definition-engine](https://github.com/cdisc-org/data-definition-engine) / [dbosak01/defineR](https://github.com/dbosak01/defineR) | Apache 2.0 / MIT | ## Related packages -- **`cdiscapi`** *(forthcoming)*: SDTM IG and ADaM IG metadata via the CDISC - Library API (requires API key). +- **`cdiscapi`** *(forthcoming)*: CDISC Library API access (requires API key) + for metadata not available from public sources - e.g. newer SDTMIG/ADaMIG + versions than `get_ig()` currently covers. - **`cdisclib`**: Core utilities built on top of `cdiscdata`. - **`defineauto`**: Automated Define-XML generation. diff --git a/data-raw/build_catalogue.R b/data-raw/build_catalogue.R index 585214a..e2513ef 100644 --- a/data-raw/build_catalogue.R +++ b/data-raw/build_catalogue.R @@ -1,6 +1,8 @@ # Rebuild the datasets_catalogue object after any data update. -# Called at the end of fetch_all.R. -# Requires ct_sdtm and ct_adam to be loaded in the environment. +# Called at the end of fetch_all.R (CT), and after build_ig_sdtm.R / +# build_ig_adam.R (IG metadata, which fetch_all.R does not touch). +# Requires ct_sdtm, ct_adam, ig_sdtm, and ig_adam to be loaded in the +# environment (e.g. via load("data/ct_sdtm.rda") or a prior build script). build_version_range <- function(x) { x <- sort(unique(x)) @@ -34,6 +36,40 @@ ct_entries <- data.frame( stringsAsFactors = FALSE ) +# ── IG entries ──────────────────────────────────────────────────────────────── +# ig_sdtm bundles two independently-versioned sources (SDTM Model, SDTMIG; +# see R/data.R), so its version range is reported per source rather than as +# one min/max across both numbering systems. +ig_sdtm_model_versions <- sort(unique(ig_sdtm$version[ig_sdtm$source == "SDTM_MODEL"])) +ig_sdtm_ig_versions <- sort(unique(ig_sdtm$version[ig_sdtm$source == "SDTMIG"])) +ig_adam_versions <- sort(unique(ig_adam$version)) + +ig_entries <- data.frame( + dataset = c("ig_sdtm", "ig_adam"), + type = c("IG", "IG"), + ct_type = NA_character_, + description = c( + "SDTM Model + SDTMIG variable metadata", + "ADaMIG ADSL + BDS variable metadata" + ), + versions = c( + sprintf("Model %s (SDTMIG %s)", + build_version_range(ig_sdtm_model_versions), + paste(ig_sdtm_ig_versions, collapse = ", ")), + build_version_range(ig_adam_versions) + ), + n_versions = c( + length(ig_sdtm_model_versions) + length(ig_sdtm_ig_versions), + length(ig_adam_versions) + ), + latest = c( + max(ig_sdtm_model_versions), + as.character(max(package_version(ig_adam_versions))) + ), + last_updated = Sys.Date(), + stringsAsFactors = FALSE +) + # ── Schema / stylesheet entries ─────────────────────────────────────────────── schema_dir <- "inst/extdata/schema" schema_dirs <- list.dirs(schema_dir, full.names = FALSE, recursive = FALSE) @@ -58,7 +94,7 @@ file_entries <- data.frame( ) # ── Combine and save ───────────────────────────────────────────────────────── -datasets_catalogue <- rbind(ct_entries, file_entries) +datasets_catalogue <- rbind(ct_entries, ig_entries, file_entries) usethis::use_data(datasets_catalogue, overwrite = TRUE, compress = "xz") message("datasets_catalogue saved.") diff --git a/data-raw/build_ig_adam.R b/data-raw/build_ig_adam.R new file mode 100644 index 0000000..13888dd --- /dev/null +++ b/data-raw/build_ig_adam.R @@ -0,0 +1,65 @@ +# Build the versioned `ig_adam` dataset: the ADaMIG ADSL (subject-level) +# variable table and the generic BDS (Basic Data Structure) variable table +# that ADPP, as a BDS-structured dataset, uses. +# +# Source: CSV transcriptions of CDISC's published ADaMIG specification +# tables, copied read-only from Bill Denney's Rsdtm package +# (github.com/humanpred/Rsdtm, private) into data-raw/ig_source/adamig_*/ so +# this build has no dependency on that package's checkout being present. See +# data-raw/ig_source/README.md for the full source/attribution note. +# +# Rsdtm splits each version's ADSL and BDS variables across several +# category files (e.g. ADSL_Dose_Variables.csv, Timing_Variables_BDS_Datasets.csv) +# rather than one file per dataset; every file in a version's directory +# whose name starts with "ADSL" is an ADSL category, everything else is a +# BDS category (true for all three transcribed versions: 1.0, 1.1, 1.2). + +source("data-raw/utils_ig.R") + +adamig_versions <- c("1.0", "1.1", "1.2") + +build_adamig_version <- function(version) { + dir <- file.path("data-raw/ig_source", paste0("adamig_", version)) + files <- sort(list.files(dir, pattern = "[.]csv$", full.names = FALSE)) + is_adsl <- startsWith(files, "ADSL") + + rows_for <- function(file, dataset) { + tbl <- read_ig_csv(file.path(dir, file)) + category <- tools::file_path_sans_ext(file) + data.frame( + dataset = dataset, + version = version, + category = category, + order = seq_len(nrow(tbl)), + variable = tbl$variable, + label = tbl$label, + type = tbl$type, + core = tbl$core, + codelist = parse_codelist_token(tbl$codelist), + length = parse_documented_length(tbl$notes), + notes = tbl$notes, + stringsAsFactors = FALSE + ) + } + + do.call(rbind, c( + Map(rows_for, files[is_adsl], "ADSL"), + Map(rows_for, files[!is_adsl], "BDS") + )) +} + +ig_adam <- do.call(rbind, lapply(adamig_versions, build_adamig_version)) +rownames(ig_adam) <- NULL + +stopifnot( + all(c("dataset", "version", "category", "order", "variable", "label", "type", + "core", "codelist", "length", "notes") %in% names(ig_adam)), + !anyNA(ig_adam$variable), !anyNA(ig_adam$version) +) + +usethis::use_data(ig_adam, overwrite = TRUE, compress = "xz") +message(sprintf( + "ig_adam saved: %d rows across %d versions (%d ADSL, %d BDS).", + nrow(ig_adam), length(adamig_versions), + sum(ig_adam$dataset == "ADSL"), sum(ig_adam$dataset == "BDS") +)) diff --git a/data-raw/build_ig_sdtm.R b/data-raw/build_ig_sdtm.R new file mode 100644 index 0000000..a4d3bae --- /dev/null +++ b/data-raw/build_ig_sdtm.R @@ -0,0 +1,93 @@ +# Build the versioned `ig_sdtm` dataset: SDTM Model class-level variables +# (Findings observation class) plus SDTMIG domain-specific variables (PP, +# and the generic SUPP-- qualifier structure used for SUPPPP). +# +# Source: CSV transcriptions of CDISC's published SDTM Model and SDTMIG +# specification tables, copied read-only from Bill Denney's Rsdtm package +# (github.com/humanpred/Rsdtm, private) into data-raw/ig_source/ so this +# build has no dependency on that package's checkout being present. See +# data-raw/ig_source/README.md for the full source/attribution note. +# +# Coverage is limited by what Rsdtm's data-raw/ happens to have transcribed: +# the SDTM Model is available for versions 1.4-1.7 (Findings class only, the +# class PP/SUPPPP need); the SDTMIG PP and Supplemental Qualifiers domain +# specifications are only transcribed for version 3.2 (Rsdtm's SDTMIG_3.3 +# copy covers a different, unrelated set of domains). Only version 3.2 is +# built here as a result; a newer SDTMIG's PP/SUPP-- tables can be added by +# copying the equivalent CSVs into data-raw/ig_source/sdtmig_/ and +# extending the `sdtmig_versions` loop below. + +source("data-raw/utils_ig.R") + +# ── SDTM Model: Findings observation class ───────────────────────────────── +model_versions <- c("1.4", "1.5", "1.6", "1.7") + +model_rows <- do.call(rbind, lapply(model_versions, function(v) { + path <- file.path("data-raw/ig_source/sdtm_model", v, "Findings_Observation_Class.csv") + tbl <- read_ig_csv(path) + # Rows with no Type are section sub-headings embedded in the source table + # ("Topic Variable", "Qualifier Variables", ...), not real variables. + tbl <- tbl[!is.na(tbl$type), ] + data.frame( + source = "SDTM_MODEL", + version = v, + class = "Findings", + domain = NA_character_, + order = seq_len(nrow(tbl)), + variable = tbl$variable, + label = tbl$label, + type = tbl$type, + role = tbl$role, + core = NA_character_, + codelist = NA_character_, + length = NA_integer_, + notes = tbl$notes, + stringsAsFactors = FALSE + ) +})) + +# ── SDTMIG: PP and Supplemental Qualifiers (SUPP--) ───────────────────────── +sdtmig_versions <- "3.2" + +build_sdtmig_domain <- function(version, domain, file) { + path <- file.path("data-raw/ig_source", paste0("sdtmig_", version), file) + tbl <- read_ig_csv(path) + data.frame( + source = "SDTMIG", + version = version, + class = NA_character_, + domain = domain, + order = seq_len(nrow(tbl)), + variable = tbl$variable, + label = tbl$label, + type = tbl$type, + role = tbl$role, + core = tbl$core, + codelist = parse_codelist_token(tbl$codelist), + length = parse_documented_length(tbl$notes), + notes = tbl$notes, + stringsAsFactors = FALSE + ) +} + +sdtmig_rows <- do.call(rbind, c( + lapply(sdtmig_versions, build_sdtmig_domain, + domain = "PP", file = "PP-specification.csv"), + lapply(sdtmig_versions, build_sdtmig_domain, + domain = "SUPPQUAL", file = "Supplemental_Qualifiers-specification.csv") +)) + +ig_sdtm <- rbind(model_rows, sdtmig_rows) +rownames(ig_sdtm) <- NULL + +stopifnot( + all(c("source", "version", "class", "domain", "order", "variable", "label", + "type", "role", "core", "codelist", "length", "notes") %in% names(ig_sdtm)), + !anyNA(ig_sdtm$variable), !anyNA(ig_sdtm$version) +) + +usethis::use_data(ig_sdtm, overwrite = TRUE, compress = "xz") +message(sprintf( + "ig_sdtm saved: %d rows (%d SDTM_MODEL, %d SDTMIG).", + nrow(ig_sdtm), sum(ig_sdtm$source == "SDTM_MODEL"), sum(ig_sdtm$source == "SDTMIG") +)) diff --git a/data-raw/fetch_all.R b/data-raw/fetch_all.R index 34bd1ed..54574c0 100644 --- a/data-raw/fetch_all.R +++ b/data-raw/fetch_all.R @@ -54,6 +54,11 @@ any_updated <- sdtm_updated || adam_updated || schema_updated || stylesheet_upda if (any_updated) { message("\n--- Rebuild datasets_catalogue ---") + # build_catalogue.R also reports on ig_sdtm/ig_adam (built separately by + # build_ig_sdtm.R / build_ig_adam.R, since they have no NCI network + # source); load the already-built copies rather than rebuilding them here. + load("data/ig_sdtm.rda") + load("data/ig_adam.rda") source("data-raw/build_catalogue.R") message("\n--- Change summary ---") diff --git a/data-raw/ig_source/README.md b/data-raw/ig_source/README.md new file mode 100644 index 0000000..b92d0e7 --- /dev/null +++ b/data-raw/ig_source/README.md @@ -0,0 +1,50 @@ +# IG source data: provenance and attribution + +The CSV files under this directory are transcriptions of tables published in +CDISC's own SDTM Model, SDTMIG, and ADaMIG specification documents +(https://www.cdisc.org/standards), copied **read-only** from +[Bill Denney's Rsdtm package](https://github.com/humanpred/Rsdtm) (private, +`data-raw/`), where they were originally transcribed for that package's own +use. They are reproduced here, with this attribution, as the implementation +guide variable metadata behind `ig_sdtm`, `ig_adam`, and `get_ig()`; built by +`data-raw/build_ig_sdtm.R` and `data-raw/build_ig_adam.R`. + +This differs from `cdiscdata`'s original design note that "Data that require +a CDISC Library API key (SDTM IG, ADaM IG) will be handled by a separate +`cdiscapi` package" (see the package README and `cran-comments.md`): no API +key is used here, only these public-source transcriptions, but the IG +metadata this enables is broader than the originally-scoped "public domain +only" CT/schema data. Flagged for Bill's review; the README has been updated +to describe this sourcing. + +## Coverage + +| Directory | Standard | Version(s) | Content | +|---|---|---|---| +| `sdtm_model/1.4` .. `1.7` | SDTM Model | 1.4, 1.5, 1.6, 1.7 | `Findings_Observation_Class.csv`: the Findings general-observation-class variables (PP and ADPP are Findings-class datasets) | +| `sdtmig_3.2` | SDTMIG | 3.2 | `PP-specification.csv` (the PP domain); `Supplemental_Qualifiers-specification.csv` (the generic SUPP-- structure used for SUPPPP) | +| `adamig_1.0`, `adamig_1.1`, `adamig_1.2` | ADaMIG | 1.0, 1.1, 1.2 | ADSL (subject-level) and BDS (Basic Data Structure, used by ADPP) variable tables, each split by Rsdtm into several category files (`ADSL_*` = ADSL, everything else = BDS) | + +**SDTMIG coverage is limited to version 3.2.** Rsdtm's `SDTMIG_3.3` copy +covers only CO, DM, SE, SM, and SV — not PP or Supplemental Qualifiers — so +no newer SDTMIG version's PP/SUPP-- tables could be sourced this way. A +newer version can be added later by copying the equivalent +`PP-specification.csv` / `Supplemental_Qualifiers-specification.csv` into a +new `sdtmig_/` directory here and extending the version list in +`data-raw/build_ig_sdtm.R`. + +## Encoding + +These files are Windows-1252 encoded (smart quotes, non-breaking spaces), +not UTF-8, as transcribed from Word/PDF source documents; `read_ig_csv()` in +`data-raw/utils_ig.R` reads them with `fileEncoding = "windows-1252"` +accordingly. + +## Length + +None of these source tables publish a variable Length column; CDISC +implementation guides do not fix one (length is a sponsor/define.xml +choice). `ig_sdtm$length` / `ig_adam$length` are `NA` except for the small +number of variables (PPTESTCD, PPTEST, ...) whose IG text explicitly states +a maximum character count, which `parse_documented_length()` recovers from +that text. diff --git a/data-raw/ig_source/adamig_1.0/ADSL-specification.csv b/data-raw/ig_source/adamig_1.0/ADSL-specification.csv new file mode 100644 index 0000000..d5875d0 --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/ADSL-specification.csv @@ -0,0 +1,139 @@ +Variable Name,Variable Label,Type,"Codelist / +Controlled Terms",Core,CDISC Notes +Study Identifiers,,,,, +STUDYID,Study Identifier,Char,,Req,"Must be identical to the SDTM variables DM.STUDYID, DM.USUBJID, DM.SUBJID and DM.SITEID." +USUBJID,"Unique Subject +Identifier",Char,,Req, +SUBJID,"Subject Identifier +for the Study",Char,,Req, +SITEID,"Study Site +Identifier",Char,,Req, +SITEGRy,Pooled Site Group y,Char,,Perm,"Character description of a grouping or pooling of clinical sites for analysis purposes. For example, SITEGR3 is the name of a variable containing site group (pooled site) names, +where the grouping has been done according to the third site grouping algorithm, defined in variable metadata; SITEGR3 does not mean the third group of sites." +SITEGRyN,Pooled Site Group y (N),Num,,Perm,The numeric code for SITEGRy. One-to-one map to SITEGRy. +Subject Demographics,,,,, +AGE,Age,Num,,Req,"The age of the subject is a required variable in ADSL. If the variable is not a copy of +DM.AGE, then an additional differently named variable must be added." +AGEU,Age Units,Char,(AGEU),Req,"The units for the subject’s age is a required variable in ADSL. If the variable is not a +copy of DM.AGEU, then an additional differently named variable must be added." +SEX,Sex,Char,(SEX),Req,"The sex of the subject is a required variable in ADSL. If the variable is not a copy of +DM.SEX, then an additional differently named variable must be added." +RACE,Race,Char,(RACE),Req,"The race of the subject is a required variable in ADSL. If the variable is not a copy of +DM.RACE, then an additional differently named variable must be added." +RACEGRy,"Pooled Race +Group y",Char,,Perm,Character description of a grouping or pooling of subject race for analysis purposes. +RACEGRyN,"Pooled Race +Group y (N)",Num,,Perm,"The numeric code for RACEGRy. Orders the grouping or pooling of subject race for +analysis and reporting. One-to-one map to RACEGRy." +Population Indicator(s),,,,, +FASFL,"Full Analysis Set +Population Flag",Char,"Y, N",Cond,"A character indicator variable is required for every population that is defined in the statistical analysis plan. A minimum of one subject-level population flag variable is required for every clinical trial. Additional population flags may be added. The values of subject-level population flags cannot be blank. If a flag is used, the corresponding numeric version (*FN) can also be included." +SAFFL,"Safety Population +Flag",Char,"Y, N",Cond, +ITTFL,"Intent-To-Treat +Population Flag",Char,"Y, N",Cond, +PPROTFL,"Per-Protocol +Population Flag",Char,"Y, N",Cond, +COMPLFL,"Completers +Population Flag",Char,"Y, N",Cond, +RANDFL,"Randomized +Population Flag",Char,"Y, N",Cond, +ENRLFL,"Enrolled +Population Flag",Char,"Y, N",Cond, +Treatment Variables,,,,, +ARM,"Description of +Planned Arm",Char,,Req,DM.ARM +TRTxxP,Planned Treatment for Period xx,Char,,Req,"Subject-level identifier that represents the planned treatment for period xx. In a one- period randomized trial, TRT01P would be the treatment to which the subject was randomized. TRTxxP might be derived from the SDTM DM variable ARM. At least +TRT01P is required." +TRTxxPN,"Planned Treatment for +Period xx (N)",Num,,Perm,The numeric code variable for TRTxxP. One-to-one map to TRTxxP. +TRTxxA,Actual Treatment for Period xx,Char,,Cond,"Subject-level identifier that represents the actual treatment for the subject for period xx. Required when actual treatment does not match planned and there is an analysis of the +data as treated." +TRTxxAN,Actual Treatment for Period xx (N),Num,,Perm,The numeric code variable for TRTxxA. One-to-one map to TRTxxA. +TRTSEQP,Planned Sequence of Treatments,Char,,Cond,"Required when there is a sequence of treatments that are analyzed, for example in a crossover design. TRTSEQP is not necessarily equal to ARM, for example if ARM contains elements that are not relevant to analysis of treatments or ARM is not fully +descriptive (e.g., “GROUP 1,” “GROUP 2”). Whenever applicable, TRTSEQP is required even if identical to ARM." +TRTSEQPN,Planned Sequence of Treatments (N),Num,,Perm,Numeric version of TRTSEQP. One-to-one map to TRTSEQP. +TRTSEQA,"Actual Sequence +of Treatments",Char,,Cond,"TRTSEQA is required if a situation occurred in the conduct of the trial where a subject +received a sequence of treatments other than what was planned." +TRTSEQAN,"Actual Sequence +of Treatments (N)",Num,,Perm,Numeric version of TRTSEQA. One-to-one map to TRTSEQA. +TRxxPGy,Planned Pooled Treatment y for Period xx,Char,,Perm,"Planned pooled treatment y for period xx. Useful when planned treatments (TRTxxP) in the specified period xx are pooled together for analysis according to pooling algorithm y. For example when in period 2 the first pooling algorithm dictates that all doses of Drug A (TR02PG1=“All doses of Drug A”) are pooled together for comparison to all doses of +Drug B (TR02PG1=“All doses of Drug B”). Each value of TRTxxP is pooled within at most one value of TRxxPGy." +TRxxPGyN,"Planned Pooled Trt y for Period +xx (N)",Char,,Perm,The numeric code for TRxxPGy. One-to-one map to TRxxPGy. +TRxxAGy,"Actual Pooled Treatment y for +Period xx",Char,,Cond,Actual pooled treatment y for period xx. Required when TRxxPGy is present and TRTxxA is present. +TRxxAGyN,"Actual Pooled Trt y for Period xx +(N)",Char,,Perm,The numeric code for TRxxAGy. One-to-one map to TRxxAGy. +Trial Dates,,,,, +RANDDT,"Date of +Randomization",Num,,Cond,Required in randomized trials +TRTSDT,"Date of First Exposure to +Treatment",Num,,Cond,Date of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. +TRTSTM,"Time of First Exposure to +Treatment",Num,,Perm,Time of first exposure to treatment for a subject in a study. +TRTSDTM,"Datetime of First Exposure to +Treatment",Num,,Cond,Datetime of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. +TRTSDTF,"Date of First +Exposure Imput. Flag",Char,(DATEFL),Cond,The level of imputation of date of first exposure to treatment. See General Timing Variable Convention #6. +TRTSTMF,"Time of First Exposure Imput. +Flag",Char,(TIMEFL),Cond,The level of imputation of time of first exposure to treatment. See General Timing Variable Convention #7. +TRTEDT,"Date of Last +Exposure to Treatment",Num,,Cond,Date of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. +TRTETM,"Time of Last +Exposure to Treatment",Num,,Perm,Time of last exposure to treatment for a subject in a study. +TRTEDTM,"Datetime of Last +Exposure to Treatment",Num,,Cond,Datetime of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. +TRTEDTF,"Date of Last Exposure Imput. +Flag",Char,(DATEFL),Cond,The level of imputation of date of last exposure to treatment. See General Timing Variable Convention #6. +TRTETMF,"Time of Last +Exposure Imput. Flag",Char,(TIMEFL),Cond,The level of imputation of time of last exposure to treatment. See General Timing Variable Convention #7. +TRxxSDT,Date of First Exposure in Period xx,Num,,Cond,"Date of first exposure to treatment in period xx. TRxxSDT and/or TRxxSDTM is required in trial designs where multiple treatments are given to the same subject, such as +a crossover design. Also useful in designs where multiple periods exist for the same treatment (i.e., multiple cycles of the same study treatment)." +TRxxSTM,"Time of First Exposure in +Period xx",Num,,Cond,"The starting time of exposure in period xx. TRxxSTM and/or TRxxSDTM are required in trial designs where multiple treatments are given to the same subject, such as a +crossover design, and time is important to the analysis." +TRxxSDTM,"Datetime of First Exposure in +Period xx",Num,,Cond,"Datetime of first exposure to treatment in period xx. TRxxSDT and/or TRxxSDTM are required in trial designs where multiple treatments are given to the same subject, such as +a crossover design." +TRxxSDTF,"Date 1st Exposure Period xx Imput. +Flag",Char,(DATEFL),Cond,The level of imputation of date of first exposure to treatment in period xx. See General Timing Variable Convention #6. +TRxxSTMF,"Time 1st +Exposure Period xx Imput. Flag",Char,(TIMEFL),Cond,The level of imputation of time of first exposure in period xx. See General Timing Variable Convention #7. +TRxxEDT,"Date of Last Exposure in +Period xx",Num,,Cond,"Date of last exposure in period xx. TRxxEDT and/or TRxxEDTM are required in trial designs where multiple treatments are given to the same subject, such as a crossover +design." +TRxxETM,"Time of Last +Exposure in Period xx",Num,,Cond,"The ending time of exposure in period xx. TRxxETM and/or TRxxEDTM are required +in trial designs where multiple treatments are given to the same subject, such as a crossover design, and ending time is important to the analysis." +TRxxEDTM,"Datetime of Last +Exposure in Period xx",Num,,Cond,"The datetime of last exposure to treatment in period xx. TRxxEDT and/or TRxxEDTM +are required in trial designs where multiple treatments are given to the same subject, such as a crossover design." +TRxxEDTF,"Date Last +Exposure Period xx Imput. Flag",Char,(DATEFL),Cond,The level of imputation of date of last exposure in period xx. See General Timing Variable Convention #6. +TRxxETMF,"Time Last Exposure Period +xx Imput. Flag",Char,(TIMEFL),Cond,The level of imputation of time of last exposure in period xx. See General Timing Variable Convention #7. +APxxSDT,"Period xx Start +Date",Num,,Perm,The starting date of period xx. +APxxSTM,Period xx Start Time,Num,,Perm,The starting time of period xx. +APxxSDTM,"Period xx Start +Datetime",Num,,Perm,The starting datetime of period xx. +APxxSDTF,"Period xx Start +Date Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of period xx start date. See General Timing Variable Convention +#6." +APxxSTMF,"Period xx Start +Time Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of period xx start time. See General Timing Variable Convention +#7." +APxxEDT,"Period xx End +Date",Num,,Perm,The ending date of period xx. +APxxETM,"Period xx End +Time",Num,,Perm,The ending time of period xx. +APxxEDTM,"Period xx End +Date/Time",Num,,Perm,The ending datetime of period xx. +APxxEDTF,"Period xx End +Date Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of period xx end date. See General Timing Variable Convention +#6." +APxxETMF,"Period End Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of period xx end time. See General Timing Variable Convention +#7." diff --git a/data-raw/ig_source/adamig_1.0/Analysis_Descriptor_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Analysis_Descriptor_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..f8bcc5d --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Analysis_Descriptor_Variables_BDS_Datasets.csv @@ -0,0 +1,42 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +DTYPE,Derivation Type,Char,(DTYPE),Cond,"Analysis value derivation method. DTYPE is used to denote, and is required to be populated, when the value of AVAL or AVALC (and thus the entire record) has been imputed, derived, or copied from other record(s). DTYPE is required to be populated even if AVAL and AVALC are null on the derived record. DTYPE is not used to denote that an analysis parameter is derived. PARAMTYP may be used to indicate that an entire parameter is derived. For each value of DTYPE, the precise derivation algorithm must be defined in analysis variable metadata, even for DTYPE values in the controlled terminology. See Section 4 for examples of the use of DTYPE. +Examples of DTYPE values +LOCF = last observation carried forward. WOCF = worst observation carried forward. +AVERAGE = average of values." +AWRANGE,"Analysis Window Valid Relative +Range",Char,,Perm,"The range of values that are valid for a given analysis timepoint (a given value of AVISIT). For example, “5-9 DAYS”." +AWTARGET,Analysis Window Target,Num,,Perm,The target or most desired analysis relative day (ADY) value or analysis relative time (ARELTM) value for a given value of AVISIT. +AWTDIFF,Analysis Window Diff from Target,Num,,Perm,"Absolute difference between ADY or ARELTM and AWTARGET. It will be necessary to adjust for the fact that there is no day 0 in the event that ADY and AWTARGET are not of the same sign. +If the sign of the difference is important, then AWTDIFF might have to be used in +conjunction with ADY or ARELTM and possibly AWTARGET when choosing among records." +AWLO,"Analysis Window Beginning +Timepoint",Num,,Perm,"The value of the beginning timepoint (inclusive) needs to be used in conjunction to AWRANGE. For example, if AWRANGE is“5-9 DAYS”, then AWLO is “5”." +AWHI,"Analysis Window +Ending Timepoint",Num,,Perm,"The value of the ending timepoint (inclusive) needs to be used in conjunction to +AWRANGE. For example, if AWRANGE is“5-9 DAYS”, then AWHI is “9”." +AWU,"Analysis Window +Unit",Char,,Perm,"Unit used for AWLO and AWHI. Examples: DAYS, HOURS." +STARTDT,Time to Event Origin Date for Subject,Num,,Perm,"The original date of risk for the time-to-event analysis. This is generally the time at which a subject is first at risk of the event of interest (as defined in the protocol or +Statistical Analysis Plan). For example, this may be the randomization date or the date of first study therapy exposure." +CNSR,Censor,Num,,Cond,"Defines whether the event was censored (period of observation truncated prior to event being observed). It is strongly recommended to use 0 as an event indicator and positive integers as censoring indicators. It is also recommended that unique positive integers be +used to indicate coded descriptions of censoring reasons. CNSR is required for time-to- event parameters." +EVNTDESC,"Event or Censoring +Description",Char,,Perm,Description of the event of interest or censoring reason. +ATOXGR,"Analysis Toxicity +Grade",Char,,Perm,"Toxicity grade for analysis; may be based on SDTM --TOXGR or an imputed or +assigned value." +BTOXGR,"Baseline Toxicity +Grade",Char,,Perm,ATOXGR of the baseline record identified by ABLFL. +ANRIND,"Analysis Reference Range +Indicator",Char,,Perm,Normal range indicator for analysis; may be based on SDTM --NRIND or an imputed or assigned value. +BNRIND,"Baseline Reference Range +Indicator",Char,,Perm,ANRIND of the baseline record identified by ABLFL. +ANRLO,"Analysis Normal +Range Lower Limit",Char,,Perm,Normal range lower limit for analysis; may be based on SDTM --NRLO or an imputed or assigned value. +ANRHI,"Analysis Normal Range Upper +Limit",Char,,Perm,Normal range upper limit for analysis; may be based on SDTM --NRHI or an imputed or assigned value. +AyLO,Analysis Range y Lower Limit,Char,,Cond,"AyLO and/or AyHI are used where there are multiple ranges used for analysis. AyLO and/or AyHI are created to capture the different levels of cutoff values used to determine whether an analysis is within a clinically acceptable value range or outside that value range. AyLO and/or AyHI are usually but not necessarily constants, parameter-specific +constants, or subject-specific constants. AyLO must be included if R2AyLO is included in the dataset." +AyHI,Analysis Range y Upper Limit,Char,,Cond,"See AyLO. +For example, if ECG QTc values are summarized based on values 450, values >480, and values >500, there is a need for 3 “hi value” range variables to calculate values against: A1HI=450, A2HI=480, A3HI=500. +AyHI must be included if R2AyHI is included in the dataset." diff --git a/data-raw/ig_source/adamig_1.0/Analysis_Parameter_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Analysis_Parameter_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..d83ea29 --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Analysis_Parameter_Variables_BDS_Datasets.csv @@ -0,0 +1,47 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +PARAM,Parameter,Char,,Req,"The description of the analysis parameter. Examples include: “Supine Systolic Blood Pressure (mm Hg)”, “Log10 (Weight (kg))”, “Time to First Hypertension Event (Days)”, “Estimated Tumor Growth Rate”, etc. PARAM should be sufficient to describe unambiguously the contents of AVAL and/or AVALC. PARAM must include test, units (if appropriate), specimen type, location, position, and any other applicable qualifying information needed, any additional information such as transformation function, and indeed any text that is needed. PARAM may be longer than 40 characters in length. +PARAM is often directly usable in Clinical Study Report displays. Note that in the ADaMIG, “parameter” is a synonym of “analysis parameter.”" +PARAMCD,Parameter Code,Char,,Req,"The short name of the analysis parameter in PARAM. Values of PARAMCD should follow SAS 5 variable naming conventions (8 characters or less; starts with a letter; contains only letters and digits). There must be a one-to-one mapping with PARAM. +Examples: SYSBP, LWEIGHT, HYPEREVT." +PARAMN,Parameter (N),Num,,Perm,"Useful for ordering and programmatic manipulation. There must be a one-to-one +mapping with PARAM. Must be an integer." +PARAMTYP,Parameter Type,Char,(PARAMTY P),Perm,"Indicator of whether the parameter is derived as a function of one or more other +parameters. This should not be confused with DTYPE which is relevant to derived AVAL and/or AVALC values." +PARCATy,Parameter Category y,Char,,Perm,"A categorization of PARAM. For example, value of PARCAT1 might group the parameters having to do with a particular questionnaire, lab specimen type, or area of +investigation." +PARCATyN,"Parameter +Category y (N)",Num,,Perm,"A numeric representation of PARCATy. This can be used for operations on PARCATy. +There should be a one to one relationship between PARCATy and PARCATyN." +AVAL,Analysis Value,Num,,"Req (at +least one)",Numeric analysis value described by PARAM. +AVALC,Analysis Value (C),Char,,,"Character analysis value described by PARAM. AVALC can be a character string +mapping to AVAL, but if so there must be a one-to-one map between AVAL and AVALC within a given PARAM. AVALC should not be used to categorize the values of AVAL." +AVALCATy,Analysis Category y,Char,,Perm,"A categorical representation of AVAL and/or AVALC. Not necessarily a one-to-one mapping to AVAL and/or AVALC. For example, if PARAM is “Headache Severity” and AVAL has values 0, 1, 2, or 3, AVALCAT1 can categorize AVAL into “None or Mild” +(for AVAL 1 or 2) and “Moderate or Severe” (for AVAL 3 or 4)" +BASE,Baseline Value,Num,,Cond,"Baseline analysis value. Required if dataset supports analysis or review of baseline value or functions of baseline value. A baseline record may be derived (e.g., it may be an average) in which case DTYPE must also be populated. If BASE is populated for a parameter, and BASE is non-null for a subject for that parameter, then there must be a +record flagged by ABLFL for that subject and parameter." +BASEC,Baseline Value (C),Char,,Perm,"Baseline value of AVALC. May be needed when AVALC is of interest. There must be a one-to-one map between BASE and BASEC within a given PARAM if both are +populated. The baseline record for AVALC must be the same as that for AVAL." +BASECATy,Baseline Category y,Char,,Perm,"A categorical representation of BASE. Not necessarily a one-to-one map to BASE. For example, if PARAM is “Headache Severity” and AVAL has values 0, 1, 2, or 3, BASECAT1 can categorize BASE into “None or Mild” (for BASE 1 or 2) and +“Moderate or Severe” (for BASE 3 or 4)" +BASETYPE,Baseline Type,Char,,Cond,"Sponsor-defined text describing the definition of baseline relevant to the value of BASE on the current record. Required when there are multiple ways that baseline is defined. If +used for a given PARAM, should be populated for all records of that PARAM. Refer to Section 4.2.1, Rule 6, for an example." +CHG,Change from Baseline,Num,,Perm,"Change from baseline analysis value. Equal to AVAL-BASE. If used for a given PARAM, should be populated for all post-baseline records of that PARAM. The +decision on how to populate pre-baseline and baseline values of CHG are left to sponsor choice." +CHGCATy,Change from Baseline Category y,Char,,Perm,"A categorical representation of CHG. Not necessarily a one-to-one mapping to CHG. The definition of CHGCATy may vary by PARAM. For example, CHGCAT1 may be +used to categorize CHG with respect to ranges of change in SYSBP; “-10 to -5 mm Hg”, “-5 to 0 mm Hg” categories." +PCHG,Percent Change from Baseline,Num,,Perm,"Percent change from baseline analysis value. Equal to ((AVAL-BASE)/BASE)*100. If used for a given PARAM, should be populated (when calculable) for all records of that PARAM. The decision on how to populate pre-baseline and baseline values of PCHG +are left to sponsor choice." +PCHGCATy,Percent Change from Baseline y,Char,,Perm,"A categorical representation of PCHG. Not necessarily a one-to-one mapping to PCHG. The definition of PCHGCATy may vary by PARAM. For example, PCHGCAT1 may be +used to categorize PCHG with respect to ranges of change in SYSBP; “>5%”, “>10%” categories." +R2BASE,Ratio to Baseline,Num,,Perm,AVAL / BASE +R2AyLO,"Ratio to Analysis Range y Lower +Limit",Num,,Perm,AVAL / AyLO. AyLO must exist in the analysis dataset. +R2AyHI,"Ratio to Analysis Range y Upper +Limit",Num,,Perm,AVAL / AyHI. AyHI must exist in the analysis dataset. +SHIFTy,Shift y,Char,,Perm,"A shift in values depending on the defined pairing for group “y”. SHIFTy can be based on the change in value of any of the following pairs (BASECATy, AVALCATy), (BNRIND, ANRIND), (BTOXGR, ATOXGR), (BASE, AVAL) or (BASEC, AVALC). +Useful for shift tables. For example, “NORMAL to HIGH”. The decision on how to populate baseline and pre-baseline values of SHIFTy are left to sponsor choice." +SHIFTyN,Shift y (N),Num,,Perm,"Numeric version of SHIFT. SHIFTN has a one-to-one mapping relationship with SHIFT. The decision on how to populate baseline and pre-baseline values of SHIFTN are left to +sponsor choice." +CRITy,Analysis Criterion y,Char,,Perm,"A text string identifying a pre-specified criterion, for example SYSBP > 90. In some cases, the presence of the text string indicates that the criterion is satisfied on this record, while a null value indicates that the criterion is not satisfied. In other cases, the text string identifies the criterion being evaluated, but whether or not the criterion is satisfied is indicated by the value of the variable CRITyFL. See CRITyFL and CRITyFN in +Section 3.2.6. Refer to Section 4.7 for additional discussion of CRITy, CRITyFL and CRITyFN." diff --git a/data-raw/ig_source/adamig_1.0/Data_Point_Traceability_Variables.csv b/data-raw/ig_source/adamig_1.0/Data_Point_Traceability_Variables.csv new file mode 100644 index 0000000..d35400f --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Data_Point_Traceability_Variables.csv @@ -0,0 +1,7 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +SRCDOM,Source Domain,Char,,Perm,The 2-character identifier of the SDTM domain that relates to AVAL or AVALC. +SRCVAR,Source Variable,Char,,Perm,"The name of the column (in the SDTM domain identified by SRCDOM) that relates to +AVAL or AVALC." +SRCSEQ,"Source Sequence +Number",Num,,Perm,"The sequence number SEQ of the row (in the SDTM domain identified by SRCDOM) +that relates to AVAL or AVALC." diff --git a/data-raw/ig_source/adamig_1.0/Indicator_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Indicator_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..992d9dd --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Indicator_Variables_BDS_Datasets.csv @@ -0,0 +1,63 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +ABLFL,Baseline Record Flag,Char,Y,Cond,"Character indicator to identify the baseline record for each parameter, or if there is more than one baseline definition, for each parameter and baseline type (BASETYPE). See BASETYPE in Table 3.2.4.1. ABLFL is required if BASE is present in the dataset. +A baseline record may be derived (e.g., it may be an average), in which case DTYPE must also be populated. If BASE is populated for a parameter, and BASE is non-null for +a subject for that parameter, then there must be a record flagged by ABLFL for that subject and parameter." +ABLFN,Baseline Record Flag (N),Num,1,Perm,"Numeric indicator to identify the baseline record for each parameter, or if there is more than one baseline definition, for each parameter and baseline type (BASETYPE)." +ANLzzFL,Analysis Record Flag zz,Char,Y,Cond,"ANLzzFL is a conditionally required flag to be used in addition to other selection variables when the other selection variables in combination are insufficient to identify the exact set of records used for one or more analyses. Often one ANLzzFL will serve to support the accurate selection of records for more than one analysis. +When one is defining the set of records used in a particular analysis or family of analyses, ANLzzFL is supplemental to, and is intended to be used in conjunction with, other selection variables, such as subject-level, parameter-level and record-level population flags, AVISIT, DTYPE, grouping variables such as SITEGRy, and others. Every record selection algorithm “zz” (i.e., every algorithm for populating an ANLzzFL) must be defined in variable metadata. When the set of records that the algorithm “zz” operates on is pre-filtered by application of other criteria, such as a record-level population flag, then the selection algorithm definition in the metadata must so specify. Note that the ANLzzFL value of Y indicates that the record fulfilled the requirements of the algorithm, but does not necessarily imply that the record was actually used in one or more analyses, as whether or not a record is used also depends on the other selection variables applied. The ANLzzFL flag is useful in many circumstances; an example is when there is more than one record for an analysis timepoint within a subject and parameter, as it can be used to identify the record chosen to represent the timepoint for an analysis. “zz” is an index for a record selection algorithm, such as “record closest to target relative day for the AVISIT, with ties broken by the latest record, for each AVISIT +within .”" +ANLzzFN,"Analyzed Record +Flag zz (N)",Num,1,Perm,Numeric version of ANLzzFL. +ONTRTFL,On Treatment Record Flag,Char,Y,Perm,Character indicator of whether the observation occurred while the subject was on treatment. +ONTRTFN,On Treatment Record Flag (N),Num,1,Perm,Numeric indicator of whether the observation occurred while the subject was on treatment. +LVOTFL,"Last Value On +Treatment Record Flag",Char,Y,Perm,Character indicator of the last non-missing value on treatment for each parameter. +LVOTFN,"Last Value On +Treatment Record Flag (N)",Num,1,Perm,Numeric indicator of the last non-missing value on treatment for each parameter. +ITTRFL,"Intent-To-Treat Record-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the intent-to-treat analysis for the specific record. +ITTRFN,"Intent-To-Treat +Record-Level Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the intent-to-treat analysis for the specific record. +ITTPFL,"Intent-To-Treat +Parameter-Level Flag",Char,Y,Cond,Character indicator of whether the subject was in the intent-to-treat analysis for the specific parameter. +ITTPFN,"Intent-To-Treat Param-Level Flag +(N)",Num,1,Perm,Numeric indicator of whether the subject was in the intent-to-treat analysis for the specific parameter. +SAFRFL,"Safety Analysis Record-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the safety analysis for the specific record. +SAFRFN,"Safety Analysis Record-Level +Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the safety analysis for the specific record. +SAFPFL,"Safety Analysis Parameter-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the safety analysis for the specific parameter. +SAFPFN,"Safety Analysis Param-Level Flag +(N)",Num,1,Perm,Numeric indicator of whether the subject was in the safety analysis for the specific parameter. +FASRFL,"Full Analysis Set +Record-Level Flag",Char,Y,Cond,Character indicator of whether the subject was in the full analysis set analysis for the specific record. +FASRFN,"Full Analysis Set Record-Level +Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the full analysis set analysis for the specific record. +FASPFL,"Full Analysis Set Parameter-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the full analysis set analysis for the specific parameter. +FASPFN,"Full Analysis Set Param-Level Flag +(N)",Num,1,Perm,Numeric indicator of whether the subject was in the full analysis set analysis for the specific parameter. +PPROTRFL,"Per-Protocol Record-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the per-protocol analysis for the specific record. +PPROTRFN,"Per-Protocol Record-Level +Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the per-protocol analysis for the specific record. +PPROTPFL,"Per-Protocol +Parameter-Level Flag",Char,Y,Cond,Character indicator of whether the subject was in the per-protocol analysis for the specific parameter. +PPROTPFN,"Per-Protocol +Parameter-Level Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the per-protocol analysis for the specific parameter. +COMPRFL,"Completers Record-Level +Flag",Char,Y,Cond,Character indicator of whether the subject was in the completed subjects analysis for the specific record. +COMPRFN,"Completers +Record-Level Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the completed subjects analysis for the specific record. +COMPPFL,"Completers +Parameter-Level Flag",Char,Y,Cond,Character indicator of whether the subject was in the completed subjects analysis for the specific parameter. +COMPPFN,"Completers +Parameter-Level Flag (N)",Num,1,Perm,Numeric indicator of whether the subject was in the completed subjects analysis for the specific parameter. +CRITyFL,"Criterion y Evaluation Result +Flag",Char,"Y +or Y, N",Cond,"Character indicator of whether the criterion defined in CRITy was met. See also CRITy in Section 3.2.4. Required if CRITy exists. Refer to Section 4.7 for additional +discussion." +CRITyFN,"Criterion y Evaluation Result +Flag (N)",Num,"1 +or 1, 0",Perm,Numeric indicator of whether the criterion defined in CRITy was met. diff --git a/data-raw/ig_source/adamig_1.0/Subject_Identifier_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Subject_Identifier_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..eea90a2 --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Subject_Identifier_Variables_BDS_Datasets.csv @@ -0,0 +1,8 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +STUDYID,Study Identifier,Char,,Req,SDTM DM.STUDYID +USUBJID,"Unique Subject +Identifier",Char,,Req,SDTM DM.USUBJID +SUBJID,"Subject Identifier +for the Study",Char,,Perm,"SDTM DM.SUBJID. SUBJID is required in ADSL, but permissible in other datasets." +SITEID,"Study Site +Identifier",Char,,Perm,"SDTM DM.SITEID. SITEID is required in ADSL, but permissible in other datasets." diff --git a/data-raw/ig_source/adamig_1.0/Timing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Timing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..0d0d229 --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Timing_Variables_BDS_Datasets.csv @@ -0,0 +1,113 @@ +Variable Name,Variable Label,Type,Codelist / Controlled Terms,Core,CDISC Notes +ADT,Analysis Date,Num,,Perm,The date associated with AVAL and/or AVALC in numeric format. +ATM,Analysis Time,Num,,Perm,The time associated with AVAL and/or AVALC in numeric format. +ADTM,"Analysis +Date/Time",Num,,Perm,The date/time associated with AVAL and/or AVALC in numeric format. +ADY,Analysis Relative Day,Num,,Perm,"The relative day of AVAL and/or AVALC. The number of days from a reference date (not necessarily DM.RFSTDTC) to ADT. The reference date should be indicated in the +variable-level metadata for ADY and the reference date should be included as a variable in the given analysis dataset or alternatively in ADSL." +ADTF,"Analysis Date +Imputation Flag",Char,(DATEFL),Cond,"The level of imputation of ADT based on the source SDTM DTC variable. See General +Timing Variable Convention #6." +ATMF,"Analysis Time +Imputation Flag",Char,(TIMEFL),Cond,"The level of imputation of ATM based on the source SDTM DTC variable. See General +Timing Variable Convention #7." +ASTDT,Analysis Start Date,Num,,Perm,"The start date associated with AVAL and/or AVALC. ASTDT and AENDT may be useful for traceability when AVAL summarizes data collected over an interval of time, or when +AVAL is a duration." +ASTTM,Analysis Start Time,Num,,Perm,"The start time associated with AVAL and/or AVALC. ASTTM and AENTM may be useful for traceability when AVAL summarizes data collected over an interval of time, or +when AVAL is a duration." +ASTDTM,Analysis Start Date/Time,Num,,Perm,"The start datetime associated with AVAL and/or AVALC. ASTDTM and AENDTM may be useful for traceability when AVAL summarizes data collected over an interval of time, +or when AVAL is a duration." +ASTDY,Analysis Start Relative Day,Num,,Perm,"The number of days from a reference date (not necessarily DM.RFSTDTC) to ASTDT. The reference date variable should be indicated in the variable-level metadata for +ASTDY and the reference date variable should be included as a variable in an analysis dataset (typically, but not necessarily, ADSL)." +ASTDTF,"Analysis Start +Date Imputation Flag",Char,(DATEFL),Cond,The level of imputation of ASTDT based on the source SDTM DTC variable. See General Timing Variable Convention #6. +ASTTMF,"Analysis Start +Time Imputation Flag",Char,(TIMEFL),Cond,The level of imputation of ASTTM based on the source SDTM DTC variable. See General Timing Variable Convention #7. +AENDT,Analysis End Date,Num,,Perm,The end date associated with AVAL and/or AVALC. See also ASTDT. +AENTM,"Analysis End +Time",Num,,Perm,The end time associated with AVAL and/or AVALC. See also ASTTM. +AENDTM,"Analysis End +Date/Time",Num,,Perm,The end datetime associated with AVAL and/or AVALC. See also ASTDTM. +AENDY,"Analysis End +Relative Day",Num,,Perm,"The number of days from a reference date (not necessarily DM.RFSTDTC) to AENDT. +See also ASTDY." +AENDTF,"Analysis End Date Imputation +Flag",Char,(DATEFL),Cond,The level of imputation of AENDT based on the source SDTM DTC variable. See General Timing Variable Convention #6. +AENTMF,"Analysis End Time Imputation +Flag",Char,(TIMEFL),Cond,The level of imputation of AENTM based on the source SDTM DTC variable. See General Timing Variable Convention #7. +AVISIT,Analysis Visit,Char,,Cond,"AVISIT may contain the visit names as observe d (i.e., from SDTM VISIT), derived visit names, time window names, conceptual descriptions (such as Average, Endpoint, etc.), or a combination of any of these. AVISIT is a derived field and does not have to map to VISIT from the SDTM. AVISIT represents the analysis visit of the record, but it does not mean that the record was analyzed. There are often multiple records for the same subject and parameter that have the same value of AVISIT. ANLzzFL and other variables may be needed to identify the records selected for any given analysis. See Section 3.2.6 for metadata about flag variables. AVISIT should be unique for a given analysis visit window. In the event that a record does not fall within any predefined analysis timepoint window, AVISIT can be populated in any way that the sponsor chooses to indicate this fact (i.e., blank or “Not Windowed”). The way that AVISIT is calculated, including the variables used in its derivation, should be indicated in the variable metadata for AVISIT. The values and the rules for deriving AVISIT may be different for different parameters +within the same dataset. Values of AVISIT are sponsor-defined, and are often directly usable in Clinical Study Report displays." +AVISITN,Analysis Visit (N),Num,,Perm,"A numeric representation of AVISIT. This may be a protocol visit number, a week or cycle number, an analysis visit number, or any other number logically related to AVISIT or useful for sorting that is needed for analysis. Within a parameter, there is a one-to-one mapping between AVISITN and AVISIT so that AVISITN has the same value for each distinct AVISIT. In the event that a record does not fall within any predefined analysis +timepoint window, AVISITN can be populated in any way that the sponsor chooses to indicate this fact (e.g., may be null). Values of AVISITN are sponsor-defined." +ATPT,Analysis Timepoint,Char,,Perm,"The analysis time point description which is required if analysis times are derived. Timepoints are relative to ATPTREF. +ATPT can be within an analysis visit (e.g., blood pressure assessments at 10 min, 20 min, and 30 min post-dose at AVISIT=Week 1) or can be unrelated to AVISIT (e.g., migraine symptoms 30 min, 60 min, and 120 min post-dose for attack 1)." +ATPTN,"Analysis +Timepoint (N)",Num,,Perm,"ATPTN provides a numeric representation of ATPT. Within the same parameter, there is +a one-to-one mapping between ATPT and ATPTN." +ATPTREF,"Analysis Timepoint +Reference",Char,,Perm,Description of the fixed reference point referred to by ATPT/ATPTN. +APERIOD,Period,Num,,Perm,"The numeric value characterizing the period to which the record belongs. The value of APERIOD must be consistent with the xx value in TRTxxP, TRTxxA, and all variables +whose names begin with TRxx and APxx." +APERIODC,Period (C),Char,,Perm,Text characterizing to which period the record belongs. One-to-one map to APERIOD. +APHASE,Phase,Char,,Perm,"Generally, a higher-level categorization of APERIOD. Does not replace APERIOD, +because APERIOD provides the indexing for the TRxx and APxx variables." +ARELTM,Analysis Relative Time,Num,,Perm,"The time relative to an anchor time. When ARELTM is present, the anchor time variable +and ARELTMU must also be included in the dataset, and the anchor time variable must be identified in the metadata for ARELTM." +ARELTMU,"Analysis Relative +Time Unit",Char,,Cond,"The units of ARELTM. For example, “HOURS” or “MINUTES.” ARELTMU is +required if ARELTM is present." +APERSDT,Period Start Date,Num,,Perm,The starting date for the period defined by APERIOD. +APERSTM,Period Start Time,Num,,Perm,The starting time for the period defined by APERIOD. +APERSDTM,"Period Start +Date/Time",Num,,Perm,The starting datetime for the period defined by APERIOD. +APERSDTF,"Period Start Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of APERSDT based on the source SDTM DTC variable. See +General Timing Variable Convention #6." +APERSTMF,"Period Start Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of APERSTM based on the source SDTM DTC variable. See +General Timing Variable Convention #7." +APEREDT,Period End Date,Num,,Perm,The ending date for the period defined by APERIOD. +APERETM,Period End Time,Num,,Perm,The ending time for the period defined by APERIOD. +APEREDTM,"Period End +Date/Time",Num,,Perm,The ending datetime for the period defined by APERIOD. +APEREDTF,"Period End Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of APEREDT based on the source SDTM DTC variable. See +General Timing Variable Convention #6." +APERETMF,"Period End Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of APERETM based on the source SDTM DTC variable. See +General Timing Variable Convention #7." +*DT,Date of …,Num,,Perm,Analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*TM,Time of …,Num,,Perm,Analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*DTM,Date/Time of …,Num,,Perm,Analysis date/time not directly characterizing AVAL and/or AVALC in numeric format. +*ADY,"Relative Day of +…",Num,,Perm,Analysis relative day not directly characterizing AVAL and/or AVALC. +*DTF,"Date Imputation +Qual of …",Char,(DATEFL),Cond,"The level of imputation of *DT based on the source SDTM DTC variable. See General +Timing Variable Convention #6." +*TMF,"Time Imputation +Flag of …",Char,(TIMEFL),Cond,"The level of imputation of *TM based on the source SDTM DTC variable. See General +Timing Variable Convention #7." +*SDT,Start Date of …,Num,,Perm,"Starting analysis date not directly characterizing AVAL and/or AVALC in numeric +format." +*STM,Start Time of …,Num,,Perm,"Starting analysis time not directly characterizing AVAL and/or AVALC in numeric +format." +*SDTM,"Start Date/Time +of …",Num,,Perm,"Starting analysis date/time not directly characterizing AVAL and/or AVALC in numeric +format." +*SDY,"Relative Start Day +of …",Num,,Perm,Starting analysis relative day not directly characterizing AVAL and/or AVALC. +*SDTF,"Start Date +Imputation Flag of …",Char,(DATEFL),Cond,The level of imputation of *SDT based on the source SDTM DTC variable. See General Timing Variable Convention #6. +*STMF,"Start Time Imputation Qual +of …",Char,(TIMEFL),Cond,The level of imputation of *STM based on the source SDTM DTC variable. See General Timing Variable Convention #7. +*EDT,End Date of …,Num,,Perm,Ending analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*ETM,End Time of …,Num,,Perm,Ending analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*EDTM,"End Date/Time of +…",Num,,Perm,"Ending analysis date/time not directly characterizing AVAL and/or AVALC in numeric +format." +*EDY,"Relative End Day +of …",Num,,Perm,Ending analysis relative day not directly characterizing AVAL and/or AVALC. +*EDTF,"End Date Imputation Flag +of …",Char,(DATEFL),Cond,The level of imputation of *EDT based on the source SDTM DTC variable. See General Timing Variable Convention #6. +*ETMF,"End Time Imputation Flag +of …",Char,(TIMEFL),Cond,The level of imputation of *ETM based on the source SDTM DTC variable. See General Timing Variable Convention #7. diff --git a/data-raw/ig_source/adamig_1.0/Treatment_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.0/Treatment_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..74d3703 --- /dev/null +++ b/data-raw/ig_source/adamig_1.0/Treatment_Variables_BDS_Datasets.csv @@ -0,0 +1,17 @@ +Variable Name,Variable Label,Type,"Codelist / Controlled +Terms",Core,CDISC Notes +TRTP,Planned Treatment,Char,,Req,"TRTP is a record-level identifier that represents the planned treatment attributed to a record for analysis purposes. TRTP indicates how treatment varies by record within a subject and enables analysis of crossover and other designs. TRTxxP (copied from ADSL) may also be needed for some analysis purposes, and may be useful for +traceability and to provide context." +TRTPN,Planned Treatment (N),Num,,Perm,The numeric code for TRTP. One-to-one map to TRTP. +TRTA,Actual Treatment,Char,,Cond,"TRTA is a record-level identifier that represents the actual treatment attributed to a record for analysis purposes. TRTA indicates how treatment varies by record within a subject and enables analysis of crossover and other multi-period designs. TRTxxA (copied from ADSL) may also be needed for some analysis purposes, and may be useful for traceability and to provide context. TRTA is required when there is an analysis of data as treated and at least one subject has any data associated with a treatment other +than the planned treatment." +TRTAN,"Actual Treatment +(N)",Num,,Perm,The numeric code for TRTA. One-to-one map to TRTA. +TRTPGy,Planned Pooled Treatment y,Char,,Perm,"Planned pooled treatment y. “y” represents an integer [1-9] corresponding to a particular pooling scheme. Useful when planned treatments (TRTP) are pooled together for analysis, for example when all doses of Drug A (TRTPG1=All doses of Drug A) are +compared to all doses of Drug B (TRTPG1=All doses of Drug B). Each value of TRTP is pooled within at most one value of TRTPGy. May vary by record within a subject." +TRTPGyN,"Planned Pooled +Treatment y (N)",Num,,Perm,The numeric code for TRTPGy. One-to-one map to TRTPGy. +TRTAGy,Actual Pooled Treatment y,Char,,Cond,"Actual pooled treatment y. “y” represents an integer [1-9] corresponding to a particular +pooling scheme. Required when TRTPGy is present and TRTA is present. May vary by record within a subject." +TRTAGyN,"Actual Pooled +Treatment y (N)",Num,,Perm,The numeric code for TRTAGy. One-to-one map to TRTAGy. diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Dose_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Dose_Variables.csv new file mode 100644 index 0000000..0515525 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Dose_Variables.csv @@ -0,0 +1,7 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +DOSExxP,Planned Treatment Dose for Period xx,Num,,Perm,Subject-level identifier that represents the planned treatment dosage for period xx. +DOSExxA,"Actual Treatment +Dose for Period xx",Num,,Perm,Subject-level identifier that represents the actual treatment dosage for period xx. +DOSExxU,"Units for Dose for +Period xx",Char,,Perm,"The units for DOSExxP and DOSExxA. It is permissible to use suffixes such as “P” and “A” if +needed, with labels modified accordingly." diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Identifier_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Identifier_Variables.csv new file mode 100644 index 0000000..4ff9fcf --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Identifier_Variables.csv @@ -0,0 +1,15 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +STUDYID,Study Identifier,Char,,Req,DM.STUDYID +USUBJID,"Unique Subject +Identifier",Char,,Req,DM.USUBJID +SUBJID,"Subject Identifier +for the Study",Char,,Req,"DM.SUBJID. SUBJID is required in ADSL, but permissible in other datasets." +SITEID,Study Site Identifier,Char,,Req,"DM.SITEID. SITEID is required in ADSL, but permissible in other datasets." +SITEGRy,Pooled Site Group y,Char,,Perm,"Character description of a grouping or pooling of clinical sites for analysis purposes. For example, SITEGR3 is the name of a variable containing site group (pooled site) names, where the grouping has been done according to the third site grouping algorithm, defined in variable metadata; SITEGR3 does not mean the third group of sites." +SITEGRyN,Pooled Site Group y (N),Num,,Perm,The numeric code for SITEGRy. One-to-one mapping to SITEGRy within a study. +REGIONy,Geographic Region y,Char,,Perm,"Character description of geographical region. For example, REGION1 might have values of ‘Asia’, +‘Europe’, ‘North America’, ‘Rest of World’; REGION2 might have values of ‘United States’, ‘Rest of World’." +REGIONyN,"Geographic Region +y (N)",Num,,Perm,"The numeric code for REGIONy. Orders REGIONy for analysis and reporting. One-to-one +mapping to REGIONy within a study." diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Population_Indicator_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Population_Indicator_Variables.csv new file mode 100644 index 0000000..cae3f1c --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Population_Indicator_Variables.csv @@ -0,0 +1,25 @@ +Variable Name ,Variable Label ,Type,"Codelist/ +Controlled +Terms",Core ,CDISC Notes +FASFL ,"Full Analysis Set +Population Flag",Char ,"Y, N ",Cond ,"These flags identify whether or not the subject is included in the specified population. A minimum +of one subject-level population flag variable is required in ADSL. +Not all of the indicators listed here need to be included in ADSL. As stated in Section 3.1.4, Item 2, +only those indicators corresponding to populations defined in the statistical analysis plan or +populations used as a basis for analysis need be included in ADSL. +This list of flags is not meant to be all-inclusive. Additional population flags may be added. +The values of subject-level population flags cannot be blank. If a flag is used, the corresponding +numeric version (*FN, where 0=no and 1=yes) of the population flag can also be included. Please +also refer to Section 3.1.4." +SAFFL ,"Safety Population +Flag",Char ,"Y, N ",Cond, +ITTFL ,"Intent-To-Treat +Population Flag",Char ,"Y, N ",Cond, +PPROTFL ,"Per-Protocol +Population Flag",Char ,"Y, N ",Cond, +COMPLFL ,"Completers +Population Flag",Char ,"Y, N ",Cond, +RANDFL ,"Randomized +Population Flag",Char ,"Y, N ",Cond, +ENRLFL ,"Enrolled Population +Flag",Char ,"Y, N ",Cond, diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Subject_Demographics_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Subject_Demographics_Variables.csv new file mode 100644 index 0000000..3f2e145 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Subject_Demographics_Variables.csv @@ -0,0 +1,13 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +AGE,Age,Num,,Req,"DM.AGE. If analysis needs require a derived age that does not match DM.AGE, then AAGE must be added" +AGEU,Age Units,Char,(AGEU),Req,DM.AGEU +AGEGRy,Pooled Age Group y,Char,,Perm,"Character description of a grouping or pooling of the subject’s age for analysis purposes. For example, AGEGR1 might have values of “<18”, “18-65”, and “>65”; AGEGR2 might have values of “Less than 35 y old” and “At least 35 y old”." +AGEGRyN,Pooled Age Group y (N),Num,,Perm,The numeric code for AGEGRy. Orders the grouping or pooling of subject age for analysis and reporting. One-to-one mapping to AGEGRy within a study. +AAGE,Analysis Age,Num,,Cond,"Age used for analysis that is derived differently from DM.AGE. AAGE is required if age is +calculated differently than in SDTM." +SEX,Sex,Char,(SEX),Req,The sex of the subject is a required variable in ADSL; must be identical to DM.SEX. +RACE,Race,Char,(RACE),Req,The race of the subject is a required variable in ADSL; must be identical to DM.RACE. +RACEGRy,Pooled Race Group y,Char,,Perm,Character description of a grouping or pooling of the subject’s race for analysis purposes. +RACEGRyN,"Pooled Race Group +y (N)",Num,,Perm,"The numeric code for RACEGRy. Orders the grouping or pooling of subject race for analysis and +reporting. One-to-one mapping to RACEGRy within a study." diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Subject_Level_Trial_Experience_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Subject_Level_Trial_Experience_Variables.csv new file mode 100644 index 0000000..f555eac --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Subject_Level_Trial_Experience_Variables.csv @@ -0,0 +1,70 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +EOSSTT,End of Study Status,Char,,Perm,"The subject’s status as of the end of study or data cutoff. Examples: COMPLETED, +DISCONTINUED, ONGOING." +EOSDT,End of Study Date,Num,,Perm,"Date subject ended the study – either date of completion or date of discontinuation or data cutoff +date for interim analyses." +DCSREAS,"Reason for Discontinuation +from Study",Char,,Perm,Reason for subject’s discontinuation from study. The source would most likely be the SDTM DS dataset. Null for subjects who completed the study. +DCSREASP,Reason Spec for Discont from Study,Char,,Perm,"Additional detail regarding subject’s discontinuation from study (e.g., description of “other”)." +EOTSTT,"End of Treatment +Status",Char,,Perm,"The subject’s status as of the end of treatment or data cutoff. Examples: COMPLETED, +DISCONTINUED, ONGOING." +DCTREAS,"Reason for Discontinuation of +Treatment",Char,,Perm,"If a subject discontinued treatment in the study, then this variable indicates the reason for discontinuation. This is for discontinuation of treatment in the overall study and not to be used for +discontinuation reason within individual treatment periods." +DCTREASP,"Reason Specify for Discont of +Treatment",Char,,Perm,"Additional detail regarding subject’s discontinuation from treatment (e.g., description of “other”)." +EOTxxSTT,"End of Treatment +Status in Period xx",Char,,Perm,"The subject’s treatment status as of the end of period xx, or data cutoff if within period xx. +Examples: COMPLETED, DISCONTINUED, ONGOING." +DCTxxRS,"Reason for Discont +of Treat in Period xx",Char,,Perm,Reason for discontinuing treatment in period xx. +DCTxxRSP,"Reason Spec for +Disc of Trt in Period xx",Char,,Perm,"Additional detail regarding subject’s discontinuation of treatment in period xx (e.g., description of “other”)." +EOPxxSTT,"End of Period xx +Status",Char,,Perm,"The subject’s status as of the end of period xx, or data cutoff if within period xx. Examples: +COMPLETED, DISCONTINUED, ONGOING." +DCPxxRS,Reason for Discont from Period xx,Char,,Perm,Reason for discontinuing analysis period xx. +DCPxxRSP,"Reason Spec for +Discont from Period xx",Char,,Perm,"Additional detail regarding subject’s discontinuation from period xx (e.g., description of “other”)." +RFICDT,"Date of Informed +Consent",Num,,Perm,Date subject gave informed consent. Generally equivalent to DM.RFICDTC. +ENRLDT,Date of Enrollment,Num,,Perm,Date of subject’s enrollment into trial. +RANDDT,"Date of +Randomization",Num,,Cond,Required in randomized trials. +RFICyDT,Date of Informed Consent y,Num,,Perm,"This variable may be used in the case where there are multiple consent dates within a study. This date does not need to repeat the date in RFICDT. ‘y’ can start with 1 but it is not required to start +with 1." +ENRLyDT,Date of Enrollment y,Num,,Perm,"This variable may be used in the case where there are multiple enrollment dates within a study. This date does not need to repeat the date in ENRLDT. ‘y’ can start with 1 but it is not required to +start with 1." +RANDyDT,Date of Randomization y,Num,,Perm,"This variable may be used in the case where there are multiple randomization dates within a study. This date does not need to repeat the date in RANDDT. ‘y’ can start with 1 but it is not required to +start with 1." +LSTALVDT,Date Last Known Alive,Num,,Perm,"If this variable is included in ADSL, the best practice is to populate it for everyone. If the derivation for subjects who died differs from the derivation for subjects who are not known to have died, the differences should be noted in metadata." +TRCMP,Treatment Compliance (%),Num,,Perm,Overall percent compliance with treatment in the trial. TRCMP may be useful for inclusion in ADSL for reasons such as defining subgroups and/or populations. +TRCMPGy,"Treatment Compliance (%) +Group y",Char,,Perm,"Grouping ‘y’ of TRCMP, treatment compliance percentage." +TRCMPGyN,"Treatment Compliance (%) +Group y (N)",Num,,Perm,Numeric version of treatment compliance (%) grouping ‘y’. Must have a one-to-one mapping to TRCMPGy. +TRxxDURD,Treatment Duration in Period xx (Days),Num,,Perm,"Treatment duration for period xx as measured in days. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its +respective units." +TRxxDURM,"Treatment Duration in Period xx +(Months)",Num,,Perm,"Treatment duration for period xx, as measure in months. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its +respective units." +TRxxDURY,Treatment Duration in Period xx (Years),Num,,Perm,"Treatment duration for period xx, as measured in years. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its +respective units." +TRTDURD,Total Treatment Duration (Days),Num,,Perm,"Total treatment duration, as measured in days. More than one of TRTDURD, TRTDURM, and TRTDURY can be populated, but each represents the entire duration in its respective units." +TRTDURM,"Total Treatment +Duration (Months)",Num,,Perm,"Total treatment duration, as measured in months. More than one of TRTDURD, TRTDURM, and +TRTDURY can be populated, but each represents the entire duration in its respective units." +TRTDURY,"Total Treatment +Duration (Years)",Num,,Perm,"Total treatment duration, as measured in years. More than one of TRTDURD, TRTDURM, and +TRTDURY can be populated, but each represents the entire duration in its respective units." +DTHDT,Date of Death,Num,,Perm,Date of subject’s death. Derived from DM.DTHDTC. +DTHDTF,"Date of Death +Imputation Flag",Char,,Cond,"Imputation flag for date of subject’s death. If DTHDT was imputed, DTHDTF must be populated +and is required. See Section 3.1.3." +DTHCAUS,Cause of Death,Char,,Perm,Cause of Death. +DTHCAUSN,Cause of Death (N),Num,,Perm,Numeric representation of cause of death. Must have a one-to-one mapping to DTHCAUS. +DTHCGRy,Cause of Death Group y,Char,,Perm,"Grouping ‘y’ of DTHCAUS, the subject’s cause of death." +DTHCGRyN,"Cause of Death +Group y (N)",Num,,Perm,"Numeric version of grouping ‘y’ of the subject’s cause of death. Must have a one-to-one mapping +to DTHCGRy." diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Timing_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Timing_Variables.csv new file mode 100644 index 0000000..ab001f6 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Timing_Variables.csv @@ -0,0 +1,46 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +TRTSDT,Date of First Exposure to Treatment,Num,,Cond,"Date of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. Note that TRTSDT is not required to have the same value as the SDTM DM variable RFXSTDTC. While both of these dates reflect the concept of first +exposure, the ADaM date may be derived to support the analysis which may not necessarily be the very first date in the SDTM EX domain." +TRTSTM,"Time of First Exposure to +Treatment",Num,,Perm,Time of first exposure to treatment for a subject in a study. +TRTSDTM,Datetime of First Exposure to Treatment,Num,,Cond,Datetime of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. +TRTSDTF,"Date of First +Exposure Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of date of first exposure to treatment. If TRTSDT (or the date part of TRTSDTM) was imputed, TRTSDTF must be populated and is required. See Section 3.1.3." +TRTSTMF,"Time of First +Exposure Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of time of first exposure to treatment. If TRTSTM (or the time part of TRTSDTM) was imputed, TRTSTMF must be populated and is required. See Section 3.1.3." +TRTEDT,Date of Last Exposure to Treatment,Num,,Cond,"Date of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. Note that TRTEDT is not required to have the same value as the SDTM DM variable RFXENDTC. While both of these dates reflect the concept of last +exposure, the ADaM date may be derived to support the analysis which may not necessarily be the very last date in the SDTM EX domain." +TRTETM,Time of Last Exposure to Treatment,Num,,Perm,Time of last exposure to treatment for a subject in a study. +TRTEDTM,"Datetime of Last +Exposure to Treatment",Num,,Cond,Datetime of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. +TRTEDTF,"Date of Last Exposure Imput. +Flag",Char,(DATEFL),Cond,"The level of imputation of date of last exposure to treatment. If TRTEDT (or the date part of TRTEDTM) was imputed, TRTEDTF must be populated and is required. See Section 3.1.3." +TRTETMF,"Time of Last Exposure Imput. +Flag",Char,(TIMEFL),Cond,"The level of imputation of time of last exposure to treatment. If TRTETM (or the time part of TRTEDTM) was imputed, TRTETMF must be populated and is required. See Section 3.1.3." +TRxxSDT,Date of First Exposure in Period xx,Num,,Cond,"Date of first exposure to treatment in period xx. TRxxSDT and/or TRxxSDTM are only required in trial designs where multiple treatments are given to the same subject, such as a crossover design, but are permissible for other trial designs. Also useful in designs where multiple periods exist for +the same treatment (i.e., multiple cycles of the same study treatment)." +TRxxSTM,"Time of First Exposure in Period +xx",Num,,Cond,"The starting time of exposure to treatment in period xx. TRxxSTM and/or TRxxSDTM are only required in trial designs where multiple treatments are given to the same subject, such as a +crossover design (but are permissible for other trial designs), and time is important to the analysis." +TRxxSDTM,"Datetime of First Exposure in Period +xx",Num,,Cond,"Datetime of first exposure to treatment in period xx. TRxxSDT and/or TRxxSDTM are only required in trial designs where multiple treatments are given to the same subject, such as a +crossover design, but are permissible for other trial designs." +TRxxSDTF,"Date 1st Exposure Period xx Imput. +Flag",Char,(DATEFL),Cond,"The level of imputation of date of first exposure to treatment in period xx. If TRxxSDT (or the date part of TRxxSDTM) was imputed, TRxxSDTF must be populated and is required. See Section +3.1.3." +TRxxSTMF,"Time 1st Exposure Period xx Imput. +Flag",Char,(TIMEFL),Cond,"The level of imputation of time of first exposure to treatment in period xx. If TRxxSTM (or the time part of TRxxSDTM) was imputed, TRxxSTMF must be populated and is required. See +Section 3.1.3." +TRxxEDT,"Date of Last Exposure in Period +xx",Num,,Cond,"Date of last exposure to treatment in period xx. TRxxEDT and/or TRxxEDTM are only required in trial designs where multiple treatments are given to the same subject, such as a crossover design, +but are permissible for other trial designs." +TRxxETM,Time of Last Exposure in Period xx,Num,,Cond,"The ending time of exposure to treatment in period xx. TRxxETM and/or TRxxEDTM are only required in trial designs where multiple treatments are given to the same subject, such as a crossover design, and ending time is important to the analysis, but are permissible for other trial designs." +TRxxEDTM,"Datetime of Last Exposure in Period +xx",Num,,Cond,"The datetime of last exposure to treatment in period xx. TRxxEDT and/or TRxxEDTM are only required in trial designs where multiple treatments are given to the same subject, such as a +crossover design, but are permissible for other trial designs." +TRxxEDTF,"Date Last Exposure Period xx Imput. +Flag",Char,(DATEFL),Cond,"The level of imputation of date of last exposure to treatment in period xx. If TRxxEDT (or the date part of TRxxEDTM) was imputed, TRxxEDTF must be populated and is required. See Section 3.1.3." +TRxxETMF,"Time Last Exposure Period xx Imput. +Flag",Char,(TIMEFL),Cond,"The level of imputation of time of last exposure to treatment in period xx. If TRxxETM (or the time +part of TRxxEDTM) was imputed, TRxxETMF must be populated and is required. See Section 3.1.3." diff --git a/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Variables.csv b/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Variables.csv new file mode 100644 index 0000000..c9a4311 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/ADSL_Treatment_Variables.csv @@ -0,0 +1,34 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ARM,"Description of +Planned Arm",Char,,Req,DM.ARM +ACTARM,"Description of +Actual Arm",Char,,Perm,DM.ACTARM +TRTxxP,Planned Treatment for Period xx,Char,,Req,"Subject-level identifier that represents the planned treatment for period xx. In a one-period randomized trial, TRT01P would be the treatment to which the subject was randomized. TRTxxP +might be derived from the SDTM DM variable ARM. At least TRT01P is required." +TRTxxPN,"Planned Treatment +for Period xx (N)",Num,,Perm,The numeric code variable for TRTxxP. One-to-one mapping to TRTxxP within a study. +TRTxxA,Actual Treatment for Period xx,Char,,Cond,Subject-level identifier that represents the actual treatment for the subject for period xx. Required when actual treatment does not match planned and there is an analysis of the data as treated. +TRTxxAN,"Actual Treatment +for Period xx (N)",Num,,Perm,The numeric code variable for TRTxxA. One-to-one mapping to TRTxxA within a study. +TRTSEQP,Planned Sequence of Treatments,Char,,Cond,"Required when there is an analysis based on the sequence of treatments, for example in a crossover design. TRTSEQP is not necessarily equal to ARM, for example if ARM contains elements that are not relevant to analysis of treatments or ARM is not fully descriptive (e.g., “GROUP 1,” “GROUP +2”). When analyzing based on the sequence of treatments, TRTSEQP is required even if identical to ARM." +TRTSEQPN,"Planned Sequence +of Treatments (N)",Num,,Perm,Numeric version of TRTSEQP. One-to-one mapping to TRTSEQP within a study. +TRTSEQA,Actual Sequence of Treatments,Char,,Cond,"TRTSEQA is required if a situation occurred in the conduct of the trial where a subject received a +sequence of treatments other than what was planned and there is an analysis based on the sequence of treatments." +TRTSEQAN,"Actual Sequence of +Treatments (N)",Num,,Perm,Numeric version of TRTSEQA. One-to-one mapping to TRTSEQA within a study. +TRxxPGy,Planned Pooled Treatment y for Period xx,Char,,Perm,"Planned pooled treatment y for period xx. Useful when planned treatments (TRTxxP) in the specified period xx are pooled together for analysis according to pooling algorithm y. For example when in period 2 the first pooling algorithm dictates that all doses of Drug A (TR02PG1=“All +doses of Drug A”) are pooled together for comparison to all doses of Drug B (TR02PG1=“All doses of Drug B”). Each value of TRTxxP is pooled within at most one value of TRxxPGy." +TRxxPGyN,"Planned Pooled Trt +y for Period xx (N)",Num *,,Perm,The numeric code for TRxxPGy. One-to-one mapping to TRxxPGy within a study. +TRxxAGy,"Actual Pooled Treatment y for +Period xx",Char,,Cond,Actual pooled treatment y for period xx. Required when TRxxPGy is present and TRTxxA is present. +TRxxAGyN,"Actual Pooled Trt y +for Period xx (N)",Num *,,Perm,The numeric code for TRxxAGy. One-to-one mapping to TRxxAGy within a study. +TSEQPGy,Planned Pooled Treatment Sequence y,Char,,Perm,"Planned pooled treatment sequence y. Useful when planned treatment sequences (TRTSEQP) are pooled together for analysis according to pooling algorithm y. For example, this might be used in +an analysis of an extension study when the analysis is based on what the subject received in the parent study as well as in the extension study." +TSEQPGyN,Planned Pooled Treatment Sequence y (N),Num,,Perm,Numeric version of TSEQPGy. One-to-one mapping to TSEQPGy within a study. +TSEQAGy,Actual Pooled Treatment Sequence y,Char,,Cond,Actual pooled treatment sequence y. Required when TSEQPGy is present and TRTSEQA is present. +TSEQAGyN,"Actual Pooled +Treatment Sequence y (N)",Num,,Perm,Numeric version of TSEQAGy. One-to-one mapping to TSEQAGy within a study. diff --git a/data-raw/ig_source/adamig_1.1/Analysis_Descriptor_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Analysis_Descriptor_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..628dbd7 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Analysis_Descriptor_Variables_BDS_Datasets.csv @@ -0,0 +1,10 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +DTYPE,Derivation Type,Char,(DTYPE),Cond,"Analysis value derivation method. DTYPE is used to denote, and is required to be populated, when the value of AVAL or AVALC has been imputed or derived differently than the other analysis values within the parameter. DTYPE is required to be populated even if AVAL and AVALC are null on the derived record. +Three common situations when DTYPE should be populated: +(1) a new row is added within a parameter with the analysis value populated based on other rows within the parameter, +(2) a new row is added within a parameter with the analysis value populated based on a constant value or data from other subjects, +(3) an analysis value (AVAL or AVALC) on an existing record is being replaced with a value based on a pre-specified algorithm. +DTYPE is used to denote analysis values that are “special cases” within a parameter. For each value of DTYPE, the precise derivation algorithm must be defined in analysis variable metadata, even for DTYPE values in the controlled terminology. The controlled terminology for DTYPE is extensible. See Section 4 for examples of the use of DTYPE. +Examples of DTYPE values: +LOCF = last observation carried forward. WOCF = worst observation carried forward. AVERAGE = average of values." diff --git a/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..3c0a9a1 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv @@ -0,0 +1,17 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +CRITy,Analysis Criterion y,Char,,Perm,"A text string identifying a pre-specified criterion within a parameter, for example SYSBP > 90. Required if CRITyFL exists. In some cases, the presence of the text string indicates that the criterion is satisfied on this record and CRITyFL is set to Y, while a null value indicates that the criterion is not satisfied or is not evaluable and is accompanied by a null value in CRITyFL. In other cases, the text string identifies the criterion being evaluated and is populated on every row for the parameter, but whether or not the criterion is satisfied is indicated by the value of the variable +CRITyFL. See CRITyFL and CRITyFN. Refer to Section 4.7 for additional discussion of CRITy, CRITyFL and CRITyFN." +CRITyFL,Criterion y Evaluation Result Flag,Char,"Y +or +Y, N",Cond,Character flag variable indicating whether the criterion defined in CRITy was met by the data on the record. See CRITy for more information regarding how to use CRITy and CRITyFL to indicate whether a criterion is met. Required if CRITy exists. Refer to Section 4.7 for additional discussion. +CRITyFN,"Criterion y +Evaluation Result Flag (N)",Num,"1 +or +1, 0",Perm,Numeric representation of CRITyFL. There is a one-to-one mapping between CRITyFL and CRITyFN. CRITyFN can be included only if CRITyFL is also included. +MCRITy,Analysis Multi- Response Criterion y,Char,,Perm,"A text string identifying a pre-specified criterion within a parameter, where the criterion can have multiple responses (as opposed to CRITy which has binary responses). Required if MCRITyML exists. For example, the grade of a lab analyte is compared to the baseline grade, with the possible conditions being 0 to 1, 0 to 2, etc. The text string identifies the criterion being evaluated (for example, “Grade increase”) and is populated on every row for the parameter; which level of the criterion is satisfied is indicated by the value of the variable MCRITyML (for example “0 to 1”, “0 +to 2”, etc.) See MCRITyML and MCRITyMN below, and refer to Section 4.7 for additional discussion of MCRITy, MCRITyML, and MCRITyMN." +MCRITyML,"Multi-Response +Criterion y Evaluation",Char,,Cond,"Character variable indicating which level of the criterion defined in MCRITy was met by the data +on the record. See MCRITy for more information regarding how to use MCRITy and MCRITyML to indicate whether a criterion was met. Content is sponsor-defined. Required if MCRITy exists." +MCRITyMN,Multi-Response Criterion y Eval (N),Num,,Perm,"Numeric representation of MCRITyML. There is a one-to-one mapping between MCRITyML and +MCRITyMN. Content is sponsor-defined. MCRITyMN can be included only if MCRITyML is also included." diff --git a/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..5492626 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Analysis_Parameter_Variables_BDS_Datasets.csv @@ -0,0 +1,53 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +PARAM,Parameter,Char,,Req,"The description of the analysis parameter. Examples include: “Supine Systolic Blood Pressure (mm Hg)”, “Log10 (Weight (kg))”, “Time to First Hypertension Event (Days)”, “Estimated Tumor Growth Rate”, etc. PARAM should be sufficient to describe unambiguously the contents of AVAL and/or AVALC. PARAM must include all descriptive and qualifying information relevant to the analysis purpose of the parameter. +Examples of qualifying information that might be relevant to analysis and therefore are candidates for inclusion in PARAM are units, specimen type, location, position, machine type, and transformation function. There is no need to include qualifiers that are not relevant to the analysis of PARAM. In contrast to SDTM --TEST, no additional variable is needed to further qualify PARAM. +PARAM may be longer than 40 characters in length but is restricted to a maximum of 200 characters. PARAM is often directly usable in Clinical Study Report displays. Note that in the +ADaMIG, “parameter” is a synonym of “analysis parameter.”" +PARAMCD,Parameter Code,Char,,Req,"The short name of the analysis parameter in PARAM. Values of PARAMCD should follow the SAS Version 5 transport file format and Oracle constraints as noted under General Variable +Conventions in Section 3.1.1. There must be a one-to-one mapping to PARAM within a dataset." +PARAMN,Parameter (N),Num,,Perm,"A numeric representation of PARAM. Useful for ordering and programmatic manipulation. There +must be a one-to-one mapping to PARAM within a dataset." +PARAMTYP,Parameter Type,Char,(PARAMTYP),Perm,"Indicator of whether the parameter is derived as a function of one or more other parameters. +This variable will be retired from the ADaMIG in the next version because it was confused with the concept of DTYPE and therefore was being misused. The variable metadata should be adequate to indicate when a parameter is wholly derived." +PARCATy,Parameter Category y,Char,,Perm,"A categorization of PARAM within a dataset. For example, values of PARCAT1 might group the parameters having to do with a particular questionnaire, lab specimen type, or area of investigation. Note that PARCATy is not a qualifier for PARAM. PARAM to PARCATy is a many-to-one mapping; any given PARAM may be associated with at most one level of PARCATy (e.g., one +level of PARCAT1 and one level of PARCAT2)." +PARCATyN,"Parameter Category +y (N)",Num,,Perm,"A numeric representation of PARCATy. This can be used for operations on PARCATy. There must +be a one-to-one relationship within a dataset between PARCATy and PARCATyN." +AVAL,Analysis Value,Num,,Cond,"Numeric analysis value described by PARAM. On a given record, it is permissible for AVAL, AVALC, or both to be null. AVAL is required if AVALC is not present, since either AVAL or +AVALC must be present in the dataset." +AVALC,Analysis Value (C),Char,,Cond,"Character analysis value described by PARAM. AVALC can be a character string mapping to AVAL, but if so there must be a one-to-one map between AVAL and AVALC within a given PARAM. AVALC should not be used to categorize the values of AVAL. Within a given parameter, if there exists a row on which both AVALC and AVAL are populated, then there must be a one-to- one mapping between AVALC and AVAL on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AVAL or AVALC be included when determining whether the one-to-one mapping requirement is satisfied.) On a given record, it is permissible for AVAL, AVALC, or both to be null. +AVALC is required if AVAL is not present, since either AVAL or AVALC must be present in the dataset." +AVALCATy,Analysis Value Category y,Char,,Perm,"A categorization of AVAL or AVALC within a parameter. Not necessarily a one-to-one mapping to AVAL and/or AVALC. For example, if PARAM is “Headache Severity” and AVAL has values 0, 1, 2, or 3, AVALCAT1 can categorize AVAL into “None or Mild” (for AVAL 0 or 1) and +“Moderate or Severe” (for AVAL 2 or 3)." +AVALCAyN,Analysis Value Category y (N),Num,,Perm,"A numeric representation of AVALCATy. This can be used for ordering of values of AVALCATy +or for other purposes. There must be a one-to-one relationship within a parameter between AVALCATy and AVALCAyN." +BASE,Baseline Value,Num,,Cond,"The subject’s baseline analysis value for a parameter and baseline definition (i.e. BASETYPE) if present. BASE contains the value of AVAL copied from a record within the parameter on which ABLFL = “Y”. Required if dataset supports analysis or review of numeric baseline value or functions of numeric baseline value. If BASE is populated for a parameter, and BASE is non-null for a subject for that parameter, then there must be a record flagged by ABLFL for that subject and parameter. Note that a baseline record may be derived (e.g., it may be an average) in which case +DTYPE must be populated on the baseline record." +BASEC,Baseline Value (C),Char,,Perm,"The subject’s baseline value of AVALC for a parameter and baseline definition (i.e. BASETYPE) if present. May be needed when AVALC is of interest. BASEC contains the value of AVALC copied from a record within the parameter on which ABLFL = “Y”. If both AVAL and AVALC are populated within a parameter, the baseline record for AVALC must be the same record as that for AVAL. +Within a given parameter, if there exists a row on which both BASEC and BASE are populated, then there must be a one-to-one mapping between BASEC and BASE on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either BASE or BASEC be included when determining whether the one-to-one mapping requirement is satisfied.) On a given record, it is permissible for BASE, BASEC, or both to be null." +BASECATy,Baseline Category y,Char,,Perm,"A categorization of BASE or BASEC within a parameter. Not necessarily a one-to-one mapping to BASE or BASEC. For example, if PARAM is “Headache Severity” and AVAL has values 0, 1, 2, or 3, BASECAT1 can categorize BASE into “None or Mild” (for BASE 0 or 1) and “Moderate or +Severe” (for BASE 2 or 3)." +BASECAyN,Baseline Category y (N),Num,,Perm,"A numeric representation of BASECATy. This can be used for ordering of values of BASECATy +or for other purposes. There must be a one-to-one relationship within a parameter between BASECATy and BASECAyN." +BASETYPE,Baseline Type,Char,,Cond,"Producer-defined text describing the definition of baseline relevant to the value of BASE on the current record. Required when there are multiple ways that baseline is defined. If used for any PARAM within a dataset, should be non-null for all records of that dataset. Refer to Section 4.2.1, +Rule 6, for an example." +CHG,Change from Baseline,Num,,Perm,"Change from baseline analysis value. Equal to AVAL-BASE. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used +for analysis. The decision on how to populate pre-baseline and baseline values of CHG is left to producer choice." +CHGCATy,Change from Baseline Category y,Char,,Perm,"A categorization of CHG within a parameter. Not necessarily a one-to-one mapping to CHG. The definition of CHGCATy may vary by PARAM. For example, CHGCAT1 may be used to categorize CHG with respect to ranges of change in SYSBP; “-10 to -5 mm Hg”, “-5 to 0 mm Hg” categories." +CHGCATyN,Change from Baseline Category y (N),Num,,Perm,A numeric representation of CHGCATy. This can be used for ordering of values of CHGCATy or for other purposes. There must be a one-to-one relationship within a parameter between CHGCATy and CHGCATyN. +PCHG,Percent Change from Baseline,Num,,Perm,"Percent change from baseline analysis value. Equal to ((AVAL-BASE)/BASE)*100. If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of PCHG is left to producer choice." +PCHGCATy,Percent Chg from Baseline Category y,Char,,Perm,"A categorization of PCHG within a parameter. Not necessarily a one-to-one mapping to PCHG. The definition of PCHGCATy may vary by PARAM. For example, PCHGCAT1 may be used to +categorize PCHG with respect to ranges of change in SYSBP; “>5%”, “>10%” categories." +PCHGCAyN,Percent Chg from Baseline Category y (N),Num,,Perm,A numeric representation of PCHGCATy. This can be used for ordering of values of PCHGCATy or for other purposes. There must be a one-to-one relationship within a parameter between PCHGCATy and PCHGCAyN. +R2BASE,Ratio to Baseline,Num,,Perm,"Ratio to the baseline value. Equal to AVAL / BASE. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for +analysis. The decision on how to populate pre-baseline and baseline values of R2BASE is left to producer choice." +R2AyLO,Ratio to Analysis Range y Lower Limit,Num,,Perm,"Ratio to the lower limit of the analysis range y. Equal to AVAL / AyLO. AyLO must exist in the ADaM dataset. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of R2AyLO is left to producer choice." +R2AyHI,Ratio to Analysis Range y Upper Limit,Num,,Perm,"Ratio to the upper limit of the analysis range y. Equal to AVAL / AyHI. AyHI must exist in the ADaM dataset. If used for a given PARAM, should be populated for all post-baseline records of +that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of R2AyHI is left to producer choice." +SHIFTy,Shift y,Char,,Perm,"A shift in values depending on the defined pairing for group y. SHIFTy can be based on the change in value of any of the following pairs (BASECATy, AVALCATy), (BNRIND, ANRIND), (ByIND, AyIND), (BTOXGR, ATOXGR), (BASE, AVAL) or (BASEC, AVALC). Useful for shift +tables. For example, “NORMAL to HIGH”. If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is +used for analysis. The decision on how to populate baseline and pre-baseline values of SHIFTy is left to producer choice." +SHIFTyN,Shift y (N),Num,,Perm,"Numeric version of SHIFTy. SHIFTyN maps one-to-one to SHIFTy within a parameter. If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate +baseline and pre-baseline values of SHIFTyN is left to producer choice." diff --git a/data-raw/ig_source/adamig_1.1/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..f92fff8 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv @@ -0,0 +1,11 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +AWRANGE,"Analysis Window Valid Relative +Range",Char,,Perm,"The range of values that are valid for a given analysis timepoint (a given value of AVISIT). For example, “5-9 DAYS”." +AWTARGET,Analysis Window Target,Num,,Perm,The target or most desired analysis relative day (ADY) value or analysis relative time (ARELTM) value for a given value of AVISIT. +AWTDIFF,Analysis Window Diff from Target,Num,,Perm,"Absolute difference between ADY or ARELTM and AWTARGET. It will be necessary to adjust for the fact that there is no day 0 in the event that ADY and AWTARGET are not of the same sign. +If the sign of the difference is important, then AWTDIFF might have to be used in conjunction with ADY or ARELTM and possibly AWTARGET when choosing among records." +AWLO,"Analysis Window +Beginning Timepoint",Num,,Perm,"The value of the beginning timepoint (inclusive) needs to be used in conjunction to AWRANGE. For example, if AWRANGE is “5-9 DAYS”, then AWLO is “5”." +AWHI,Analysis Window Ending Timepoint,Num,,Perm,"The value of the ending timepoint (inclusive) needs to be used in conjunction to AWRANGE. For example, if AWRANGE is “5-9 DAYS”, then AWHI is “9”." +AWU,"Analysis Window +Unit",Char,,Perm,"Unit used for AWLO and AWHI. Examples: DAYS, HOURS." diff --git a/data-raw/ig_source/adamig_1.1/BDS_Population_Indicators.csv b/data-raw/ig_source/adamig_1.1/BDS_Population_Indicators.csv new file mode 100644 index 0000000..b56bfc2 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/BDS_Population_Indicators.csv @@ -0,0 +1,19 @@ +Variable Name,Variable Label,Type,"Codelist/ Controlled +Terms",Core,CDISC Notes +ITTRFL,"Intent-To-Treat +Record-Level Flag",Char,Y,Perm,"These indicators identify whether or not the subject was in the specified analysis for the specific record. Useful when the subject is included in the subject-level population, but there are records for the subject that do not satisfy requirements for the population. The valid values of these record- level population indicators are Y or Null. If a flag is used, the corresponding numeric version (*FN, where 1=yes) of the flag can also be included. As described in Section 3.1.1 Item 8, the *FN version of the variable can be included only if the corresponding *FL is also included. Additional indicators may also be used; refer to Section 3.1.4." +SAFRFL,Safety Analysis Record-Level Flag,Char,Y,Perm, +FASRFL,"Full Analysis Set +Record-Level Flag",Char,Y,Perm, +PPROTRFL,"Per-Protocol +Record-Level Flag",Char,Y,Perm, +COMPLRFL,Completers Record- Level Flag,Char,Y,Perm, +ITTPFL,Intent-To-Treat Parameter-Level Flag,Char,Y,Perm,"These indicators identify whether or not the subject was in the specified analysis for the specific parameter. Useful when the subject is included in the subject-level population, but there are parameters for which the subject does not satisfy requirements for the population. The valid values of these parameter-level population indicators are Y or Null. If a flag is used, the corresponding numeric version (*FN, where 1=yes) of the flag can also be included. As described in Section 3.1.1 Item 8, the *FN version of the variable can be included only if the corresponding *FL is also included. Additional indicators may also be used; refer to Section 3.1.4, “Flag Variable Conventions.”" +SAFPFL,"Safety Analysis +Parameter-Level Flag",Char,Y,Perm, +FASPFL,"Full Analysis Set +Parameter-Level Flag",Char,Y,Perm, +PPROTPFL,"Per-Protocol Parameter-Level +Flag",Char,Y,Perm, +COMPLPFL,"Completers Parameter-Level +Flag",Char,Y,Perm, diff --git a/data-raw/ig_source/adamig_1.1/Datapoint_Traceability_Variables.csv b/data-raw/ig_source/adamig_1.1/Datapoint_Traceability_Variables.csv new file mode 100644 index 0000000..a0c7030 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Datapoint_Traceability_Variables.csv @@ -0,0 +1,8 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +SRCDOM,Source Data,Char,,Perm,"The SDTM domain name or ADaM dataset name that relates to the analysis value (e.g., AVAL or AVALC in a BDS dataset). If the source data is a supplemental qualifier in SDTM, this variable +will contain the value of RDOMAIN in SUPP-- or SUPPQUAL." +SRCVAR,Source Variable,Char,,Perm,"The name of the column (in the domain or dataset identified by SRCDOM) that relates to the analysis value (e.g., AVAL or AVALC in a BDS dataset). In the event that SRCDOM is a +SUPPQUAL, then SRCVAR will be populated with the value of the related QNAM." +SRCSEQ,Source Sequence Number,Num,,Perm,"The sequence number --SEQ or ASEQ of the row (in the domain or dataset identified by SRCDOM) that relates to the analysis value (e.g., AVAL or AVALC in a BDS dataset). In the event that SRCDOM is a SUPPQUAL, then this variable will contain the sequence number of the +relevant related domain record." diff --git a/data-raw/ig_source/adamig_1.1/Identifier_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Identifier_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..f377f2a --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Identifier_Variables_BDS_Datasets.csv @@ -0,0 +1,11 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +STUDYID,Study Identifier,Char,,Req,DM.STUDYID +USUBJID,"Unique Subject +Identifier",Char,,Req,DM.USUBJID +SUBJID,"Subject Identifier +for the Study",Char,,Perm,"DM.SUBJID. SUBJID is required in ADSL, but permissible in other datasets." +SITEID,Study Site Identifier,Char,,Perm,"DM.SITEID. SITEID is required in ADSL, but permissible in other datasets." +ASEQ,Analysis Sequence Number,Num,,Perm,"Sequence number given to ensure uniqueness of subject records within an ADaM dataset. As long as values are unique within a subject within the dataset, any valid number can be used for ASEQ. ASEQ uniquely indexes records within a subject within an ADaM dataset. +ASEQ is useful for traceability when the dataset is used as input to another ADaM dataset. To refer +to a record in a predecessor ADaM dataset, set SRCDOM to the name of the predecessor dataset, and set SRCSEQ to the value of ASEQ in the predecessor dataset." diff --git a/data-raw/ig_source/adamig_1.1/Indicator_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Indicator_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..5776d6a --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Indicator_Variables_BDS_Datasets.csv @@ -0,0 +1,21 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ABLFL,Baseline Record Flag,Char,Y,Cond,"Character indicator to identify the baseline record for each subject, parameter, and baseline type (BASETYPE) combination. See BASETYPE in Table 3.3.4.1. ABLFL is required if BASE is present in the dataset. +A baseline record may be derived (e.g., it may be an average), in which case DTYPE must also be populated. If BASE is populated for a parameter, and BASE is non-null for a subject for that parameter, then there must be a record flagged by ABLFL for that subject and parameter." +ABLFN,"Baseline Record +Flag (N)",Num,1,Perm,"A numeric representation of ABLFL. ABLFN has a one-to-one mapping with ABLFL. As +described in Section 3.1.1 Item 8, ABLFN can be included only if ABLFL is also included." +ANLzzFL,Analysis Flag zz,Char,Y,Cond,"ANLzzFL is a conditionally required flag to be used in addition to other selection variables when the other selection variables in combination are insufficient to identify the exact set of records used for one or more analyses. Often one ANLzzFL will serve to support the accurate selection of records for more than one analysis. Note that it is allowable to add additional descriptive text to the label (see Section 3.1.6, Item 1). +When one is defining the set of records used in a particular analysis or family of analyses, ANLzzFL is supplemental to, and is intended to be used in conjunction with, other selection variables, such as subject-level, parameter-level and record-level population flags, AVISIT, DTYPE, grouping variables such as SITEGRy, and others. The lower-case letter “zz” in the variable name is an index for the zzth record selection algorithm where “zz” is replaced with a zero- padded two-digit integer [01-99]. Every record selection algorithm “zz” (i.e., every algorithm for populating an ANLzzFL) must be defined in variable metadata. When the set of records that the algorithm “zz” operates on is pre-filtered by application of other criteria, such as a record-level population flag, then the selection algorithm definition in the metadata must so specify. +Note that the ANLzzFL value of Y indicates that the record fulfilled the requirements of the algorithm, but does not necessarily imply that the record was actually used in one or more analyses, as whether or not a record is used also depends on the other selection variables applied. The ANLzzFL flag is useful in many circumstances; an example is when there is more than one record for an analysis timepoint within a subject and parameter, as it can be used to identify the record chosen to represent the timepoint for an analysis. “zz” is an index for a record selection algorithm, such as “record closest to target relative day for the AVISIT, with ties broken by the latest record, for each AVISIT within .” +Note that it is not required that a specific ANLzzFL variable has the same definition across a project or even across datasets within a study. There is also no requirement that the ANLzzFL +variables in a dataset or study be used in numerical order; e.g. ANL02FL might occur in a dataset or study without ANL01FL present in the same dataset or study." +ANLzzFN,Analysis Flag zz (N),Num,1,Perm,"Numeric version of ANLzzFL. There is a one-to-one mapping between ANLzzFL and ANLzzFN within a dataset. As described in Section 3.1.1 Item 8, ANLzzFN can be included only if ANLzzFL is also included." +ONTRTFL,On Treatment Record Flag,Char,Y,Perm,"Character indicator of whether the observation occurred while the subject was on treatment. +ONTRTFL is producer-defined, and its definition may vary across datasets in a study based on analysis needs." +ONTRTFN,On Treatment Record Flag (N),Num,1,Perm,"Numeric representation of ONTRTFL. There is a one-to-one mapping between ONTRTFL and +ONTRTFN. As described in Section 3.1.1 Item 8, ONTRTFN can be included only if ONTRTFL is also included." +LVOTFL,"Last Value On Treatment Record +Flag",Char,Y,Perm,Character indicator of the subject’s last non-missing value on treatment for each parameter. +LVOTFN,"Last Value On +Treatment Record Flag (N)",Num,1,Perm,"Numeric representation of LVOTFL. There is a one-to-one mapping between LVOTFL and +LVOTFN. As described in Section 3.1.1 Item 8, LVOTFN can be included only if LVOTFL is also included." diff --git a/data-raw/ig_source/adamig_1.1/Period_Subperiod_Phase_Start_End_Timing_Variables.csv b/data-raw/ig_source/adamig_1.1/Period_Subperiod_Phase_Start_End_Timing_Variables.csv new file mode 100644 index 0000000..f5de42d --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Period_Subperiod_Phase_Start_End_Timing_Variables.csv @@ -0,0 +1,61 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +APERSDT,Period Start Date,Num,,Perm,The starting date for the period defined by APERIOD. +APERSTM,Period Start Time,Num,,Perm,The starting time for the period defined by APERIOD. +APERSDTM,"Period Start +Datetime",Num,,Perm,The starting datetime for the period defined by APERIOD. +APERSDTF,"Period Start Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of period start date. If APERSDT (or the date part of APERSDTM) was +imputed, APERSDTF must be populated and is required. See Section 3.1.3." +APERSTMF,"Period Start Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of period start time. If APERSTM (or the time part of APERSDTM) was +imputed, APERSTMF must be populated and is required. See Section 3.1.3." +APEREDT,Period End Date,Num,,Perm,The ending date for the period defined by APERIOD. +APERETM,Period End Time,Num,,Perm,The ending time for the period defined by APERIOD. +APEREDTM,"Period End +Datetime",Num,,Perm,The ending datetime for the period defined by APERIOD. +APEREDTF,"Period End Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of period end date. If APEREDT (or the date part of APEREDTM) was +imputed, APEREDTF must be populated and is required. See Section 3.1.3." +APERETMF,"Period End Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of period end time. If APERETM (or the time part of APEREDTM) was +imputed, APERETMF must be populated and is required. See Section 3.1.3." +ASPRSDT,"Subperiod Start +Date",Num,,Perm,The starting date for the subperiod defined by ASPER. +ASPRSTM,"Subperiod Start +Time",Num,,Perm,The starting time for the subperiod defined by ASPER. +ASPRSDTM,"Subperiod Start +Datetime",Num,,Perm,The starting datetime for the subperiod defined by ASPER. +ASPRSDTF,"Subperiod Start +Date Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of subperiod start date. If ASPRSDT (or the date part of ASPRSDTM) was +imputed, ASPRSDTF must be populated and is required. See Section 3.1.3." +ASPRSTMF,"Subperiod Start +Time Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of subperiod start time. If ASPRSTM (or the time part of ASPRSDTM) +was imputed, ASPRSTMF must be populated and is required. See Section 3.1.3." +ASPREDT,Subperiod End Date,Num,,Perm,The ending date for the subperiod defined by ASPER. +ASPRETM,Subperiod End Time,Num,,Perm,The ending time for the subperiod defined by ASPER. +ASPREDTM,"Subperiod End +Datetime",Num,,Perm,The ending datetime for the subperiod defined by ASPER. +ASPREDTF,"Subperiod End Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of subperiod end date. If ASPREDT (or the date part of ASPREDTM) was +imputed, ASPREDTF must be populated and is required. See Section 3.1.3." +ASPRETMF,"Subperiod End Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of subperiod end time. If ASPRETM (or the time part of ASPREDTM) was +imputed, ASPRETMF must be populated and is required. See Section 3.1.3." +PHSDT,Phase Start Date,Num,,Perm,The starting date for the phase defined by APHASE. +PHSTM,Phase Start Time,Num,,Perm,The starting time for the phase defined by APHASE. +PHSDTM,"Phase Start +Datetime",Num,,Perm,The starting datetime for the phase defined by APHASE. +PHSDTF,"Phase Start Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of phase start date. If PHSDT (or the date part of PHSDTM) was imputed, +PHSDTF must be populated and is required. See Section 3.1.3." +PHSTMF,Phase Start Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of phase start time. If PHSTM (or the time part of PHSDTM) was imputed, PHSTMF must be populated and is required. See Section 3.1.3." +PHEDT,Phase End Date,Num,,Perm,The ending date for the phase defined by APHASE. +PHETM,Phase End Time,Num,,Perm,The ending time for the phase defined by APHASE. +PHEDTM,Phase End Datetime,Num,,Perm,The ending datetime for the phase defined by APHASE. +PHEDTF,"Phase End Date +Imput. Flag",Char,(DATEFL),Cond,"The level of imputation of phase end date. If PHEDT (or the date part of PHEDTM) was imputed, +PHEDTF must be populated and is required. See Section 3.1.3." +PHETMF,"Phase End Time +Imput. Flag",Char,(TIMEFL),Cond,"The level of imputation of phase end time. If PHETM (or the time part of PHEDTM) was imputed, +PHETMF must be populated and is required. See Section 3.1.3." diff --git a/data-raw/ig_source/adamig_1.1/Record_Level_Dose_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Record_Level_Dose_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..6b4d8e5 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Record_Level_Dose_Variables_BDS_Datasets.csv @@ -0,0 +1,13 @@ +Variable Name,Variable Label,Type,"Codelist/ +Controlled Terms",Core,CDISC Notes +DOSEP,"Planned Treatment +Dose",Num,,Perm,DOSEP represents the planned treatment dosage associated with the record. +DOSCUMP,"Cumulative Planned +Treatment Dose",Num,,Perm,"Cumulative planned dosage of treatment for the subject at the point in time of the record (e.g., +ADT)." +DOSEA,Actual Treatment Dose,Num,,Perm,DOSEA represents the actual treatment dosage associated with the record. +DOSCUMA,"Cumulative Actual +Treatment Dose",Num,,Perm,"Cumulative actual dosage of treatment for the subject at the point in time of the record (e.g., ADT)." +DOSEU,"Treatment Dose +Units",Char,,Perm,"The units for DOSEP, DOSCUMP, DOSEA, and DOSCUMA. It is permissible to use suffixes +such as “P” and “A” if needed, with labels modified accordingly." diff --git a/data-raw/ig_source/adamig_1.1/Record_Level_Treatment_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Record_Level_Treatment_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..3f2bde9 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Record_Level_Treatment_Variables_BDS_Datasets.csv @@ -0,0 +1,18 @@ +Variable Name,Variable Label,Type,"Codelist/ Controlled +Terms",Core,CDISC Notes +TRTP,Planned Treatment,Char,,Cond,"TRTP is a record-level identifier that represents the planned treatment attributed to a record for analysis purposes. TRTP indicates how treatment varies by record within a subject and enables analysis of crossover and other designs. Though there is no requirement that TRTP will correspond to the TRTxxP as defined by the record’s value of APERIOD, if populated, TRTP must match at least one value of the character planned treatment variables in ADSL (e.g., TRTxxP, TRTSEQP, TRxxPGy). +As noted previously, at least one treatment variable is required even in non-randomized trials. This requirement is satisfied by any subject-level or record-level treatment variables (e.g., TRTxxP, TRTP, TRTA). Even if not used for analysis, any ADSL treatment variable may be included in the +BDS dataset." +TRTPN,"Planned Treatment +(N)",Num,,Perm,The numeric code for TRTP. One-to-one mapping within a study to TRTP. +TRTA,Actual Treatment,Char,,Cond,"TRTA is a record-level identifier that represents the actual treatment attributed to a record for analysis purposes. TRTA indicates how treatment varies by record within a subject and enables analysis of crossover and other multi-period designs. Though there is no requirement that TRTA will correspond to the TRTxxA as defined by the record’s value of APERIOD, TRTA must match at least one value of the character actual treatment variables in ADSL (e.g., TRTxxA, TRTSEQA, TRxxAGy). +As noted previously, at least one treatment variable is required. This requirement is satisfied by any subject-level or record-level treatment variables (e.g., TRTxxP, TRTP, TRTA). Even if not +used for analysis, any ADSL treatment variable may be included in the BDS dataset." +TRTAN,"Actual Treatment +(N)",Num,,Perm,The numeric code for TRTA. One-to-one mapping within a study to TRTA. +TRTPGy,Planned Pooled Treatment y,Char,,Perm,"TRTPGy is the planned pooled treatment y attributed to a record for analysis purposes. “y” represents an integer [1-99, not zero-padded] corresponding to a particular pooling scheme. Useful when planned treatments (TRTP) are pooled together for analysis, for example when all doses of Drug A (TRTPG1=All doses of Drug A) are compared to all doses of Drug B (TRTPG1=All doses +of Drug B). Each value of TRTP is pooled within at most one value of TRTPGy." +TRTPGyN,"Planned Pooled +Treatment y (N)",Num,,Perm,The numeric code for TRTPGy. One-to-one mapping within a study to TRTPGy. +TRTAGy,Actual Pooled Treatment y,Char,,Cond,"TRTAGy is the actual pooled treatment y attributed to a record for analysis purposes. “y” represents an integer [1-99, not zero-padded] corresponding to a particular pooling scheme. Required when TRTPGy is present and TRTA is present." +TRTAGyN,Actual Pooled Treatment y (N),Num,,Perm,The numeric code for TRTAGy. One-to-one mapping within a study to TRTAGy. diff --git a/data-raw/ig_source/adamig_1.1/Subject_level_Period_Subperiod_Phase_Timing_Variables.csv b/data-raw/ig_source/adamig_1.1/Subject_level_Period_Subperiod_Phase_Timing_Variables.csv new file mode 100644 index 0000000..0acb3eb --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Subject_level_Period_Subperiod_Phase_Timing_Variables.csv @@ -0,0 +1,55 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +APxxSDT,Period xx Start Date,Num,,Perm,The starting date of period xx. +APxxSTM,"Period xx Start +Time",Num,,Perm,The starting time of period xx. +APxxSDTM,"Period xx Start +Datetime",Num,,Perm,The starting datetime of period xx. +APxxSDTF,"Period xx Start Date +Imput. Flag",Char,(DATEFL),Cond,The level of imputation of period xx start date. See Section 3.1.3. +APxxSTMF,"Period xx Start +Time Imput. Flag",Char,(TIMEFL),Cond,The level of imputation of period xx start time. See Section 3.1.3. +APxxEDT,Period xx End Date,Num,,Perm,The ending date of period xx. +APxxETM,Period xx End Time,Num,,Perm,The ending time of period xx. +APxxEDTM,"Period xx End +Datetime",Num,,Perm,The ending datetime of period xx. +APxxEDTF,"Period xx End Date +Imput. Flag",Char,(DATEFL),Cond,The level of imputation of period xx end date. See Section 3.1.3. +APxxETMF,"Period xx End Time +Imput. Flag",Char,(TIMEFL),Cond,The level of imputation of period xx end time. See Section 3.1.3. +PxxSw,"Description of Period xx Subperiod +w",Char,,Perm,Description of analysis subperiod w within period xx. +PxxSwSDT,"Period xx Subperiod +w Start Date",Num,,Perm,The starting date of subperiod w within period xx. +PxxSwSTM,Period xx Subperiod w Start Time,Num,,Perm,The starting time of subperiod w within period xx. +PxxSwSDM,"Period xx Subperiod +w Start Datetime",Num,,Perm,The starting datetime of subperiod w within period xx. +PxxSwSDF,"Period xx Subper w Start Date Imput +Flag",Char,(DATEFL),Cond,The level of imputation of the start date for subperiod w within period xx. See Section 3.1.3. +PxxSwSTF,"Period xx Subper w Start Time Imput +Flag",Char,(TIMEFL),Cond,The level of imputation of the start time for subperiod w within period xx. See Section 3.1.3. +PxxSwEDT,Period xx Subperiod w End Date,Num,,Perm,The ending date of subperiod w within period xx. +PxxSwETM,"Period xx Subperiod +w End Time",Num,,Perm,The ending time of subperiod w within period xx. +PxxSwEDM,"Period xx Subperiod +w End Datetime",Num,,Perm,The ending datetime of subperiod w within period xx. +PxxSwEDF,Period xx Subper w End Date Imput Flag,Char,(DATEFL),Cond,The level of imputation of the end date for subperiod w within period xx. See Section 3.1.3. +PxxSwETF,"Period xx Subper w +End Time Imput Flag",Char,(TIMEFL),Cond,The level of imputation of the end time for subperiod w within period xx. See Section 3.1.3. +APHASEw,"Description of Phase +w",Char,,Perm,Description of analysis phase w. +PHwSDT,Phase w Start Date,Num,,Perm,The starting date of phase w. +PHwSTM,Phase w Start Time,Num,,Perm,The starting time of phase w. +PHwSDTM,"Phase w Start +Datetime",Num,,Perm,The starting datetime of phase w. +PHwSDTF,"Phase w Start Date +Imputation Flag",Char,(DATEFL),Cond,The level of imputation of the start date for phase w. See Section 3.1.3. +PHwSTMF,"Phase w Start Time +Imputation Flag",Char,(TIMEFL),Cond,The level of imputation of the start time for phase w. See Section 3.1.3. +PHwEDT,Phase w End Date,Num,,Perm,The ending date of phase w. +PHwETM,Phase w End Time,Num,,Perm,The ending time of phase w. +PHwEDTM,"Phase w End +Datetime",Num,,Perm,The ending datetime of phase w. +PHwEDTF,"Phase w End Date +Imputation Flag",Char,(DATEFL),Cond,The level of imputation of the end date for phase w. See Section 3.1.3. +PHwETMF,"Phase w End Time +Imputation Flag",Char,(TIMEFL),Cond,The level of imputation of the end time for phase w. See Section 3.1.3. diff --git a/data-raw/ig_source/adamig_1.1/Suffixes_User_Defined_Timing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Suffixes_User_Defined_Timing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..d6fa72c --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Suffixes_User_Defined_Timing_Variables_BDS_Datasets.csv @@ -0,0 +1,29 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +*DT,{Date},Num,,Perm,Analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*TM,{Time},Num,,Perm,Analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*DTM,{Datetime},Num,,Perm,Analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*ADY,{Relative Day},Num,,Perm,Analysis relative day not directly characterizing AVAL and/or AVALC. +*DTF,"{Date Imputation +Flag}",Char,(DATEFL),Cond,"The level of imputation of *DT. If *DT (or the date part of *DTM) was imputed, *DTF must be +populated and is required. See Section 3.1.3." +*TMF,"{Time Imputation +Flag}",Char,(TIMEFL),Cond,"The level of imputation of *TM. If *TM (or the time part of *DTM) was imputed, *TMF must be +populated and is required. See Section 3.1.3." +*SDT,{Start Date},Num,,Perm,Starting analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*STM,{Start Time},Num,,Perm,Starting analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*SDTM,{Start Datetime},Num,,Perm,Starting analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*SDY,{Relative Start Day},Num,,Perm,Starting analysis relative day not directly characterizing AVAL and/or AVALC. +*SDTF,"{Start Date +Imputation Flag}",Char,(DATEFL),Cond,"The level of imputation of *SDT. If *SDT (or the date part of *SDTM) was imputed, *SDTF must +be populated and is required. See Section 3.1.3." +*STMF,"{Start Time +Imputation Flag}",Char,(TIMEFL),Cond,"The level of imputation of *STM. If *STM (or the time part of *SDTM) was imputed, *STMF +must be populated and is required. See Section 3.1.3." +*EDT,{End Date},Num,,Perm,Ending analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*ETM,{End Time},Num,,Perm,Ending analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*EDTM,{End Datetime},Num,,Perm,Ending analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*EDY,{Relative End Day},Num,,Perm,Ending analysis relative day not directly characterizing AVAL and/or AVALC. +*EDTF,{End Date Imputation Flag},Char,(DATEFL),Cond,"The level of imputation of *EDT. If *EDT (or the date part of *EDTM) was imputed, *EDTF must be populated and is required. See Section 3.1.3." +*ETMF,"{End Time +Imputation Flag}",Char,(TIMEFL),Cond,"The level of imputation of *ETM. If *ETM (or the time part of *EDTM) was imputed, *ETMF +must be populated and is required. See Section 3.1.3." diff --git a/data-raw/ig_source/adamig_1.1/Time_To_Event_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Time_To_Event_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..03a0626 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Time_To_Event_Variables_BDS_Datasets.csv @@ -0,0 +1,17 @@ +Variable Name,Variable Label,Type,"Codelist/ Controlled +Terms",Core,CDISC Notes +STARTDT,"Time-to-Event Origin Date for +Subject",Num,,Perm,"The original date of risk for the time-to-event analysis. This is generally the time at which a subject is first at risk for the event of interest evaluation (as defined in the Protocol or Statistical Analysis +Plan). For example, this may be the randomization date or the date of first study therapy exposure." +STARTDTM,"Time-to-Event +Origin Datetime",Num,,Perm,The datetime associated with STARTDT in numeric format. +STARTDTF,Origin Date Imputation Flag,Char,(DATEFL),Cond,The level of imputation of the start date. See Section 3.1.3. +STARTTMF,"Origin Time +Imputation Flag",Char,(TIMEFL),Cond,The level of imputation of the start time. See Section 3.1.3. +CNSR,Censor,Num,,Cond,"Defines whether the event was censored for the subject within the parameter (period of observation truncated prior to event being observed). It is strongly recommended to use 0 as an event indicator and positive integers as censoring indicators. It is also recommended that unique positive integers +be used to indicate coded descriptions of censoring reasons. CNSR is required for time-to-event parameters." +EVNTDESC,"Event or Censoring +Description",Char,,Perm,Description of the event of interest or censoring reason for the subject within the parameter. +CNSDTDSC,"Censor Date +Description",Char,,Perm,"Describes the circumstance represented by the censoring date if different from the event date that +warrants censoring." diff --git a/data-raw/ig_source/adamig_1.1/Timing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Timing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..944530a --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Timing_Variables_BDS_Datasets.csv @@ -0,0 +1,66 @@ +Variable Name,Variable Label,Type,"Codelist/ Controlled +Terms",Core,CDISC Notes +ADT,Analysis Date,Num,,Perm,The date associated with AVAL and/or AVALC in numeric format. +ATM,Analysis Time,Num,,Perm,The time associated with AVAL and/or AVALC in numeric format. +ADTM,Analysis Datetime,Num,,Perm,The datetime associated with AVAL and/or AVALC in numeric format. +ADY,"Analysis Relative +Day",Num,,Perm,"The relative day of AVAL and/or AVALC. The number of days from an anchor date (not +necessarily DM.RFSTDTC) to ADT. See Section 3.1.2." +ADTF,"Analysis Date +Imputation Flag",Char,(DATEFL),Cond,"The level of imputation of analysis date. If ADT (or the date part of ADTM) was imputed, ADTF +must be populated and is required. See Section 3.1.3." +ATMF,"Analysis Time +Imputation Flag",Char,(TIMEFL),Cond,"The level of imputation of analysis time. If ATM (or the time part of ADTM) was imputed, ATMF +must be populated and is required. See Section 3.1.3." +ASTDT,Analysis Start Date,Num,,Perm,"The start date associated with AVAL and/or AVALC. ASTDT and AENDT may be useful for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a +duration." +ASTTM,Analysis Start Time,Num,,Perm,"The start time associated with AVAL and/or AVALC. ASTTM and AENTM may be useful for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a +duration." +ASTDTM,Analysis Start Datetime,Num,,Perm,"The start datetime associated with AVAL and/or AVALC. ASTDTM and AENDTM may be useful +for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a duration." +ASTDY,"Analysis Start +Relative Day",Num,,Perm,"The number of days from an anchor date (not necessarily DM.RFSTDTC) to ASTDT. See Section +3.1.2." +ASTDTF,"Analysis Start Date +Imputation Flag",Char,(DATEFL),Cond,"The level of imputation of analysis start date. If ASTDT (or the date part of ASTDTM) was +imputed, ASTDTF must be populated and is required. See Section 3.1.3." +ASTTMF,Analysis Start Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of analysis start time. If ASTTM (or the time part of ASTDTM) was imputed, ASTTMF must be populated and is required. See Section 3.1.3." +AENDT,Analysis End Date,Num,,Perm,The end date associated with AVAL and/or AVALC. See also ASTDT. +AENTM,Analysis End Time,Num,,Perm,The end time associated with AVAL and/or AVALC. See also ASTTM. +AENDTM,"Analysis End +Datetime",Num,,Perm,The end datetime associated with AVAL and/or AVALC. See also ASTDTM. +AENDY,Analysis End Relative Day,Num,,Perm,"The number of days from an anchor date (not necessarily DM.RFSTDTC) to AENDT. See Section +3.1.2." +AENDTF,"Analysis End Date +Imputation Flag",Char,(DATEFL),Cond,"The level of imputation of analysis end date. If AENDT (or the date part of AENDTM) was +imputed, AENDTF must be populated and is required. See Section 3.1.3." +AENTMF,Analysis End Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of analysis end time. If AENTM (or the time part of AENDTM) was imputed, AENTMF must be populated and is required. See Section 3.1.3." +AVISIT,Analysis Visit,Char,,Cond,"The analysis visit description; required if an analysis is done by nominal, assigned or analysis visit. AVISIT may contain the visit names as observed (i.e., from SDTM VISIT), derived visit names, time window names, conceptual descriptions (such as Average, Endpoint, etc.), or a combination of any of these. AVISIT is a derived field and does not have to map to VISIT from the SDTM. AVISIT represents the analysis visit of the record, but it does not mean that the record was analyzed. There are often multiple records for the same subject and parameter that have the same value of AVISIT. ANLzzFL and other variables may be needed to identify the records selected for any given analysis. See Section 3.3.8 for information about flag variables. AVISIT should be unique for a given analysis visit window. In the event that a record does not fall within any predefined analysis timepoint window, AVISIT can be populated in any way that the producer chooses to indicate this fact (i.e., blank or “Not Windowed”). The way that AVISIT is calculated, including the variables used in its derivation, should be indicated in the variable metadata for AVISIT. The values and the rules for deriving AVISIT may be different for different parameters within the same dataset. Values of AVISIT are producer-defined, and are often directly usable in +Clinical Study Report displays." +AVISITN,Analysis Visit (N),Num,,Perm,"A numeric representation of AVISIT. Since study visits are usually defined by certain timepoints, defining AVISITN so that it represents the timepoint associated with the visit can facilitate plotting and interpretation of the values. Alternatively, AVISITN may be a protocol visit number, a cycle number, an analysis visit number, or any other number logically related to AVISIT or useful for sorting that is needed for analysis. +Within a parameter, there is a one-to-one mapping between AVISITN and AVISIT so that AVISITN has the same value for each distinct AVISIT. (Best practice would dictate that the mapping would be one-to-one within a study, but that is not an ADaM requirement.) In the event that a record does not fall within any predefined analysis timepoint window, AVISITN can be +populated in any way that the producer chooses to indicate this fact (e.g., may be null). Values of AVISITN are producer-defined." +ATPT,Analysis Timepoint,Char,,Cond,"The analysis timepoint description; required if an analysis is done by nominal, assigned or analysis timepoint (instead of or in addition to by-visit). Timepoints are relative to ATPTREF. ATPT may contain the timepoint names as observed (i.e., from SDTM --TPT), derived timepoint names, time window names, conceptual descriptions (such as Average, Endpoint, etc.), or a combination of any of these. This variable is often used in conjunction with AVISIT. ATPT represents the analysis timepoint of the record. +ATPT can be within an analysis visit (e.g., blood pressure assessments at 10 min, 20 min, and 30 min post-dose at AVISIT=Week 1) or can be unrelated to AVISIT (e.g., migraine symptoms 30 min, 60 min, and 120 min post-dose for attack 1). +The way that ATPT is calculated, including the variables used in its derivation, should be indicated in the variable metadata for ATPT. The values and the rules for deriving ATPT may be different for different parameters within the same dataset. Values of ATPT are producer-defined, and are often +directly usable in Clinical Study Report displays." +ATPTN,Analysis Timepoint (N),Num,,Perm,"ATPTN provides a numeric representation of ATPT. Defining ATPTN so that its values represent the planned timepoints (e.g., minutes or hours after dosing) is not required but can facilitate plotting and interpretation of the values. Within the same parameter, there is a one-to-one mapping between ATPT and ATPTN. (Best practice would dictate that the mapping would be one-to-one within a +study, but that is not an ADaM requirement.)" +ATPTREF,"Analysis Timepoint +Reference",Char,,Perm,"Description of the fixed reference point referred to by ATPT/ATPTN (e.g., time of dose)." +APHASE,Phase,Char,,Perm,"APHASE is a categorization of timing within a study, for example a higher-level categorization of +APERIOD or an analysis epoch. For example, APHASE could describe spans of time for SCREENING, ON TREATMENT, and FOLLOW-UP." +APHASEN,Phase (N),Num,,Perm,"APHASEN provides a numeric representation of APHASE. Within a study, there is a one-to-one +mapping between APHASE and APHASEN." +APERIOD,Period,Num,,Perm,APERIOD is a record-level timing variable that represents the analysis period within the study associated with the record for analysis purposes. The value of APERIOD (if populated) must be one of the xx values found in the ADSL TRTxxP variables. +APERIODC,Period (C),Char,,Perm,"Text characterizing to which analysis period the record belongs. One-to-one mapping within a +dataset to APERIOD." +ASPER,"Subperiod within +Period",Num,,Perm,"The numeric value characterizing a sublevel within APERIOD to which the record belongs. Within +each APERIOD, the first ASPER is 1 (i.e., it resets to 1 when the APERIOD value changes)." +ASPERC,Subperiod within Period (C),Char,,Perm,Text characterizing to which subperiod the record belongs. One-to-one mapping within a period to ASPER. +ARELTM,Analysis Relative Time,Num,,Perm,"The time relative to an anchor time. The amount of time from an anchor time to ATM. When +ARELTM is present, the anchor time variable and ARELTMU must also be included in the dataset, and the anchor time variable must be identified in the metadata for ARELTM." +ARELTMU,"Analysis Relative +Time Unit",Char,,Perm,"The units of ARELTM. For example, “HOURS” or “MINUTES.” ARELTMU is required if +ARELTM is present." diff --git a/data-raw/ig_source/adamig_1.1/Toxicity_Range_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.1/Toxicity_Range_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..36c4c32 --- /dev/null +++ b/data-raw/ig_source/adamig_1.1/Toxicity_Range_Variables_BDS_Datasets.csv @@ -0,0 +1,35 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ATOXGR,"Analysis Toxicity +Grade",Char,,Perm,"Toxicity grade of AVAL or AVALC for analysis; may be based on SDTM --TOXGR or an +imputed or assigned value." +BTOXGR,"Baseline Toxicity +Grade",Char,,Perm,ATOXGR of the baseline record identified by ABLFL. +ANRIND,"Analysis Reference +Range Indicator",Char,,Perm,"Indicates where AVAL or AVALC falls with respect to the normal reference range for analysis; +may be based on SDTM --NRIND or an imputed or assigned value." +BNRIND,Baseline Reference Range Indicator,Char,,Perm,ANRIND of the baseline record identified by ABLFL. +ANRLO,"Analysis Normal +Range Lower Limit",Num *,,Perm,"Normal range lower limit for analysis; may be based on SDTM --NRLO or an imputed or assigned +value." +ANRLOC,Analysis Normal Range Lower Limit (C),Char,,Perm,"Character analysis normal range lower limit. ANRLOC can be a character string mapping to ANRLO, but if so there must be a one-to-one map between ANRLO and ANRLOC within a given PARAM. ANRLOC should not be used to categorize the values of ANRLO. Within a given parameter, if there exists a row on which both ANRLOC and ANRLO are populated, then there must be a one-to-one mapping between ANRLOC and ANRLO on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either ANRLO or ANRLOC be included when determining whether the one-to-one mapping +requirement is satisfied.) On a given record, it is permissible for ANRLO, ANRLOC, or both to be null." +ANRHI,"Analysis Normal +Range Upper Limit",Num *,,Perm,"Normal range upper limit for analysis; may be based on SDTM --NRHI or an imputed or assigned +value." +ANRHIC,Analysis Normal Range Upper Limit (C),Char,,Perm,"Character analysis normal range upper limit. ANRHIC can be a character string mapping to ANRHI, but if so there must be a one-to-one map between ANRHI and ANRHIC within a given PARAM. ANRHIC should not be used to categorize the values of ANRHI. Within a given parameter, if there exists a row on which both ANRHIC and ANRHI are populated, then there must be a one-to-one mapping between ANRHIC and ANRHI on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either ANRHI +or ANRHIC be included when determining whether the one-to-one mapping requirement is satisfied.) On a given record, it is permissible for ANRHI, ANRHIC, or both to be null." +AyLO,Analysis Range y Lower Limit,Num *,,Cond,"AyLO and/or AyHI are used for analysis ranges other than the normal range. AyLO and/or AyHI are created to capture the different levels of cutoff values used to determine whether an analysis is within a clinically acceptable value range or outside that value range. AyLO and/or AyHI are +usually but not necessarily constants, parameter-specific constants, or subject-specific constants. AyLO must be included if R2AyLO is included in the dataset." +AyLOC,Analysis Range y Lower Limit (C),Char,,Perm,"Character analysis range y lower limit. AyLOC can be a character string mapping to AyLO, but if so there must be a one-to-one map between AyLO and AyLOC within a given PARAM. AyLOC should not be used to categorize the values of AyLO. Within a given parameter, if there exists a row on which both AyLOC and AyLO are populated, then there must be a one-to-one mapping between AyLOC and AyLO on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AyLO or AyLOC be included when determining whether the one-to-one mapping requirement is satisfied.) On a given record, it is +permissible for AyLO, AyLOC, or both to be null." +AyHI,Analysis Range y Upper Limit,Num *,,Cond,"See AyLO. +For example, if ECG QTc values are summarized based on values >450, values >480, and values +>500, there is a need for 3 “hi value” range variables against which to compare values: A1HI=450, A2HI=480, A3HI=500. +AyHI must be included if R2AyHI is included in the dataset." +AyHIC,Analysis Range y Upper Limit (C),Char,,Perm,"Character analysis range y upper limit. AyHIC can be a character string mapping to AyHI, but if so there must be a one-to-one map between AyHI and AyHIC within a given PARAM. AyHIC should not be used to categorize the values of AyHI. Within a given parameter, if there exists a row on which both AyHIC and AyHI are populated, then there must be a one-to-one mapping between AyHIC and AyHI on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AyHI or AyHIC be included when determining +whether the one-to-one mapping requirement is satisfied.) On a given record, it is permissible for AyHI, AyHIC, or both to be null." +AyIND,"Analysis Range y +Indicator",Char,,Perm,"Indicates relationship of AVAL to the analysis range variables AyLO and/or AyHI, or the +relationship of AVALC to the analysis range variables AyLOC and/or AyHIC." +ByIND,"Baseline Analysis +Range y Indicator",Char,,Perm,AyIND of the baseline record identified by ABLFL. diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Dose_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Dose_Variables.csv new file mode 100644 index 0000000..b7bf289 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Dose_Variables.csv @@ -0,0 +1,4 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +DOSExxP,Planned Treatment Dose for Period xx,Num,,Perm,Subject-level identifier that represents the planned treatment dosage for period xx. +DOSExxA,Actual Treatment Dose for Period xx,Num,,Perm,Subject-level identifier that represents the actual treatment dosage for period xx. +DOSExxU,Units for Dose for Period xx,Char,,Perm,"The units for DOSExxP and DOSExxA. It is permissible to use suffixes such as ""P"" and ""A"" if needed, with labels modified accordingly." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Identifier_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Identifier_Variables.csv new file mode 100644 index 0000000..764aae4 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Identifier_Variables.csv @@ -0,0 +1,11 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +STUDYID,Study Identifier,Char,,Req,DM.STUDYID +USUBJID,Unique Subject Identifier,Char,,Req,DM.USUBJID +SUBJID,Subject Identifier for the Study,Char,,Req,"DM.SUBJID. SUBJID is required in ADSL, but permissible in other datasets." +SITEID,Study Site Identifier,Char,,Req,"DM.SITEID. SITEID is required in ADSL, but permissible in other datasets." +SITEGRy,Pooled Site Group y,Char,,Perm,"Character description of a grouping or pooling of clinical sites for analysis purposes. For example, SITEGR3 is the name of a variable containing site group (pooled site) names, where the grouping has been done according to the third site grouping algorithm, defined in variable metadata; SITEGR3 does not mean the third group of sites." +SITEGRyN,Pooled Site Group y (N),Num,,Perm,"Numeric representation of SITEGRy. There must be a one-to-one relationship between SITEGRyN and SITEGRy within a study. +SITEGRyN cannot be present unless SITEGRy is also present. When SITEGRy and SITEGRyN are present, then on a given record, either both must be populated or both must be null." +REGIONy,Geographic Region y,Char,,Perm,"Character description of geographical region. For example, REGION1 might have values of ""Asia"", ""Europe"", ""North America"", ""Rest of World""; REGION2 might have values of ""United States"", ""Rest of World""." +REGIONyN,Geographic Region y (N),Num,,Perm,"Numeric representation of REGIONy. Orders REGIONy for analysis and reporting.There must be a one-to-one relationship between REGIONyN and REGIONy within a study. +REGIONyN cannot be present unless REGIONy is also present. When REGIONy and REGIONyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Population_Indicator_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Population_Indicator_Variables.csv new file mode 100644 index 0000000..a3cc616 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Population_Indicator_Variables.csv @@ -0,0 +1,11 @@ +Variable Name,Variable Label,,Type,Codelist/ Controlled Terms,Core,CDISC Notes +FASFL,Full Analysis Set Population Flag,,Char,"Y, N",Cond,"These flags identify whether or not the subject is included in the specified population. A minimum of one subject-level population flag variable is required in ADSL. +Not all of the indicators listed here need to be included in ADSL. As stated in Section 3.1.4, Flag Variable Conventions, only those indicators corresponding to populations defined in the statistical analysis plan or populations used as a basis for analysis need be included in ADSL. +This list of flags is not meant to be all-inclusive. Additional population flags may be added. +The values of subject-level population flags cannot be blank. If a flag is used, the corresponding numeric version (*FN, where 0 = No and 1 = Yes) of the population flag can also be included. Please also refer to Section 3.1.4, Flag Variable Conventions." +SAFFL,Safety Population Flag,,Char,"Y, N",Cond, +ITTFL,Intent-To-Treat Population Flag,,Char,"Y, N",Cond, +PPROTFL,Per-Protocol Population Flag,,Char,"Y, N",Cond, +COMPLFL,Completers Population Flag,,Char,"Y, N",Cond, +RANDFL,Randomized Population Flag,,Char,"Y, N",Cond, +ENRLFL,Enrolled Population Flag,,Char,"Y, N",Cond, diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Stratification_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Stratification_Variables.csv new file mode 100644 index 0000000..d06ab7e --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Stratification_Variables.csv @@ -0,0 +1,18 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +STRATAR,Strata Used for Randomization,Char,,Perm,"STRATAR contains the combination of values of the individual stratification factors used for randomization. The exact format should be determined by the sponsor. This variable is intended for studies that use stratified randomization. +For example, "">=50, Treatment experienced, N""" +STRATARN,Strata Used for Randomization (N),Num,,Perm,"Numeric representation of STRATAR. For example, STRATARN=3 when STRATAR="">=50, Treatment experienced, N"". There must be a one-to-one relationship between STRATARN and STRATAR within a study. +STRATARN cannot be present unless STRATAR is also present. When STRATAR and STRATARN are present, then on a given record, either both must be populated or both must be null." +STRATwD,Description of Stratification Factor w,Char,,Perm,"STRATwD is a full text description of the stratification factor ""w"". This text description will remain constant for all subjects. These descriptive variables are included to quickly and clearly communicate critical study design information as well as to facilitate integration. +For example, STRAT3D=""Hypertension""" +STRATwR,Strat Factor w Value Used for Rand,Char,,Perm,"STRATwR is the subject-level value of the ""w'th"" stratification factor used for randomization. +For example, STRAT3R=""N""" +STRATwRN,Strat Factor w Value Used for Rand (N),Num,,Perm,"Numeric representation of STRATwR. For example, STRAT3RN=0 when STRAT3R=""N"". There must be a one-to-one relationship between STRATwRN and STRATwR within a study. +STRATwRN cannot be present unless STRATwR is also present. When STRATwR and STRATwRN are present, then on a given record, either both must be populated or both must be null." +STRATAV,Strata from Verification Source,Char,,Perm,"STRATAV contains the entire string value represents the combination of values of the individual stratification factors that should have been used and represents the ""as verified"" value. The STRATAV variables are based on the source documentation and are determined after randomization. If the values used for the randomization of a given subject were all correct, then STRATAV will equal STRATAR. Otherwise, one or more components of the text string for STRATAR and STRATAV will be different. +The exact format should be determined by the sponsor. For example, "">=50, Treatment experienced, Y""" +STRATAVN,Strata from Verification Source (N),Num,,Perm,"Numeric representation of STRATAV. For example, STRATAVN=4 when STRATVR="">=50, Treatment experienced, Y"". There must be a one-to-one relationship between STRATAVN and STRATAV within a study. +STRATAVN cannot be present unless STRATAV is also present. When STRATAV and STRATAVN are present, then on a given record, either both must be populated or both must be null." +STRATwV,Strat Factor w Value from Verif Source,Char,,Perm,"STRATwV is the ""as verified"" subject-level value of the ""w'th"" stratification factor. If the value based on randomization was correct, then STRATwV will equal STRATwR. For example, STRAT3V=""Y""" +STRATwVN,Strat Fact w Val from Verif Source (N),Num,,Perm,"Numeric representation of STRATwV. For example, STRAT3VN=1 when STRAT3V=""Y"". There must be a one-to-one relationship between STRATwVN and STRATwV within a study. +STRATwVN cannot be present unless STRATwV is also present. When STRATwV and STRATwVN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Subject_Demographics_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Subject_Demographics_Variables.csv new file mode 100644 index 0000000..1a26ac3 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Subject_Demographics_Variables.csv @@ -0,0 +1,12 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +AGE,Age,Num,,Req,"DM.AGE. If analysis needs require a derived age that does not match DM.AGE, then AAGE must be added" +AGEU,Age Units,Char,(AGEU),Req,DM.AGEU +AGEGRy,Pooled Age Group y,Char,,Perm,"Character description of a grouping or pooling of the subject's age for analysis purposes. For example, AGEGR1 might have values of ""<18"", ""18-65"", and "">65""; AGEGR2 might have values of ""Less than 35 y old"" and ""At least 35 y old""." +AGEGRyN,Pooled Age Group y (N),Num,,Perm,"Numeric representation of AGEGRy. Orders the grouping or pooling of subject age for analysis and reporting. There must be a one-to-one relationship between AGEGRyN and AGEGRy within a study. +AGEGRyN cannot be present unless AGEGRy is also present. When AGEGRy and AGEGRyN are present, then on a given record, either both must be populated or both must be null." +AAGE,Analysis Age,Num,,Cond,Age used for analysis that may be derived differently than DM.AGE. AAGE is required if age is calculated differently than DM.AGE. +SEX,Sex,Char,(SEX),Req,DM.SEX. +RACE,Race,Char,(RACE),Req,DM.RACE. +RACEGRy,Pooled Race Group y,Char,,Perm,Character description of a grouping or pooling of the subject's race for analysis purposes. +RACEGRyN,Pooled Race Group y (N),Num,,Perm,"Numeric representation of RACEGRy. Orders the grouping or pooling of subject race for analysis and reporting. There must be a one-to-one relationship between RACEGRyN and RACEGRy within a study. +RACEGRyN cannot be present unless RACEGRy is also present. When RACEGRy and RACEGRyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Subject_Level_Trial_Experience_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Subject_Level_Trial_Experience_Variables.csv new file mode 100644 index 0000000..a31a1be --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Subject_Level_Trial_Experience_Variables.csv @@ -0,0 +1,38 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +EOSSTT,End of Study Status,Char,(SBJTSTAT),Perm,"The subject's status as of the end of study or data cutoff. Examples: COMPLETED, DISCONTINUED, ONGOING." +EOSDT,End of Study Date,Num,,Perm,Date subject ended the study - either date of completion or date of discontinuation or data cutoff date for interim analyses. +DCSREAS,Reason for Discontinuation from Study,Char,,Perm,Reason for subject's discontinuation from study. The source would most likely be the SDTM DS dataset. Null for subjects who completed the study. +DCSREASP,Reason Spec for Discont from Study,Char,,Perm,"Additional detail regarding subject's discontinuation from study (e.g., description of ""other"")." +EOTSTT,End of Treatment Status,Char,(SBJTSTAT),Perm,"The subject's status as of the end of treatment or data cutoff. Examples: COMPLETED, DISCONTINUED, ONGOING." +DCTREAS,Reason for Discontinuation of Treatment,Char,,Perm,"If a subject discontinued treatment in the study, then this variable indicates the reason for discontinuation. This is for discontinuation of treatment in the overall study and not to be used for discontinuation reason within individual treatment periods." +DCTREASP,Reason Specify for Discont of Treatment,Char,,Perm,"Additional detail regarding subject's discontinuation from treatment (e.g., description of ""other"")." +EOTxxSTT,End of Treatment Status in Period xx,Char,(SBJTSTAT),Perm,"The subject's treatment status as of the end of period xx, or data cutoff if within period xx. Examples: COMPLETED, DISCONTINUED, ONGOING." +DCTxxRS,Reason for Discont of Treat in Period xx,Char,,Perm,Reason for discontinuing treatment in period xx. +DCTxxRSP,Reason Spec for Disc of Trt in Period xx,Char,,Perm,"Additional detail regarding subject's discontinuation of treatment in period xx (e.g., description of ""other"")." +EOPxxSTT,End of Period xx Status,Char,(SBJTSTAT),Perm,"The subject's status as of the end of period xx, or data cutoff if within period xx. Examples: COMPLETED, DISCONTINUED, ONGOING." +DCPxxRS,Reason for Discont from Period xx,Char,,Perm,Reason for discontinuing analysis period xx. +DCPxxRSP,Reason Spec for Discont from Period xx,Char,,Perm,"Additional detail regarding subject's discontinuation from period xx (e.g., description of ""other"")." +RFICDT,Date of Informed Consent,Num,,Perm,Date subject gave informed consent. Generally equivalent to DM.RFICDTC. +ENRLDT,Date of Enrollment,Num,,Perm,Date of subject's enrollment into trial. +RANDDT,Date of Randomization,Num,,Cond,Required in randomized trials. +RFICyDT,Date of Informed Consent y,Num,,Perm,"This variable may be used in the case where there are multiple consent dates within a study. This date does not need to repeat the date in RFICDT. ""y"" can start with 1 but it is not required to start with 1." +ENRLyDT,Date of Enrollment y,Num,,Perm,"This variable may be used in the case where there are multiple enrollment dates within a study. This date does not need to repeat the date in ENRLDT. ""y"" can start with 1 but it is not required to start with 1." +RANDyDT,Date of Randomization y,Num,,Perm,"This variable may be used in the case where there are multiple randomization dates within a study. This date does not need to repeat the date in RANDDT. ""y"" can start with 1 but it is not required to start with 1." +LSTALVDT,Date Last Known Alive,Num,,Perm,"If this variable is included in ADSL, the best practice is to populate it for everyone. If the derivation for subjects who died differs from the derivation for subjects who are not known to have died, the differences should be noted in metadata." +TRCMP,Treatment Compliance (%),Num,,Perm,Overall percent compliance with treatment in the trial. TRCMP may be useful for inclusion in ADSL for reasons such as defining subgroups and/or populations. +TRCMPGy,Treatment Compliance (%) Group y,Char,,Perm,"Grouping ""y"" of TRCMP, treatment compliance percentage." +TRCMPGyN,Treatment Compliance (%) Group y (N),Num,,Perm,"Numeric representation of treatment compliance (%) grouping ""y"". There must be a one-to-one relationship between TRCMPGyN and TRCMPGy within a study. +TRCMPGyN cannot be present unless TRCMPGy is also present. When TRCMPGy and TRCMPGyN are present, then on a given record, either both must be populated or both must be null." +TRxxDURD,Treatment Duration in Period xx (Days),Num,,Perm,"Treatment duration for period xx as measured in days. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its respective units." +TRxxDURM,Treatment Duration in Period xx (Months),Num,,Perm,"Treatment duration for period xx, as measure in months. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its respective units." +TRxxDURY,Treatment Duration in Period xx (Years),Num,,Perm,"Treatment duration for period xx, as measured in years. More than one of TRxxDURD, TRxxDURM, and TRxxDURY can be populated, but each represents the entire duration in its respective units." +TRTDURD,Total Treatment Duration (Days),Num,,Perm,"Total treatment duration, as measured in days. More than one of TRTDURD, TRTDURM, and TRTDURY can be populated, but each represents the entire duration in its respective units." +TRTDURM,Total Treatment Duration (Months),Num,,Perm,"Total treatment duration, as measured in months. More than one of TRTDURD, TRTDURM, and TRTDURY can be populated, but each represents the entire duration in its respective units." +TRTDURY,Total Treatment Duration (Years),Num,,Perm,"Total treatment duration, as measured in years. More than one of TRTDURD, TRTDURM, and TRTDURY can be populated, but each represents the entire duration in its respective units." +DTHDT,Date of Death,Num,,Perm,Date of subject's death. Derived from DM.DTHDTC. +DTHDTF,Date of Death Imputation Flag,Char,(DATEFL),Cond,"Imputation flag for date of subject's death. If DTHDT was imputed, DTHDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +DTHCAUS,Cause of Death,Char,,Perm,Cause of Death. +DTHCAUSN,Cause of Death (N),Num,,Perm,"Numeric representation of cause of death. There must be a one-to-one relationship between DTHCAUSN and DTHCAUS within a study. DTHCAUSN cannot be present unless DTHCAUS is also present. When DTHCAUS and DTHCAUSN are present, then on a given record, either both must be populated or both must be null." +DTHCGRy,Cause of Death Group y,Char,,Perm,"Grouping ""y"" of DTHCAUS, the subject's cause of death." +DTHCGRyN,Cause of Death Group y (N),Num,,Perm,"Numeric representation of grouping ""y"" of the subject's cause of death. There must be a one-to-one relationship between DTHCGRyN and DTHCGRy within a study. +DTHCGyN cannot be present unless DTHCGy is also present. When DTHCGy and DTHCGyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Timing_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Timing_Variables.csv new file mode 100644 index 0000000..6a997d6 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Timing_Variables.csv @@ -0,0 +1,22 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +TRTSDT,Date of First Exposure to Treatment,Num,,Cond,"Date of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. Note that TRTSDT is not required to have the same value as the SDTM DM variable RFXSTDTC. While both of these dates reflect the concept of first exposure, the ADaM date may be derived to support the analysis which may not necessarily +be the very first date in the SDTM EX domain." +TRTSTM,Time of First Exposure to Treatment,Num,,Perm,Time of first exposure to treatment for a subject in a study. +TRTSDTM,Datetime of First Exposure to Treatment,Num,,Cond,Datetime of first exposure to treatment for a subject in a study. TRTSDT and/or TRTSDTM are required if there is an investigational product. +TRTSDTF,Date of First Exposure Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of date of first exposure to treatment. If TRTSDT (or the date part of TRTSDTM) was imputed, TRTSDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRTSTMF,Time of First Exposure Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of time of first exposure to treatment. If TRTSTM (or the time part of TRTSDTM) was imputed, TRTSTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRTEDT,Date of Last Exposure to Treatment,Num,,Cond,"Date of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. Note that TRTEDT is not required to have the same value as the SDTM DM variable RFXENDTC. While both of these dates reflect the concept of last exposure, the ADaM date may be derived to support the analysis which may not necessarily be the very last date in the SDTM EX domain." +TRTETM,Time of Last Exposure to Treatment,Num,,Perm,Time of last exposure to treatment for a subject in a study. +TRTEDTM,Datetime of Last Exposure to Treatment,Num,,Cond,Datetime of last exposure to treatment for a subject in a study. TRTEDT and/or TRTEDTM are required if there is an investigational product. +TRTEDTF,Date of Last Exposure Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of date of last exposure to treatment. If TRTEDT (or the date part of TRTEDTM) was imputed, TRTEDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRTETMF,Time of Last Exposure Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of time of last exposure to treatment. If TRTETM (or the time part of TRTEDTM) was imputed, TRTETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRxxSDT,Date of First Exposure in Period xx,Num,,Cond,"Date of first exposure to treatment in period xx. TRxxSDT and/or TRxxSDTM are only required in trial designs where multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P). Examples include crossover designs or designs where multiple periods exist for the same treatment." +TRxxSTM,Time of First Exposure in Period xx,Num,,Cond,"Starting time of exposure to treatment in period xx. TRxxSTM and/or TRxxSDTM are only required in trial designs where starting time is important to the analysis and multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P)." +TRxxSDTM,Datetime of First Exposure in Period xx,Num,,Cond,"Datetime of first exposure to treatment in period xx. TRxxSDTM is only required in trial designs where multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P)." +TRxxSDTF,Date 1st Exposure Period xx Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of date of first exposure to treatment in period xx. If TRxxSDT (or the date part of TRxxSDTM) was imputed, TRxxSDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRxxSTMF,Time 1st Exposure Period xx Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of time of first exposure to treatment in period xx. If TRxxSTM (or the time part of TRxxSDTM) was imputed, TRxxSTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRxxEDT,Date of Last Exposure in Period xx,Num,,Cond,"Date of last exposure to treatment in period xx. TRxxEDT and/or TRxxEDTM are only required in trial designs where multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P)." +TRxxETM,Time of Last Exposure in Period xx,Num,,Cond,"Ending time of exposure to treatment in period xx. TRxxETM and/or TRxxEDTM are only required in trial designs where ending time is important to the analysis and multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P)." +TRxxEDTM,Datetime of Last Exposure in Period xx,Num,,Cond,"Datetime of last exposure to treatment in period xx. TRxxEDTM is only required in trial designs where multiple treatment periods are defined (i.e., required when there is a TRTxxP other than TRT01P)." +TRxxEDTF,Date Last Exposure Period xx Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of date of last exposure to treatment in period xx. If TRxxEDT (or the date part of TRxxEDTM) was imputed, TRxxEDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +TRxxETMF,Time Last Exposure Period xx Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of time of last exposure to treatment in period xx. If TRxxETM (or the time part of TRxxEDTM) was imputed, TRxxETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." diff --git a/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Variables.csv b/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Variables.csv new file mode 100644 index 0000000..b5be374 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/ADSL_Treatment_Variables.csv @@ -0,0 +1,27 @@ +Variable Name,,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ARM,,Description of Planned Arm,Char,,Req,DM.ARM +ACTARM,,Description of Actual Arm,Char,,Perm,DM.ACTARM +TRTxxP,,Planned Treatment for Period xx,Char,,Req,"Subject-level identifier that represents the planned treatment for period xx. In a one-period randomized trial, TRT01P would be the treatment to which the subject was randomized. TRTxxP might be derived from the SDTM DM variable ARM. At least TRT01P is required." +TRTxxPN,,Planned Treatment for Period xx (N),Num,,Perm,"Numeric representation of TRTxxP. There must be a one- to-one relationship between TRTxxPN and TRTxxP within a study. +TRTxxPN cannot be present unless TRTxxP is also present. When TRTxxP and TRTxxPN are present, then on a given record, either both must be populated or both must be null." +TRTxxA,,Actual Treatment for Period xx,Char,,Cond,Subject-level identifier that represents the actual treatment for the subject for period xx. Required when actual treatment does not match planned and there is an analysis of the data as treated. +TRTxxAN,,Actual Treatment for Period xx (N),Num,,Perm,"Numeric representation of TRTxxA. There must be a +one-to-one relationship between TRTxxAN and TRTxxA within a study. TRTxxAN cannot be present unless TRTxxA is also present. When TRTxxA and TRTxxAN are present, then on a given record, either both must be populated or both must be null." +TRTSEQP,,Planned Sequence of Treatments,Char,,Cond,"Required when there is an analysis based on the sequence of treatments, for example in a crossover design. +TRTSEQP is not necessarily equal to ARM, for example if ARM contains elements that are not relevant to analysis of treatments or ARM is not fully descriptive (e.g., ""GROUP 1,"" ""GROUP 2""). When analyzing based on the sequence of treatments, TRTSEQP is required even if identical to ARM." +TRTSEQPN,,Planned Sequence of Treatments (N),Num,,Perm,"Numeric representation of TRTSEQP. There must be a one-to-one relationship between TRTSEQPN and TRTSEQP within a study. +TRTSEQPN cannot be present unless TRTSEQP is also present. When TRTSEQP and TRTSEQPN are present, then on a given record, either both must be populated or both must be null." +TRTSEQA,,Actual Sequence of Treatments,Char,,Cond,TRTSEQA is required if a situation occurred in the conduct of the trial where a subject received a sequence of treatments other than what was planned and there is an analysis based on the sequence of treatments. +TRTSEQAN,,Actual Sequence of Treatments (N),Num,,Perm,"Numeric representation of TRTSEQA. There must be a one-to-one relationship between TRTSEQAN and TRTSEQA within a study. +TRTSEQAN cannot be present unless TRTSEQA is also present. When TRTSEQA and TRTSEQAN are present, then on a given record, either both must be populated or both must be null." +TRxxPGy,,Planned Pooled Treatment y for Period xx,Char,,Perm,"Planned pooled treatment y for period xx. Useful when planned treatments (TRTxxP) in the specified period xx are pooled together for analysis according to pooling algorithm y. For example when in period 2 the first pooling algorithm dictates that all doses of Drug A (TR02PG1=""All doses of Drug A"") are pooled together for comparison to all doses of Drug B (TR02PG1=""All doses of Drug B""). Each value of TRTxxP is pooled within at most one value of TRxxPGy." +TRxxPGyN,,Planned Pooled Trt y for Period xx (N),Num,,Perm,"Numeric representation of TRxxPGy. There must be a one-to-one relationship between TRxxPGyN and TRxxPGy within a study. +TRxxPGyN cannot be present unless TRxxPGy is also present. When TRxxPGy and TRxxPGyN are present, then on a given record, either both must be populated or both must be null." +TRxxAGy,,Actual Pooled Treatment y for Period xx,Char,,Cond,Actual pooled treatment y for period xx. Required when TRxxPGy is present and TRTxxA is present. +TRxxAGyN,,Actual Pooled Trt y for Period xx (N),Num,,Perm,"Numeric representation of TRxxAGy. There must be a one-to-one relationship between TRxxAGyN and TRxxAGy within a study. TRxxAGyN cannot be present unless TRxxAGy is also present. When TRxxAGy and TRxxAGyN are present, then on a given record, either both must be populated or both must be null." +TSEQPGy,,Planned Pooled Treatment Sequence y,Char,,Perm,"Planned pooled treatment sequence y. Useful when planned treatment sequences (TRTSEQP) are pooled together for analysis according to pooling algorithm y. For example, this might be used in an analysis of an extension study when the analysis is based on what the subject received in the parent study as well as in the extension study." +TSEQPGyN,,Planned Pooled Treatment Sequence y (N),Num,,Perm,"Numeric representation of TSEQPGy. There must be a one-to-one relationship between TSEQPGyN and TSEQPGy within a study. +TSEQPGyN cannot be present unless TSEQPGy is also present. When TSEQPGy and TSEQPGyN are present, then on a given record, either both must be populated or both must be null." +TSEQAGy,,Actual Pooled Treatment Sequence y,Char,,Cond,Actual pooled treatment sequence y. Required when TSEQPGy is present and TRTSEQA is present. +TSEQAGyN,,Actual Pooled Treatment Sequence y (N),Num,,Perm,"Numeric representation of TSEQAGy. There must be a one-to-one relationship between TSEQAGyN and TSEQAGy within a study. +TSEQAGyN cannot be present unless TSEQAGy is also present. When TSEQAGy and TSEQAGyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/Analysis_Descriptor_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Analysis_Descriptor_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..22930fe --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Analysis_Descriptor_Variables_BDS_Datasets.csv @@ -0,0 +1,11 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +DTYPE,Derivation Type,Char,(DTYPE),Cond,"Analysis value derivation method. DTYPE is used to denote, and must be populated, when the value of AVAL or AVALC has been imputed or derived differently than the other analysis values within the parameter. DTYPE is required to be populated even if AVAL and AVALC are null on the derived record. +Three common situations when DTYPE should be populated: +? A new row is added within a parameter with the analysis value populated based on other rows within the parameter. +? A new row is added within a parameter with the analysis value populated based on a constant value or data from other subjects. +? An analysis value (AVAL or AVALC) on an existing record is being replaced with a value based on a pre- specified algorithm. +DTYPE is used to denote analysis values that are ""special cases"" within a parameter. For each value of DTYPE, the precise derivation algorithm must be defined in analysis variable metadata, even for DTYPE values in the CDISC Controlled Terminology. The controlled terminology for DTYPE is extensible. See Section 4, Implementation Issues, Standard Solutions, and Examples for examples of the use of DTYPE. +Some examples of DTYPE values: +? LOCF = last observation carried forward. +? WOCF = worst observation carried forward. +? AVERAGE = average of values." diff --git a/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..bb4ce66 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Criteria_Variables_BDS_Datasets.csv @@ -0,0 +1,12 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +CRITy,Analysis Criterion y,Char,,Perm,"A text string identifying a pre-specified criterion within a parameter, for example SYSBP > 90. Required if CRITyFL is present. In some cases, the presence of the text string indicates that the criterion is satisfied on this record and CRITyFL is set to Y, while a null value indicates that the criterion is not satisfied or is not evaluable and is accompanied by a null value in CRITyFL. In other cases, the text string identifies the criterion being evaluated and is populated on every row for the parameter, but whether or not the criterion is satisfied is indicated by the value of the variable CRITyFL. See CRITyFL and CRITyFN. +Refer to Section 4.7, Identification of Records which Satisfy a Predefined Criterion for Analysis Purposes, for additional discussion of CRITy, CRITyFL and CRITyFN." +CRITyFL,Criterion y Evaluation Result Flag,Char,"Y or Y, N",Cond,"Character flag variable indicating whether the criterion defined in CRITy was met by the data on the record. See CRITy for more information regarding how to use CRITy and CRITyFL to indicate whether a criterion is met. Required if CRITy is present. +Refer to Section 4.7, Identification of Records which Satisfy a Predefined Criterion for Analysis Purposes, for additional discussion." +CRITyFN,Criterion y Evaluation Result Flag (N),Num,"1 or 1, 0",Perm,"Numeric representation of CRITyFL. There must be a one-to-one relationship between CRITyFN and CRITyFL within a parameter. CRITyFN cannot be present unless CRITyFL is also present. When CRITyFL and CRITyFN are present, then on a given record, either +both must be populated or both must be null." +MCRITy,Analysis Multi- Response Criterion y,Char,,Perm,"A text string identifying a pre-specified criterion within a parameter, where the criterion can have multiple responses (as opposed to CRITy which has binary responses). Required if MCRITyML is present. For example, the grade of a lab analyte is compared to the baseline grade, with the possible conditions being 0 to 1, 0 to 2, etc. The text string identifies the criterion being evaluated (for example, ""Grade increase"") and is populated on every row for the parameter; which level of the criterion is satisfied is indicated by the value of the variable MCRITyML (for example ""0 to 1"", ""0 to 2"", etc.). +See MCRITyML and MCRITyMN below, and refer to Section 4.7, Identification of Records which Satisfy a Predefined Criterion for Analysis Purposes, for additional discussion of MCRITy, MCRITyML, and MCRITyMN." +MCRITyML,Multi- Response Criterion y Evaluation,Char,,Cond,Character variable indicating which level of the criterion defined in MCRITy was met by the data on the record. See MCRITy for more information regarding how to use MCRITy and MCRITyML to indicate whether a criterion was met. Content is sponsor-defined. Required if MCRITy is present. +MCRITyMN,Multi- Response Criterion y Eval (N),Num,,Perm,"Numeric representation of MCRITyML. There must be a one-to-one relationship between MCRITyMN and MCRITyML within a parameter. Content is sponsor-defined. +MCRITyMN cannot be present unless MCRITyML is also present. When MCRITyML and MCRITyMN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Variables.csv b/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Variables.csv new file mode 100644 index 0000000..9b40752 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Analysis_Parameter_Variables.csv @@ -0,0 +1,49 @@ +Variable Name,,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +PARAM,,Parameter,Char,,Req,"The description of the analysis parameter. PARAM must include all descriptive and qualifying information relevant to the analysis purpose of the parameter. +Some examples are: ""Supine Systolic Blood Pressure (mm Hg)"", ""Log10 (Weight (kg))"", ""Time to First Hypertension Event (Days)"", and ""Estimated Tumor Growth Rate"". PARAM should be sufficient to describe unambiguously the contents of AVAL and/or AVALC. +Examples of qualifying information that might be relevant to analysis, and are therefore candidates for inclusion in PARAM, are units, specimen type, location, position, machine type, and transformation function. There is no need to include qualifiers that are not relevant to the analysis of PARAM. In contrast to SDTM -- TEST, no additional variable is needed to further qualify PARAM. PARAM is restricted to a maximum of 200 characters. If the value of PARAM will be used as a variable label in a transposed dataset, +then the producer may wish to limit the value of PARAM to 40 characters. Such limitation to 40 characters should not compromise the integrity of the description. +PARAM is often directly usable in Clinical Study Report displays. Note that in the ADaMIG, ""parameter"" is a synonym of ""analysis parameter."" +PARAM must be present and populated on every record in a BDS dataset." +PARAMCD,,Parameter Code,Char,,Req,"The short name of the analysis parameter in PARAM. The values of PARAMCD must be no more than 8 characters in length, start with a letter (not underscore), and be comprised only of letters (A-Z), underscore (_), and numerals (0-9). These constraints will allow for a BDS dataset to be transposed in such a way that the values of PARAMCD can be used as valid ADaM variable names per Section 3.1.1, General Variable Conventions. There must be a one-to-one relationship between PARAM and PARAMCD within a dataset. +PARAMCD must be present and populated on every record in a BDS dataset." +PARAMN,,Parameter (N),Num,,Perm,"Numeric representation of PARAM. Useful for ordering and programmatic manipulation. There must be a one-to-one relationship between PARAM and PARAMN within a dataset for all parameters where PARAMN is populated. +if PARAMN is populated on any record for a PARAM, it must be populated on every record for that PARAM." +PARCATy,,Parameter Category y,Char,,Perm,"A categorization of PARAM within a dataset. For example, values of PARCAT1 might group the parameters having to do with a particular questionnaire, lab specimen type, or area of investigation. Note that PARCATy is not a qualifier for PARAM. PARAM to PARCATy is a many-to-one mapping; any given PARAM may be associated with at most one level of PARCATy (e.g., one level of PARCAT1 and one level of PARCAT2)." +PARCATyN,,Parameter Category y (N),Num,,Perm,"Numeric representation of PARCATy. Useful for the ordering of values of PARCATy or for other purposes. There must be a one-to- one relationship between PARCATy and PARCATyN within a dataset. +PARCATyN cannot be present unless PARCATy is also present. When PARCATy and PARCATyN are present, then on a given record, either both must be populated or both must be null." +AVAL,,Analysis Value,Num,,Cond,"Numeric analysis value described by PARAM. On a given record, it is permissible for AVAL, AVALC, or both to be null. AVAL is required if AVALC is not present, since either AVAL or AVALC must be present in the dataset." +AVALC,,Analysis Value (C),Char,,Cond,"Character analysis value described by PARAM. AVALC can be a character string mapping to AVAL, but if so there must be a one-to- one relationship between AVAL and AVALC within a given PARAM. AVALC should not be used to categorize the values of AVAL. Within a given parameter, if there exists a row on which both AVALC and AVAL are populated, then there must be a one-to- one relationship between AVALC and AVAL on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AVAL or AVALC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for AVAL, AVALC, or both to be null. +AVALC is required if AVAL is not present, since either AVAL or AVALC must be present in the dataset." +AVALCATy,,Analysis Value Category y,Char,,Perm,"A categorization of AVAL or AVALC within a parameter. Not necessarily a one-to-one mapping to AVAL and/or AVALC. For example, if PARAM is ""Headache Severity"" and AVAL has values 0, 1, 2, or 3, AVALCAT1 can categorize AVAL into ""None or Mild"" (for AVAL 0 or 1) and ""Moderate or Severe"" (for AVAL 2 or 3). AVALCATy is parameter variant." +AVALCAyN,,Analysis Value Category y (N),Num,,Perm,"Numeric representation of AVALCATy. Useful for ordering of values of AVALCATy or for other purposes. There must be a one- to-one relationship between AVALCAyN and AVALCATy within a parameter. +AVALCAyN cannot be present unless AVALCATy is also present. When AVALCATy and AVALCAyN are present, then on a given record, either both must be populated or both must be null." +BASE,,Baseline Value,Num,,Cond,"The subject's baseline analysis value for a parameter and baseline definition (i.e., BASETYPE) if present. BASE contains the value of AVAL copied from a record within the parameter on which ABLFL += ""Y"". Required if dataset supports analysis or review of numeric baseline value or functions of numeric baseline value. If BASE is populated for a parameter, and BASE is non-null for a subject for that parameter, then there must be a record flagged by ABLFL for that subject and parameter. Note that a baseline record may be derived (e.g., it may be an average) in which case DTYPE must be populated on the baseline record." +BASEC,,Baseline Value (C),Char,,Perm,"The subject's baseline value of AVALC for a parameter and baseline definition (i.e., BASETYPE) if present. May be needed when AVALC is of interest. BASEC contains the value of AVALC copied from a record within the parameter on which ABLFL = ""Y"". If both AVAL and AVALC are populated within a parameter, the baseline record for AVALC must be the same record as that for AVAL. +Within a given parameter, if there exists a row on which both BASEC and BASE are populated, then there must be a one-to-one relationship between BASEC and BASE on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either BASE or BASEC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for BASE, BASEC, or both to be null." +BASECATy,,Baseline Category y,Char,,Perm,"A categorization of BASE or BASEC within a parameter. Not necessarily a one-to-one mapping to BASE or BASEC. For example, if PARAM is ""Headache Severity"" and AVAL has values 0, 1, 2, or 3, BASECAT1 can categorize BASE into ""None or Mild"" (for BASE 0 or 1) and ""Moderate or Severe"" (for BASE 2 or 3)." +BASECAyN,,Baseline Category y (N),Num,,Perm,"Numeric representation of BASECATy. Useful for ordering of values of BASECATy or for other purposes. There must be a one-to- one relationship between BASECAyN and BASECATy within a parameter. BASECAyN cannot be present unless BASECATy is also present. When BASECATy and BASECAyN are present, then on a given record, either both must be populated or both must be null." +BASETYPE,,Baseline Type,Char,,Cond,"Producer-defined text describing the definition of baseline relevant to the value of BASE on the current record. Required when there are multiple ways that baseline is defined. If used for any PARAM within a dataset, should be non-null for all records for that PARAM within that dataset. Refer to Section 4.2.1.6, Rule 6, for an example." +CHG,,Change from Baseline,Num,,Perm,"Change from baseline analysis value. Equal to AVAL-BASE. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of CHG is left to producer choice." +CHGCATy,,Change from Baseline Category y,Char,,Perm,"A categorization of CHG within a parameter. Not necessarily a one- to-one mapping to CHG. The definition of CHGCATy may vary by PARAM. For example, CHGCAT1 may be used to categorize CHG with respect to ranges of change in SYSBP; ""-10 to -5 mm Hg"", ""-5 to 0 mm Hg"" categories." +CHGCATyN,,Change from Baseline Category y (N),Num,,Perm,"Numeric representation of CHGCATy. Useful for ordering of values of CHGCATy or for other purposes. There must be a one-to-one relationship between CHGCATyN and CHGCATy within a parameter. +CHGCATyN cannot be present unless CHGCATy is also present. When CHGCATy and CHGCATyN are present, then on a given record, either both must be populated or both must be null." +PCHG,,Percent Change from Baseline,Num,,Perm,"Percent change from baseline analysis value. Equal to ((AVAL- BASE)/BASE)*100. If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of PCHG is left to producer choice." +PCHGCATy,,Percent Chg from Baseline Category y,Char,,Perm,"A categorization of PCHG within a parameter. Not necessarily a one-to-one mapping to PCHG. The definition of PCHGCATy may vary by PARAM. For example, PCHGCAT1 may be used to categorize PCHG with respect to ranges of change in SYSBP; "">5%"", "">10%"" categories." +PCHGCAyN,,Percent Chg from Baseline Category y (N),Num,,Perm,"Numeric representation of PCHGCATy. Useful for ordering of values of PCHGCATy or for other purposes. There must be a one- to-one relationship between PCHGCAyN and PCHGCATy within a parameter. +PCHGCAyN cannot be present unless PCHGCATy is also present. When PCHGCATy and PCHGCAyN are present, then on a given record, either both must be populated or both must be null." +R2BASE,,Ratio to Baseline,Num,,Perm,"Ratio to the baseline value. Equal to AVAL / BASE. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of R2BASE is left to producer choice." +R2AyLO,,Ratio to Analysis Range y Lower Limit,Num,,Perm,"Ratio to the lower limit of the analysis range y. Equal to AVAL / AyLO. AyLO must exist in the ADaM dataset. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of R2AyLO is left to producer choice." +R2AyHI,,Ratio to Analysis Range y Upper Limit,Num,,Perm,"Ratio to the upper limit of the analysis range y. Equal to AVAL / AyHI. AyHI must exist in the ADaM dataset. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of R2AyHI is left to producer choice." +SHIFTy,,Shift y,Char,,Perm,"A shift in values depending on the defined pairing for group y within a parameter. SHIFTy can only be based on the change in value of any of the following pairs (BASECATy, AVALCATy), (BNRIND, ANRIND), (ByIND, AyIND), (BTOXGR, ATOXGR), (BTOXGRL, ATOXGRL), (BTOXGRH, ATOXGRH), (BASE, AVAL) or +(BASEC, AVALC). Useful for shift tables. For example, ""NORMAL to HIGH"". If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate baseline and pre-baseline values of SHIFTy is left to producer choice." +SHIFTyN,,Shift y (N),Num,,Perm,"Numeric representation of SHIFTy. There must be a one-to-one relationship between SHIFTyN and SHIFTy within a parameter.SHIFTyN cannot be present unless SHIFTy is also present. When SHIFTy and SHIFTyN are present, then on a given record, either both must be populated or both must be null.If SHIFTyN is used for a given PARAM, SHIFTy and SHIFTyN should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis." +BCHG,,Change to Baseline,Num,,Perm,"Change to baseline analysis value. Equal to BASE-AVAL. If used for a given PARAM, should be populated for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of BCHG is left to producer choice." +BCHGCATy,,Change to Baseline Category y,Char,,Perm,"A categorization of BCHG within a parameter. Not necessarily a one-to-one mapping to BCHG. The definition of BCHGCATy may vary by PARAM. For example, BCHGCAT1 may be used to categorize BCHG with respect to ranges of change in SYSBP; ""-10 to -5 mm Hg"", ""-5 to 0 mm Hg"" categories." +BCHGCAyN,,Change to Baseline Category y (N),Num,,Perm,"Numeric representation of BCHGCATy. Useful for ordering of values of BCHGCATy or for other purposes. There must be a one- to-one relationship between BCHGCAyN and BCHGCATy within a parameter. +BCHGCAyN cannot be present unless BCHGCATy is also present. When BCHGCATy and BCHGCAyN are present, then on a given record, either both must be populated or both must be null." +PBCHG,,Percent Change to Baseline,Num,,Perm,"Percent change to baseline analysis value. Equal to ((BASE- AVAL)/AVAL)*100. If used for a given PARAM, should be populated (when calculable) for all post-baseline records of that PARAM regardless of whether that record is used for analysis. The decision on how to populate pre-baseline and baseline values of PBCHG is left to producer choice" +PBCHGCAy,,Percent Change to Baseline Category y,Char,,Perm,"A categorization of PBCHG within a parameter. Not necessarily a one-to-one mapping to PBCHG. The definition of PBCHGCAy may vary by PARAM. For example, PBCHGCA1 may be used to categorize PBCHG with respect to ranges of change in SYSBP; "">5%"", "">10%"" categories." +PBCHGCyN,,Percent Change to Baseline Category y (N),Num,,Perm,"Numeric representation of PBCHGCAy. Useful for ordering of values of PBCHGCAy or for other purposes. There must be a one- to-one relationship between PBCHGCyN and PBCHGCAy within a parameter. +PBCHGCyN cannot be present unless PBCHGCAy is also present. When PBCHGCAy and PBCHGCyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..194c59b --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Analysis_Visit_Windowing_Variables_BDS_Datasets.csv @@ -0,0 +1,8 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +AWRANGE,Analysis Window Valid Relative Range,Char,,Perm,"The range of values that are valid for a given analysis timepoint (a given value of AVISIT). For example, ""5-9 DAYS""." +AWTARGET,Analysis Window Target,Num,,Perm,The target or most desired analysis relative day (ADY) value or analysis relative time (ARELTM) value for a given value of AVISIT. +AWTDIFF,Analysis Window Diff from Target,Num,,Perm,"Absolute difference between ADY or ARELTM and AWTARGET. It will be necessary to adjust for the fact that there is no Day 0 in the event that ADY and AWTARGET are not of the same sign. +If the sign of the difference is important, then AWTDIFF might have to be used in conjunction with ADY or ARELTM and possibly AWTARGET when choosing among records." +AWLO,Analysis Window Beginning Timepoint,Num,,Perm,"The value of the beginning timepoint (inclusive) needs to be used in conjunction to AWRANGE. For example, if AWRANGE is ""5-9 DAYS"", then AWLO is ""5""." +AWHI,Analysis Window Ending Timepoint,Num,,Perm,"The value of the ending timepoint (inclusive) needs to be used in conjunction to AWRANGE. For example, if AWRANGE is ""5-9 DAYS"", then AWHI is ""9""." +AWU,Analysis Window Unit,Char,,Perm,"Unit used for AWTARGET, AWTDIFF, AWLO and AWHI. Examples: DAYS, HOURS." diff --git a/data-raw/ig_source/adamig_1.2/BDS_Population_Indicators.csv b/data-raw/ig_source/adamig_1.2/BDS_Population_Indicators.csv new file mode 100644 index 0000000..ed75c48 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/BDS_Population_Indicators.csv @@ -0,0 +1,15 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ITTRFL,Intent-To-Treat Record-Level Flag,Char,Y,Perm,"These indicators identify whether or not the subject was in the specified analysis for the specific record. Useful when the subject is included in the subject-level population, but there are records for the subject that do not satisfy requirements for the population. +The valid values of these record-level population indicators are Y or null. If a flag is used, the corresponding numeric version (*FN, where 1=Yes) of the flag can also be included. As described in Section 3.1.1 Item 8, the *FN version of the variable can be included only if the corresponding *FL is also included. +Additional indicators may also be used; refer to Section 3.1.4, Flag Variable Conventions." +SAFRFL,Safety Analysis Record-Level Flag,Char,Y,Perm, +FASRFL,Full Analysis Set Record-Level Flag,Char,Y,Perm, +PPROTRFL,Per-Protocol Record-Level Flag,Char,Y,Perm, +COMPLRFL,Completers Record-Level Flag,Char,Y,Perm, +ITTPFL,Intent-To-Treat Parameter-Level Flag,Char,Y,Perm,"These indicators identify whether or not the subject was in the specified analysis for the specific parameter. Useful when the subject is included in the subject-level population, but there are parameters for which the subject does not satisfy requirements for the population. +The valid values of these parameter-level population indicators are Y or null. If a flag is used, the corresponding numeric version (*FN, where 1=Yes) of the flag can also be included. As described in Section 3.1.1, Item 8, the *FN version of the variable can be included only if the corresponding *FL is also included. +Additional indicators may also be used; refer to Section 3.1.4, Flag Variable Conventions." +SAFPFL,Safety Analysis Parameter-Level Flag,Char,Y,Perm, +FASPFL,Full Analysis Set Parameter-Level Flag,Char,Y,Perm, +PPROTPFL,Per-Protocol Parameter-Level Flag,Char,Y,Perm, +COMPLPFL,Completers Parameter-Level Flag,Char,Y,Perm, diff --git a/data-raw/ig_source/adamig_1.2/Datapoint_Traceability_Variables.csv b/data-raw/ig_source/adamig_1.2/Datapoint_Traceability_Variables.csv new file mode 100644 index 0000000..e5dd1fe --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Datapoint_Traceability_Variables.csv @@ -0,0 +1,5 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +SRCDOM,Source Data,Char,,Perm,"The SDTM domain name or ADaM dataset name that relates to the analysis value (i.e., AVAL or AVALC in a BDS dataset). If the source data is a supplemental qualifier in SDTM, this variable will contain the value of RDOMAIN in SUPP-- or SUPPQUAL." +SRCVAR,Source Variable,Char,,Perm,"The name of the column (in the domain or dataset identified by SRCDOM) that relates to the analysis value (i.e., AVAL or AVALC in a BDS dataset). In the event that SRCDOM is a SUPPQUAL, then SRCVAR will be populated with the value of the related QNAM." +SRCSEQ,Source Sequence Number,Num,,Perm,"The sequence number --SEQ or ASEQ of the row (in the domain or dataset identified by SRCDOM) that relates to the analysis value (i.e., AVAL or AVALC in a BDS dataset). In the event that SRCDOM is a SUPPQUAL, then this +variable will contain the sequence number of the relevant related domain record." diff --git a/data-raw/ig_source/adamig_1.2/Flag_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Flag_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..bc232bc --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Flag_Variables_BDS_Datasets.csv @@ -0,0 +1,16 @@ +Variable Name,Variable Label,,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ABLFL,Baseline Record Flag,,Char,Y,Cond,"Character indicator to identify the baseline record for each subject, parameter, and baseline type (BASETYPE) combination. See BASETYPE in Table 3.3.4.1.1. ABLFL is required if BASE is present in the dataset. +A baseline record may be derived (e.g., it may be an average), in which case DTYPE must also be populated. If BASE is populated for a parameter, and BASE is non-null for a subject for that parameter, then there must be a record flagged by ABLFL for that subject and parameter." +ABLFN,Baseline Record Flag (N),,Num,1,Perm,"Numeric representation of ABLFL. There must be a one-to- one relationship between ABLFN and ABLFL. ABLFN cannot be present unless ABLFL is also present. When ABLFL and ABLFN are present, then on a given record, either both must be populated or both must be null." +ANLzzFL,Analysis Flag zz,,Char,Y,Cond,"ANLzzFL is a conditionally required flag to be used in addition to other selection variables when the other selection variables in combination are insufficient to identify the exact set of records used for one or more analyses. Often one ANLzzFL will serve to support the accurate selection of records for more than one analysis. Note that it is allowable to add additional descriptive text to the label (see Section 3.1.6, Item 1). +When defining the set of records used in a particular analysis or family of analyses, ANLzzFL is supplemental to, and is intended to be used in conjunction with, other selection variables, such as subject-level, parameter-level and record- level population flags, AVISIT, DTYPE, grouping variables such as SITEGRy, and others. The lower-case letter ""zz"" in the variable name is an index for the zzth record selection algorithm where ""zz"" is replaced with a zero-padded two-digit integer [01-99]. Every record selection algorithm ""zz"" (i.e., every algorithm for populating an ANLzzFL) must be defined in variable metadata. When the set of records that the algorithm ""zz"" operates on is pre-filtered by application of other criteria, such as a record-level population flag, then the selection algorithm definition in the metadata must so specify. +Note that the ANLzzFL value of Y indicates that the record fulfilled the requirements of the algorithm, but does not necessarily imply that the record was actually used in one or more analyses, as whether or not a record is used also depends on the other selection variables applied. The ANLzzFL flag is useful in many circumstances; an example is when there is more than one record for an analysis timepoint within a subject and parameter, as it can be used to identify the record chosen to represent the timepoint for an analysis. ""zz"" is an index for a record selection algorithm, such as ""record closest to target relative day for the AVISIT, with ties broken by the latest record, for each AVISIT within ."" +Note that it is not required that a specific ANLzzFL variable has the same definition across a project or even across datasets within a study. There is also no requirement that the ANLzzFL variables in a dataset or study be used in numerical order; e.g. ANL02FL might occur in a dataset or study without ANL01FL present in the same dataset or study." +ANLzzFN,Analysis Flag zz (N),,Num,1,Perm,"Numeric representation of ANLzzFL. There must be a one-to- one relationship between ANLzzFN and ANLzzFL within a dataset. +ANLzzFN cannot be present unless ANLzzFL is also present. When ANLzzFL and ANLzzFN are present, then on a given record, either both must be populated or both must be null." +ONTRTFL,On Treatment Record Flag,,Char,Y,Perm,"Character indicator of whether the observation occurred while the subject was on treatment. ONTRTFL is producer-defined, and its definition may vary across datasets in a study based on analysis needs." +ONTRTFN,On Treatment Record Flag (N),,Num,1,Perm,"Numeric representation of ONTRTFL. There must be a one- to-one relationship between ONTRTFN and ONTRTFL within a dataset. +ONTRTFN cannot be present unless ONTRTFL is also present. When ONTRTFL and ONTRTFN are present, then on a given record, either both must be populated or both must be null." +LVOTFL,Last Value On Treatment Record Flag,,Char,Y,Perm,Character indicator of the subject's last non-missing value on treatment for each parameter. +LVOTFN,Last Value On Treatment Record Flag (N),,Num,1,Perm,"Numeric representation of LVOTFL. There must be a one-to- one relationship between LVOTFN and LVOTFL within a dataset. +LVOTFN cannot be present unless LVOTFL is also present. When LVOTFL and LVOTFN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/Identifier_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Identifier_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..5c36a18 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Identifier_Variables_BDS_Datasets.csv @@ -0,0 +1,10 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +STUDYID,Study Identifier,Char,,Req,"DM.STUDYID, ADSL STUDYID, and/or STUDYID +from another ADaM or SDTM dataset appropriate to the analysis." +USUBJID,Unique Subject Identifier,Char,,Req,"DM.USUBJID, ADSL.USUBJID, and/or USUBJID from +another ADaM or SDTM dataset appropriate to the analysis." +SUBJID,Subject Identifier for the Study,Char,,Perm,"DM.SUBJID, ADSL.SUBJID, and/or SUBJID from +another ADaM dataset appropriate to the analysis. SUBJID is required in ADSL, but permissible in other datasets." +SITEID,Study Site Identifier,Char,,Perm,"DM.SITEID, ADSL.SITEID, and/or SITEID from +another ADaM dataset appropriate to the analysis. SITEID is required in ADSL, but permissible in other datasets." +ASEQ,Analysis Sequence Number,Num,,Perm,"Sequence number given to ensure uniqueness of subject records within an ADaM dataset. As long as values are unique within a subject within the dataset, any valid number can be used for ASEQ. ASEQ uniquely indexes records within a subject within an ADaM dataset. ASEQ is useful for traceability when the dataset is used as input to another ADaM dataset. To refer to a record in a predecessor ADaM dataset, set SRCDOM to the name of the predecessor dataset, and set SRCSEQ to the value of ASEQ in the predecessor dataset." diff --git a/data-raw/ig_source/adamig_1.2/Period_Subperiod_Phase_Start_End_Timing_Variables.csv b/data-raw/ig_source/adamig_1.2/Period_Subperiod_Phase_Start_End_Timing_Variables.csv new file mode 100644 index 0000000..0dcac85 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Period_Subperiod_Phase_Start_End_Timing_Variables.csv @@ -0,0 +1,31 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +APERSDT,Period Start Date,Num,,Perm,The starting date for the period defined by APERIOD. +APERSTM,Period Start Time,Num,,Perm,The starting time for the period defined by APERIOD. +APERSDTM,Period Start Datetime,Num,,Perm,The starting datetime for the period defined by APERIOD. +APERSDTF,Period Start Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of period start date. If APERSDT (or the date part of APERSDTM) was imputed, APERSDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +APERSTMF,Period Start Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of period start time. If APERSTM (or the time part of APERSDTM) was imputed, APERSTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +APEREDT,Period End Date,Num,,Perm,The ending date for the period defined by APERIOD. +APERETM,Period End Time,Num,,Perm,The ending time for the period defined by APERIOD. +APEREDTM,Period End Datetime,Num,,Perm,The ending datetime for the period defined by APERIOD. +APEREDTF,Period End Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of period end date. If APEREDT (or the date part of APEREDTM) was imputed, APEREDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +APERETMF,Period End Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of period end time. If APERETM (or the time part of APEREDTM) was imputed, APERETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASPRSDT,Subperiod Start Date,Num,,Perm,The starting date for the subperiod defined by ASPER. +ASPRSTM,Subperiod Start Time,Num,,Perm,The starting time for the subperiod defined by ASPER. +ASPRSDTM,Subperiod Start Datetime,Num,,Perm,The starting datetime for the subperiod defined by ASPER. +ASPRSDTF,Subperiod Start Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of subperiod start date. If ASPRSDT (or the date part of ASPRSDTM) was imputed, ASPRSDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASPRSTMF,Subperiod Start Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of subperiod start time. If ASPRSTM (or the time part of ASPRSDTM) was imputed, ASPRSTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASPREDT,Subperiod End Date,Num,,Perm,The ending date for the subperiod defined by ASPER. +ASPRETM,Subperiod End Time,Num,,Perm,The ending time for the subperiod defined by ASPER. +ASPREDTM,Subperiod End Datetime,Num,,Perm,The ending datetime for the subperiod defined by ASPER. +ASPREDTF,Subperiod End Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of subperiod end date. If ASPREDT (or the date part of ASPREDTM) was imputed, ASPREDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASPRETMF,Subperiod End Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of subperiod end time. If ASPRETM (or the time part of ASPREDTM) was imputed, ASPRETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHSDT,Phase Start Date,Num,,Perm,The starting date for the phase defined by APHASE. +PHSTM,Phase Start Time,Num,,Perm,The starting time for the phase defined by APHASE. +PHSDTM,Phase Start Datetime,Num,,Perm,The starting datetime for the phase defined by APHASE. +PHSDTF,Phase Start Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of phase start date. If PHSDT (or the date part of PHSDTM) was imputed, PHSDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHSTMF,Phase Start Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of phase start time. If PHSTM (or the time part of PHSDTM) was imputed, PHSTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHEDT,Phase End Date,Num,,Perm,The ending date for the phase defined by APHASE. +PHETM,Phase End Time,Num,,Perm,The ending time for the phase defined by APHASE. +PHEDTM,Phase End Datetime,Num,,Perm,The ending datetime for the phase defined by APHASE. +PHEDTF,Phase End Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of phase end date. If PHEDT (or the date part of PHEDTM) was imputed, PHEDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHETMF,Phase End Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of phase end time. If PHETM (or the time part of PHEDTM) was imputed, PHETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." diff --git a/data-raw/ig_source/adamig_1.2/Record_Level_Dose_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Record_Level_Dose_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..1b31fb5 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Record_Level_Dose_Variables_BDS_Datasets.csv @@ -0,0 +1,6 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +DOSEP,Planned Treatment Dose,Num,,Perm,DOSEP represents the planned treatment dosage associated with the record. +DOSCUMP,Cumulative Planned Treatment Dose,Num,,Perm,"Cumulative planned dosage of treatment for the subject at the point in time of the record (e.g., ADT)." +DOSEA,Actual Treatment Dose,Num,,Perm,DOSEA represents the actual treatment dosage associated with the record. +DOSCUMA,Cumulative Actual Treatment Dose,Num,,Perm,"Cumulative actual dosage of treatment for the subject at the point in time of the record (e.g., ADT)." +DOSEU,Treatment Dose Units,Char,,Perm,"The units for DOSEP, DOSCUMP, DOSEA, and DOSCUMA. It is permissible to use suffixes such as ""P"" and ""A"" if needed, with labels modified accordingly." diff --git a/data-raw/ig_source/adamig_1.2/Record_Level_Treatment_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Record_Level_Treatment_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..336723e --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Record_Level_Treatment_Variables_BDS_Datasets.csv @@ -0,0 +1,16 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +TRTP,Planned Treatment,Char,,Cond,"TRTP is a record-level identifier that represents the planned treatment attributed to a record for analysis purposes. TRTP indicates how treatment varies by record within a subject and enables analysis of crossover and other designs. Though there is no requirement that TRTP will correspond to the TRTxxP as defined by the record's value of APERIOD, if populated, TRTP must match at least one value of the character planned treatment variables in ADSL (e.g., TRTxxP, TRTSEQP, TRxxPGy). +As noted previously, at least one treatment variable is required even in non-randomized trials. This requirement is satisfied by any subject-level or record-level treatment variables (e.g., TRTxxP, TRTP, TRTA). Even if not used for analysis, any ADSL treatment variable may be included in the BDS dataset." +TRTPN,Planned Treatment (N),Num,,Perm,"Numeric representation of TRTP. There must be a one- to-one relationship between TRTPN and TRTP within a study. +TRTPN cannot be present unless TRTP is also present. When TRTP and TRTPN are present, then on a given record, either both must be populated or both must be null." +TRTA,Actual Treatment,Char,,Cond,"TRTA is a record-level identifier that represents the actual treatment attributed to a record for analysis purposes. TRTA indicates how treatment varies by record within a subject and enables analysis of crossover and other multi-period designs. Though there is no requirement that TRTA will correspond to the TRTxxA as defined by the record's value of APERIOD, TRTA must match at least one value of the character actual treatment variables in ADSL (e.g., TRTxxA, TRTSEQA, TRxxAGy). +As noted previously, at least one treatment variable is required. This requirement is satisfied by any subject-level or record-level treatment variables (e.g., TRTxxP, TRTP, TRTA). Even if not used for analysis, any ADSL treatment variable may be included in the BDS dataset." +TRTAN,Actual Treatment (N),Num,,Perm,"Numeric representation of TRTA. There must be a one- to-one relationship between TRTAN and TRTA within a study. +TRTAN cannot be present unless TRTA is also present. When TRTA and TRTAN are present, then on a given record, either both must be populated or both must be null." +TRTPGy,Planned Pooled Treatment y,Char,,Perm,"TRTPGy is the planned pooled treatment y attributed to a record for analysis purposes. ""y"" represents an integer [1- 99, not zero-padded] corresponding to a particular pooling scheme. Useful when planned treatments (TRTP) are pooled together for analysis, for example when all doses of Drug A (TRTPG1=All doses of Drug A) are compared to all doses of Drug B (TRTPG1=All doses of Drug B). Each value of TRTP is pooled within at most one value of TRTPGy." +TRTPGyN,Planned Pooled Treatment y (N),Num,,Perm,"Numeric representation of TRTPGy. There must be a +one-to-one relationship between TRTPGyN and TRTPGy within a study. +TRTPGyN cannot be present unless TRTPGy is also present. When TRTPGy and TRTPGyN are present, then on a given record, either both must be populated or both must be null." +TRTAGy,Actual Pooled Treatment y,Char,,Cond,"TRTAGy is the actual pooled treatment y attributed to a record for analysis purposes. ""y"" represents an integer [1- 99, not zero-padded] corresponding to a particular pooling scheme. Required when TRTPGy is present and TRTA is present." +TRTAGyN,Actual Pooled Treatment y (N),Num,,Perm,"Numeric representation of TRTAGy. There must be a one-to-one relationship between TRTAGyN and TRTAGy within a study. +TRTAGyN cannot be present unless TRTAGy is also present. When TRTAGy and TRTAGyN are present, then on a given record, either both must be populated or both must be null." diff --git a/data-raw/ig_source/adamig_1.2/Subject_Level_Period_Subperiod_Phase_Timing_Variables.csv b/data-raw/ig_source/adamig_1.2/Subject_Level_Period_Subperiod_Phase_Timing_Variables.csv new file mode 100644 index 0000000..2f37b6f --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Subject_Level_Period_Subperiod_Phase_Timing_Variables.csv @@ -0,0 +1,33 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +APxxSDT,Period xx Start Date,Num,,Perm,The starting date of period xx. +APxxSTM,Period xx Start Time,Num,,Perm,The starting time of period xx. +APxxSDTM,Period xx Start Datetime,Num,,Perm,The starting datetime of period xx. +APxxSDTF,Period xx Start Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of period xx start date. See Section 3.1.3, Date and Time Imputation Flag Variables." +APxxSTMF,Period xx Start Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of period xx start time. See Section 3.1.3, Date and Time Imputation Flag Variables." +APxxEDT,Period xx End Date,Num,,Perm,The ending date of period xx. +APxxETM,Period xx End Time,Num,,Perm,The ending time of period xx. +APxxEDTM,Period xx End Datetime,Num,,Perm,The ending datetime of period xx. +APxxEDTF,Period xx End Date Imput. Flag,Char,(DATEFL),Cond,"The level of imputation of period xx end date. See Section 3.1.3, Date and Time Imputation Flag Variables." +APxxETMF,Period xx End Time Imput. Flag,Char,(TIMEFL),Cond,"The level of imputation of period xx end time. See Section 3.1.3, Date and Time Imputation Flag Variables." +PxxSw,Description of Period xx Subperiod w,Char,,Perm,Description of analysis subperiod w within period xx. +PxxSwSDT,Period xx Subperiod w Start Date,Num,,Perm,The starting date of subperiod w within period xx. +PxxSwSTM,Period xx Subperiod w Start Time,Num,,Perm,The starting time of subperiod w within period xx. +PxxSwSDM,Period xx Subperiod w Start Datetime,Num,,Perm,The starting datetime of subperiod w within period xx. +PxxSwSDF,Period xx Subper w Start Date Imput Flag,Char,(DATEFL),Cond,"The level of imputation of the start date for subperiod w within period xx. See Section 3.1.3, Date and Time Imputation Flag Variables." +PxxSwSTF,Period xx Subper w Start Time Imput Flag,Char,(TIMEFL),Cond,"The level of imputation of the start time for subperiod w within period xx. See Section 3.1.3, Date and Time Imputation Flag Variables." +PxxSwEDT,Period xx Subperiod w End Date,Num,,Perm,The ending date of subperiod w within period xx. +PxxSwETM,Period xx Subperiod w End Time,Num,,Perm,The ending time of subperiod w within period xx. +PxxSwEDM,Period xx Subperiod w End Datetime,Num,,Perm,The ending datetime of subperiod w within period xx. +PxxSwEDF,Period xx Subper w End Date Imput Flag,Char,(DATEFL),Cond,"The level of imputation of the end date for subperiod w within period xx. See Section 3.1.3, Date and Time Imputation Flag Variables." +PxxSwETF,Period xx Subper w End Time Imput Flag,Char,(TIMEFL),Cond,"The level of imputation of the end time for subperiod w within period xx. See Section 3.1.3, Date and Time Imputation Flag Variables." +APHASEw,Description of Phase w,Char,,Perm,"Description of analysis phase w. Analysis phase is independent of TRTxxP within ADSL, and may be populated for spans of time where a subject is not on treatment." +PHwSDT,Phase w Start Date,Num,,Perm,The starting date of phase w. +PHwSTM,Phase w Start Time,Num,,Perm,The starting time of phase w. +PHwSDTM,Phase w Start Datetime,Num,,Perm,The starting datetime of phase w. +PHwSDTF,Phase w Start Date Imputation Flag,Char,(DATEFL),Cond,"The level of imputation of the start date for phase w. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHwSTMF,Phase w Start Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of the start time for phase w. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHwEDT,Phase w End Date,Num,,Perm,The ending date of phase w. +PHwETM,Phase w End Time,Num,,Perm,The ending time of phase w. +PHwEDTM,Phase w End Datetime,Num,,Perm,The ending datetime of phase w. +PHwEDTF,Phase w End Date Imputation Flag,Char,(DATEFL),Cond,"The level of imputation of the end date for phase w. See Section 3.1.3, Date and Time Imputation Flag Variables." +PHwETMF,Phase w End Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of the end time for phase w. See Section 3.1.3, Date and Time Imputation Flag Variables." diff --git a/data-raw/ig_source/adamig_1.2/Suffixes_Producer_Defined_Timing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Suffixes_Producer_Defined_Timing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..21d5a85 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Suffixes_Producer_Defined_Timing_Variables_BDS_Datasets.csv @@ -0,0 +1,23 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +*DT,{Date},Num,,Perm,Analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*TM,{Time},Num,,Perm,Analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*DTM,{Datetime},Num,,Perm,Analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*ADY,{Relative Day},Num,,Perm,Analysis relative day not directly characterizing AVAL and/or AVALC. +*DTF,{Date Imputation Flag},Char,(DATEFL),Cond,"The level of imputation of *DT. If *DT (or the date part of *DTM) was imputed, *DTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +*TMF,{Time Imputation Flag},Char,(TIMEFL),Cond,"The level of imputation of *TM. If *TM (or the time part of *DTM) was imputed, *TMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +*SDT,{Start Date},Num,,Perm,Starting analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*STM,{Start Time},Num,,Perm,Starting analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*SDTM,{Start Datetime},Num,,Perm,Starting analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*SDY,{Relative Start Day},Num,,Perm,Starting analysis relative day not directly characterizing AVAL and/or AVALC. +*SDTF,{Start Date Imputation Flag},Char,(DATEFL),Cond,"The level of imputation of *SDT. If *SDT (or the date part of +*SDTM) was imputed, *SDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +*STMF,{Start Time Imputation Flag},Char,(TIMEFL),Cond,"The level of imputation of *STM. If *STM (or the time part of +*SDTM) was imputed, *STMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +*EDT,{End Date},Num,,Perm,Ending analysis date not directly characterizing AVAL and/or AVALC in numeric format. +*ETM,{End Time},Num,,Perm,Ending analysis time not directly characterizing AVAL and/or AVALC in numeric format. +*EDTM,{End Datetime},Num,,Perm,Ending analysis datetime not directly characterizing AVAL and/or AVALC in numeric format. +*EDY,{Relative End Day},Num,,Perm,Ending analysis relative day not directly characterizing AVAL and/or AVALC. +*EDTF,{End Date Imputation Flag},Char,(DATEFL),Cond,"The level of imputation of *EDT. If *EDT (or the date part of +*EDTM) was imputed, *EDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +*ETMF,{End Time Imputation Flag},Char,(TIMEFL),Cond,"The level of imputation of *ETM. If *ETM (or the time part of +*EDTM) was imputed, *ETMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." diff --git a/data-raw/ig_source/adamig_1.2/Time_To_Event_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Time_To_Event_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..294a45b --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Time_To_Event_Variables_BDS_Datasets.csv @@ -0,0 +1,8 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,,Core,,CDISC Notes,, +STARTDT,Time-to- Event Origin Date for Subject,Num,,,Perm,,"The original date of risk for the time-to-event analysis. This is generally the point at which a subject is first at risk for the event of interest evaluation (as defined in the Protocol or SAP). For example, this may be the randomization date or the date of first study therapy exposure.",, +STARTDTM,Time-to- Event Origin Datetime,Num,,,Perm,,"The original datetime of risk for the time-to-event analysis. This is generally the point at which a subject is first at risk for the event of interest evaluation (as defined in the Protocol or SAP). For example, this may be the randomization datetime or the datetime of first study therapy exposure.",, +STARTDTF,Origin Date Imputation Flag,Char,(DATEFL),,Cond,,"The level of imputation of the start date. See Section 3.1.3, Date and Time Imputation Flag Variables.",, +STARTTMF,Origin Time Imputation Flag,Char,(TIMEFL),,Cond,,"The level of imputation of the start time. See Section 3.1.3, Date and Time Imputation Flag Variables.",, +CNSR,Censor,Num,,,Cond,,Defines whether the event was censored for the subject within the parameter (period of observation truncated prior to event being observed). It is strongly recommended to use 0 as an event indicator and positive integers as censoring indicators. It is also recommended that unique positive integers be used to indicate coded descriptions of censoring reasons. CNSR is required for time-to-event parameters.,, +EVNTDESC,Event or Censoring Description,Char,,,Perm,,Description of the event of interest or censoring reason for the subject within the parameter.,, +CNSDTDSC,Censor Date Description,Char,,,Perm,,Describes the circumstance represented by the censoring date if different from the event date that warrants censoring.,, diff --git a/data-raw/ig_source/adamig_1.2/Timing_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Timing_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..ea460b9 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Timing_Variables_BDS_Datasets.csv @@ -0,0 +1,39 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ADT,Analysis Date,Num,,Perm,The date associated with AVAL and/or AVALC in numeric format. +ATM,Analysis Time,Num,,Perm,The time associated with AVAL and/or AVALC in numeric format. +ADTM,Analysis Datetime,Num,,Perm,The datetime associated with AVAL and/or AVALC in numeric format. +ADY,Analysis Relative Day,Num,,Perm,"The relative day of AVAL and/or AVALC. The number of days from an anchor date (not necessarily DM.RFSTDTC) to ADT. See Section 3.1.2, Timing Variable Conventions." +ADTF,Analysis Date Imputation Flag,Char,(DATEFL),Cond,"The level of imputation of analysis date. If ADT (or the date part of ADTM) was imputed, ADTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ATMF,Analysis Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of analysis time. If ATM (or the time part of ADTM) was imputed, ATMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASTDT,Analysis Start Date,Num,,Perm,"The start date associated with AVAL and/or AVALC. ASTDT and AENDT may be useful for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a duration." +ASTTM,Analysis Start Time,Num,,Perm,"The start time associated with AVAL and/or AVALC. ASTTM and AENTM may be useful for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a duration." +ASTDTM,Analysis Start Datetime,Num,,Perm,"The start datetime associated with AVAL and/or AVALC. ASTDTM and AENDTM may be useful for traceability when AVAL summarizes data collected over an interval of time, or when AVAL is a duration." +ASTDY,Analysis Start Relative Day,Num,,Perm,"The number of days from an anchor date (not necessarily DM.RFSTDTC) to ASTDT. See Section 3.1.2, Timing Variable Conventions." +ASTDTF,Analysis Start Date Imputation Flag,Char,(DATEFL),Cond,"The level of imputation of analysis start date. If ASTDT (or the date part of ASTDTM) was imputed, ASTDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +ASTTMF,Analysis Start Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of analysis start time. If ASTTM (or the time part of ASTDTM) was imputed, ASTTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +AENDT,Analysis End Date,Num,,Perm,The end date associated with AVAL and/or AVALC. See also ASTDT. +AENTM,Analysis End Time,Num,,Perm,The end time associated with AVAL and/or AVALC. See also ASTTM. +AENDTM,Analysis End Datetime,Num,,Perm,The end datetime associated with AVAL and/or AVALC. See also ASTDTM. +AENDY,Analysis End Relative Day,Num,,Perm,"The number of days from an anchor date (not necessarily DM.RFSTDTC) to AENDT. See Section 3.1.2, Timing Variable Conventions." +AENDTF,Analysis End Date Imputation Flag,Char,(DATEFL),Cond,"The level of imputation of analysis end date. If AENDT (or the date part of AENDTM) was imputed, AENDTF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +AENTMF,Analysis End Time Imputation Flag,Char,(TIMEFL),Cond,"The level of imputation of analysis end time. If AENTM (or the time part of AENDTM) was imputed, AENTMF must be populated and is required. See Section 3.1.3, Date and Time Imputation Flag Variables." +AVISIT,Analysis Visit,Char,,Cond,"The analysis visit description; required if an analysis is done by nominal, assigned or analysis visit. AVISIT may contain the visit names as observed (i.e., from SDTM VISIT), derived visit names, time window names, conceptual descriptions (such as Average, Endpoint, etc.), or a combination of any of these. AVISIT is a derived field and does not have to map to VISIT from the SDTM. AVISIT represents the analysis visit of the record, but it does not mean that the record was analyzed. There are often multiple records for the same subject and parameter that have the same value of AVISIT. ANLzzFL and other variables may be needed to identify the records selected for any given analysis. See Section 3.3.8, Indicator Variables for BDS Datasets, for information about flag variables. AVISIT should be unique for a given analysis visit window. In the event that a record does not fall within any predefined analysis timepoint window, AVISIT can be populated in any way that the producer chooses to indicate this fact (e.g., blank or ""Not Windowed""). The way that AVISIT is calculated, including the variables used in its derivation, should be indicated in the variable metadata for AVISIT. The values and the rules for deriving AVISIT may be different for different parameters within the same dataset. Values of AVISIT are producer-defined, and are often directly usable in Clinical Study Report displays." +AVISITN,Analysis Visit (N),Num,,Perm,"Numeric representation of AVISIT. Since study visits are usually defined by certain timepoints, defining AVISITN so that it represents the timepoint associated with the visit can facilitate plotting and interpretation of the values. +Alternatively, AVISITN may be a protocol visit number, a cycle number, an analysis visit number, or any other number logically related to AVISIT or useful for sorting that is needed for analysis. +There must be a one-to-one relationship between AVISITN and AVISIT (i.e., AVISITN has the same value for each distinct AVISIT) within a parameter. A best practice is to extend the one-to-one relationship to within a study, but this is not an ADaM requirement. In the event that a record does not fall within any predefined analysis timepoint window, AVISITN can be populated in any way that the producer chooses to indicate this fact (e.g., may be null). Values of AVISITN are producer- defined. +AVISITN cannot be present unless AVISIT is also present. On a given record, AVISITN cannot be populated if AVISIT is null. AVISITN can be null when AVISIT is populated, as long as the one-to-one relationship is maintained within a parameter on all rows on which both variables are populated." +ATPT,Analysis Timepoint,Char,,Cond,"The analysis timepoint description; required if an analysis is done by nominal, assigned or analysis timepoint (instead of or in addition to by-visit). Timepoints are relative to ATPTREF. ATPT may contain the timepoint names as observed (i.e., from SDTM -- TPT), derived timepoint names, time window names, conceptual descriptions (such as Average, Endpoint, etc.), or a combination of any of these. This variable is often used in conjunction with AVISIT. ATPT represents the analysis timepoint of the record. +ATPT can be within an analysis visit (e.g., blood pressure assessments at 10 min, 20 min, and 30 min post- dose at AVISIT=Week 1) or can be unrelated to AVISIT (e.g., migraine symptoms 30 min, 60 min, and 120 min post-dose for attack 1). The way that ATPT is calculated, including the variables used in its derivation, should be indicated in the variable metadata for ATPT. The values and the rules for deriving ATPT may be different for different parameters within the same dataset. Values of ATPT are producer-defined, and are often directly usable in Clinical Study Report displays." +ATPTN,Analysis Timepoint (N),Num,,Perm,"Numeric representation of ATPT. Defining ATPTN so that its values represent the planned timepoints (e.g., minutes or hours after dosing) is not required but can facilitate plotting and interpretation of the values. There must be a one-to-one relationship between ATPTN and ATPT within a parameter. (Best practice would dictate that the mapping would be one-to-one within a study, but that is not an ADaM requirement.) +ATPTN cannot be present unless ATPT is also present. When ATPT and ATPTN are present, then on a given record, either both must be populated or both must be null." +ATPTREF,Analysis Timepoint Reference,Char,,Perm,"Description of the fixed reference point referred to by ATPT/ATPTN (e.g., time of dose)." +APHASE,Phase,Char,,Perm,"APHASE is a categorization of timing within a study, for example a higher-level categorization of APERIOD or an analysis epoch. For example, APHASE could describe spans of time for SCREENING, ON TREATMENT, and FOLLOW-UP. APHASE may be used alone or in addition to APERIOD. APHASE is independent of TRTxxP within ADSL. APHASE may be populated for spans of time where a subject is not on treatment. The value of APHASE (if populated) must be one of the values found in the ADSL APHASEw variables." +APHASEN,Phase (N),Num,,Perm,"Numeric representation of APHASE. The value of APHASEN (if populated) must be one of the w values found in the ADSL APHASEw variable names. There must be a one-to-one relationship between APHASEN and APHASE within a study, which must be the same as the one-to-one mapping between w and APHASEw in ADSL. +APHASEN cannot be present unless APHASE is also present. When APHASE and APHASEN are present, then on a given record, either both must be populated or both must be null." +APERIOD,Period,Num,,Cond,APERIOD is a record-level timing variable that represents the analysis period within the study associated with the record for analysis purposes. The value of APERIOD (if populated) must be one of the xx values found in the ADSL TRTxxP variable names. APERIOD is required if ASPER is present. APERIOD must be populated on all records where ASPER is populated. +APERIODC,Period (C),Char,,Perm,"Text characterizing to which analysis period the record belongs. There must be a one-to-one relationship between APERIODC and APERIOD within a study. APERIODC cannot be present unless APERIOD is also present. When APERIOD and APERIODC are present, then on a given record, either both must be populated or both must be null." +ASPER,Subperiod within Period,Num,,Perm,"The numeric value characterizing a sublevel within APERIOD to which the record belongs. Within each APERIOD, the first ASPER is 1 (i.e., it resets to 1 when the APERIOD value changes). The value of ASPER (if populated) must be one of the w values found in the ADSL PxxSw variable names." +ASPERC,Subperiod within Period (C),Char,,Perm,"Text characterizing to which subperiod the record belongs. There must be a one-to-one relationship between ASPERC and ASPER within a value of APERIOD, which must be the same as the one-to-one mapping between PxxSw and w in ADSL, where xx is equal to the value of APERIOD. The value of ASPERC (if populated) must be one of the values found in the ADSL PxxSw variables. +ASPERC cannot be present unless ASPER is also present. When ASPER and ASPERC are present, then on a given record, either both must be populated or both must be null." +ARELTM,Analysis Relative Time,Num,,Perm,"The time relative to an anchor time. The amount of time from an anchor time to ATM. When ARELTM is present, the anchor time variable and ARELTMU must also be included in the dataset, and the anchor time variable must be identified in the metadata for ARELTM." +ARELTMU,Analysis Relative Time Unit,Char,,Perm,"The units of ARELTM. For example, ""HOURS"" or ""MINUTES."" ARELTMU is required if ARELTM is present." diff --git a/data-raw/ig_source/adamig_1.2/Toxicity_Range_Variables_BDS_Datasets.csv b/data-raw/ig_source/adamig_1.2/Toxicity_Range_Variables_BDS_Datasets.csv new file mode 100644 index 0000000..209a796 --- /dev/null +++ b/data-raw/ig_source/adamig_1.2/Toxicity_Range_Variables_BDS_Datasets.csv @@ -0,0 +1,46 @@ +Variable Name,Variable Label,Type,Codelist/ Controlled Terms,Core,CDISC Notes +ATOXGR,Analysis Toxicity Grade,Char,,Perm,Toxicity grade of AVAL or AVALC for analysis; may be based on SDTM --TOXGR or an imputed or assigned value. +ATOXGRN,Analysis Toxicity Grade (N),Num,,Perm,"Numeric representation of ATOXGR. There must be a one-to-one relationship between ATOXGRN and ATOXGR within a parameter. +ATOXGRN cannot be present unless ATOXGR is also present. When ATOXGR and ATOXGRN are present, then on a given record, either both must be populated or both must be null." +BTOXGR,Baseline Toxicity Grade,Char,,Perm,ATOXGR of the baseline record identified by ABLFL. +BTOXGRN,Baseline Toxicity Grade (N),Num,,Perm,"Numeric representation of BTOXGR. There must be a one-to-one relationship between BTOXGRN and BTOXGR within a parameter. +BTOXGRN cannot be present unless BTOXGR is also present. When BTOXGR and BTOXGRN are present, then on a given record, either both must be populated or both must be null." +ANRIND,Analysis Reference Range Indicator,Char,,Perm,Indicates where AVAL or AVALC falls with respect to the normal reference range for analysis; may be based on SDTM --NRIND or an imputed or assigned value. +BNRIND,Baseline Reference Range Indicator,Char,,Perm,ANRIND of the baseline record identified by ABLFL. +ANRLO,Analysis Normal Range Lower Limit,Num,,Perm,Normal range lower limit for analysis; may be based on SDTM --NRLO or an imputed or assigned value. +ANRLOC,Analysis Normal Range Lower Limit (C),Char,,Perm,"Character analysis normal range lower limit. ANRLOC can be a character string mapping to ANRLO, but if so there must be a one-to-one +relationship between ANRLO and ANRLOC +within a given PARAM. ANRLOC should not be used to categorize the values of ANRLO. +Within a given parameter, if there exists a row on which both ANRLOC and ANRLO are populated, then there must be a one-to-one relationship between ANRLOC and ANRLO on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either ANRLO or ANRLOC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for ANRLO, ANRLOC, or both to be null." +ANRHI,Analysis Normal Range Upper Limit,Num,,Perm,Normal range upper limit for analysis; may be based on SDTM --NRHI or an imputed or assigned value. +ANRHIC,Analysis Normal Range Upper Limit (C),Char,,Perm,"Character analysis normal range upper limit. ANRHIC can be a character string mapping to ANRHI, but if so there must be a one-to-one +relationship between ANRHI and ANRHIC within +a given PARAM. ANRHIC should not be used to categorize the values of ANRHI. Within a given parameter, if there exists a row on which both ANRHIC and ANRHI are populated, then there must be a one-to-one relationship between ANRHIC and ANRHI on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either ANRHI or ANRHIC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for ANRHI, ANRHIC, or both to be null." +AyLO,Analysis Range y Lower Limit,Num,,Cond,"AyLO and/or AyHI are used for analysis ranges other than the normal range. AyLO and/or AyHI are created to capture the different levels of cutoff values used to determine whether an analysis is within a clinically acceptable value range or outside that value range. AyLO and/or AyHI are usually but not necessarily constants, parameter-specific constants, or subject-specific constants. AyLO must be included if R2AyLO is included in the dataset." +AyLOC,Analysis Range y Lower Limit (C),Char,,Perm,"Character analysis range y lower limit. AyLOC can be a character string mapping to AyLO, but if so there must be a one-to-one +relationship between AyLO and AyLOC within a +given PARAM. AyLOC should not be used to categorize the values of AyLO. +Within a given parameter, if there exists a row on which both AyLOC and AyLO are populated, then there must be a one-to-one relationship between AyLOC and AyLO on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AyLO or AyLOC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for AyLO, AyLOC, or both to be null." +AyHI,Analysis Range y Upper Limit,Num,,Cond,"See AyLO. +For example, if ECG QTc values are summarized based on values >450, values >480, and values +>500, there is a need for 3 ""hi value"" range variables against which to compare values: A1HI=450, A2HI=480, A3HI=500. +AyHI must be included if R2AyHI is included in the dataset." +AyHIC,Analysis Range y Upper Limit (C),Char,,Perm,"Character analysis range y upper limit. +AyHIC can be a character string mapping to AyHI, but if so there must be a one-to-one relationship between AyHI and AyHIC within a given PARAM. AyHIC should not be used to categorize the values of AyHI. +Within a given parameter, if there exists a row on which both AyHIC and AyHI are populated, then there must be a one-to-one relationship between AyHIC and AyHI on all rows on which both variables are populated. (In other words, there is no requirement that records with a null value in either AyHI or AyHIC be included when determining whether the one-to-one relationship requirement is satisfied.) On a given record, it is permissible for AyHI, AyHIC, or both to be null." +AyIND,Analysis Range y Indicator,Char,,Perm,"Indicates relationship of AVAL to the analysis range variables AyLO and/or AyHI, or the relationship of AVALC to the analysis range variables AyLOC and/or AyHIC." +ByIND,Baseline Analysis Range y Indicator,Char,,Perm,AyIND of the baseline record identified by ABLFL. +ATOXGRL,Analysis Toxicity Grade Low,Char,,Perm,Low toxicity grade of AVAL or AVALC for analysis; may be based on SDTM --TOXGR or an imputed or assigned value. Used to assess when a subject's lab value falls within the low toxicity range. +ATOXGRLN,Analysis Toxicity Grade Low (N),Num,,Perm,"Numeric representation of ATOXGRL. There must be a one-to-one relationship between ATOXGRLN and ATOXGRL within a parameter. +ATOXGRLN cannot be present unless ATOXGRL is also present. When ATOXGRL and ATOXGRLN are present, then on a given record, either both must be populated or both must be null." +ATOXGRH,Analysis Toxicity Grade High,Char,,Perm,"High toxicity grade of AVAL or AVALC for analysis; may be based on SDTM --TOXGR or +an imputed or assigned value. Used to assess when a subject's lab value falls within the high toxicity range." +ATOXGRHN,Analysis Toxicity Grade High (N),Num,,Perm,"Numeric representation of ATOXGRH. There must be a one-to-one relationship between ATOXGRHN and ATOXGRH within a parameter. +ATOXGRHN cannot be present unless ATOXGRH is also present. When ATOXGRH and ATOXGRHN are present, then on a given record, either both must be populated or both must be null." +BTOXGRL,Baseline Toxicity Grade Low,Char,,Perm,ATOXGRL of the baseline record identified by ABLFL. +BTOXGRLN,Baseline Toxicity Grade Low (N),Num,,Perm,"Numeric representation of BTOXGRL. There must be a one-to-one relationship between BTOXGRLN and BTOXGRL within a parameter. +BTOXGRLN cannot be present unless BTOXGRL is also present. When BTOXGRL and BTOXGRLN are present, then on a given record, either both must be populated or both must be null." +BTOXGRH,Baseline Toxicity Grade High,Char,,Perm,ATOXGRH of the baseline record identified by ABLFL. +BTOXGRHN,Baseline Toxicity Grade High (N),Num,,Perm,"Numeric representation of BTOXGRH. There must be a one-to-one relationship between BTOXGRHN and BTOXGRH within a parameter. BTOXGRHN cannot be present unless BTOXGRH is also present. When BTOXGRH and BTOXGRHN are present, then on a given record, either both must be populated or both must be null." +ATOXDSCL,Analysis Toxicity Description Low,Char,,Perm,The analysis toxicity term used to describe toxicity in the low direction. ATOXDCSL is only populated if AVAL is populated and the PARAM is evaluated for toxicity in the low direction. There is a one-to- one relationship between ATOXDCSL and PARAM within a subject. The intent of this variable is to describe the type of toxicity being evaluated and not the level of toxicity on the specific record. +ATOXDSCH,Analysis Toxicity Description High,Char,,Perm,The analysis toxicity term used to describe toxicity in the high direction. ATOXDSCH is only populated if AVAL is populated and the PARAM is evaluated for toxicity in the high direction. There is a one-to-one relationship between ATOXDCSH and PARAM within a subject. The intent of this variable is to describe the type of toxicity being evaluated and not the level of toxicity on the specific record. diff --git a/data-raw/ig_source/sdtm_model/1.4/Findings_Observation_Class.csv b/data-raw/ig_source/sdtm_model/1.4/Findings_Observation_Class.csv new file mode 100644 index 0000000..70c85b6 --- /dev/null +++ b/data-raw/ig_source/sdtm_model/1.4/Findings_Observation_Class.csv @@ -0,0 +1,270 @@ +"Variable +Name ",Variable Label ,Type ,Role ,Description +Topic Variable,,,, +--TESTCD ,"Short Name of +Measurement, Test +or Examination",Char ,Topic ,"Short character value for --TEST used as a column name when +converting a dataset from a vertical format to a horizontal +format. The short value can be up to 8 characters. Examples: +PLAT, SYSBP, RRMIN, EYEEXAM." +Qualifier Variables,,,, +--TEST ,"Name of +Measurement, Test +or Examination",Char ,"Synonym +Qualifier of +--TESTCD","Long name For --TESTCD. Examples: Platelet, Systolic Blood +Pressure, Summary (Min) RR Duration, Eye Examination." +--MODIFY ,Modified Term ,Char ,"Synonym +Qualifier of +--ORRES","If the value of --ORRES is modified for coding purposes, then +the modified text is placed here." +--TSTDTL ,"Measurement, Test +or Examination +Detail",Char ,"Variable +Qualifier of +--TESTCD and +--TEST","Further description of --TESTCD and --TEST. Example: “The +percentage of cells with +1 intensity of staining” when +MITESTCD = TTF1." +--CAT ,Category ,Char ,"Grouping +Qualifier","Used to define a category of topic-variable values. Examples: +HEMATOLOGY, URINALYSIS, CHEMISTRY, HAMILTON +DEPRESSION SCALE, SF36, MICRO ARRAY, EGFR +MUTATION ANALYSIS" +--SCAT ,Subcategory ,Char ,"Grouping +Qualifier","Used to define a further categorization of --CAT values. +Example: DIFFERENTIAL." +--POS ,"Position of Subject +During +Observation",Char ,"Record +Qualifier","Position of the subject during a measurement or examination. +Examples: SUPINE, STANDING, SITTING." +--BODSYS ,"Body System or +Organ Class",Char ,"Record +Qualifier","Body System or Organ Class that is involved for a finding from +the standard hierarchy for dictionary-coded results. Example: +MedDRA SOC." +--ORRES ,"Result or Finding +in Original Units",Char ,"Result +Qualifier","Result of the measurement or finding as originally received or +collected. Examples: 120, <1, POS." +--ORRESU ,Original Units ,Char ,"Variable +Qualifier of +--ORRES","Unit for --ORRES. Examples: IN, LB, kg/L." +--ORNRLO ,"Normal Range +Lower Limit +Original Units",Char ,"Variable +Qualifier of +--ORRES","Lower end of normal range or reference range for results stored +in --ORRES." +--ORNRHI ,"Normal Range +Upper Limit +Original Units",Char ,"Variable +Qualifier of +--ORRES","Upper end of normal range or reference range for results stored +in --ORRES." +--STRESC ,"Result or Finding +in Standard Format",Char ,"Result +Qualifier","Contains the result value for all findings, copied or derived from +--ORRES in a standard format or in standard units. --STRESC +should store all results or findings in character format; if results +are numeric, they should also be stored in numeric format in -- +STRESN. For example, if various tests have results “NONE”, +“NEG”, and “NEGATIVE” in --ORRES and these results +effectively have the same meaning, they could be represented in +standard format in --STRESC as ""NEGATIVE""." +--STRESN ,"Numeric +Result/Finding in +Standard Units",Num ,"Result +Qualifier","Used for continuous or numeric results or findings in standard +format; copied in numeric format from --STRESC. --STRESN +should store all numeric test results or findings." +--STRESU ,Standard Units ,Char ,"Variable +Qualifier of +--STRESC and +--STRESN","Standardized units used for --STRESC and --STRESN. +Example: mol/L." +--STNRLO ,"Normal Range +Lower Limit +Standard Units",Num ,"Variable +Qualifier of +--STRESC and +--STRESN","Lower end of normal range or reference range for standardized +results (e.g., --STRESC, --STRESN) represented in +standardized units (--STRESU)." +--STNRHI ,"Normal Range +Upper Limit +Standard Units",Num ,"Variable +Qualifier of +--STRESC and +--STRESN","Upper end of normal range or reference range for standardized +results (e.g., --STRESC, --STRESN) represented in +standardized units (--STRESU)." +--STNRC ,"Normal Range for +Character Results",Char ,"Variable +Qualifier of +--STRESC","Normal range or reference range for results stored in --STRESC +that are character in ordinal or categorical scale. Example: +Negative to Trace." +--NRIND ,"Normal/Reference +Range Indicator",Char ,"Variable +Qualifier of +--ORRES","Used to indicate the value is outside the normal range or +reference range. May be defined by --ORNRLO and --ORNRHI +or other objective criteria. Examples: Y, N; HIGH, LOW; +NORMAL; ABNORMAL." +--RESCAT ,Result Category ,Char ,"Variable +Qualifier of +--ORRES","Used to categorize the result of a finding. Example: +MALIGNANT or BENIGN for tumor findings. RESISTANCE +VARIANT for genetic variation." +--STAT ,Completion Status ,Char ,"Record +Qualifier","Used to indicate that a question was not asked or a test was not +done, or a test was attempted but did not generate a result. +Should be null or have a value of NOT DONE." +--REASND ,Reason Not Done ,Char ,"Record +Qualifier","Reason not done. Used in conjunction with --STAT when value +is NOT DONE." +--XFN ,External File Path ,Char ,"Record +Qualifier","Filename for an external file, such as one for an ECG waveform +or a medical image." +--NAM ,"Laboratory/Vendor +Name",Char ,"Record +Qualifier","Name or identifier of the vendor (e.g., laboratory) that provided +the test results." +--LOINC ,LOINC Code ,Char ,"Synonym +Qualifier of +--TESTCD","Logical Observation Identifiers Names and Codes (LOINC) +code for the topic variable such as a lab test." +--SPEC ,"Specimen Material +Type",Char ,"Record +Qualifier","Defines the type of specimen used for a measurement. +Examples: SERUM, PLASMA, URINE, DNA, RNA." +--ANTREG ,Anatomical Region ,Char ,"Variable +Qualifier of +--SPEC","Defines the specific anatomical or biological region of a tissue, +organ specimen or the region from which the specimen is +obtained, as defined in the protocol, such as a section or part of +what is described in the --SPEC variable. Examples: CORTEX, +MEDULLA, MUCOSA" +--SPCCND ,"Specimen +Condition",Char ,"Record +Qualifier",Defines the condition of the specimen. Example: CLOUDY. +--SPCUFL ,"Specimen +Usability for the +Test",Char ,"Record +Qualifier","Describes the usability of the specimen for the test. The value +will be N if the specimen is not usable, and null if the specimen +is usable." +--LOC ,"Location Used for +the Measurement",Char ,"Record +Qualifier","Anatomical location of the subject relevant to the collection of +the measurement. Examples: RECTAL for temperature, ARM +for blood pressure." +--LAT ,Laterality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing +laterality. Examples: RIGHT, LEFT, BILATERAL" +--DIR ,Directionality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing +directionality. Examples: ANTERIOR, LOWER, PROXIMAL" +--PORTOT ,Portion or Totality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing +the distribution, which means arrangement of, apportioning of. . +Examples: ENTIRE, SINGLE, SEGMENT, MANY." +--METHOD ,"Method of Test or +Examination",Char ,"Record +Qualifier","Method of the test or examination. Examples: EIA (Enzyme +Immunoassay), ELECTROPHORESIS, DIPSTICK" +--RUNID ,Run ID ,Char ,"Record +Qualifier","A unique identifier for a particular run of a test on a particular +batch of samples." +--ANMETH ,Analysis Method ,Char ,"Record +Qualifier","Analysis method applied to obtain a summarized result. +Analysis method describes the method of secondary processing +applied to a complex observation result (e.g. an image or a +genetic sequence)." +--LEAD ,"Lead Identified to +Collect +Measurements",Char ,"Record +Qualifier","Lead or leads identified to capture the measurement for a test +from an instrument. Examples: LEAD I, LEAD V2, LEAD +CM5." +--CSTATE ,"Consciousness +State",Char ,"Record +Qualifier","The consciousness state of the subject at the time of +measurement. Examples: CONSCIOUS, SEMI-CONSCIOUS, +UNCONSCIOUS" +--BLFL ,Baseline Flag ,Char ,"Record +Qualifier",Indicator used to identify a baseline value. Should be Y or null. +--FAST ,Fasting Status ,Char ,"Record +Qualifier","Indicator used to identify fasting status. Valid values include Y, +N, U or null if not relevant." +--DRVFL ,Derived Flag ,Char ,"Record +Qualifier","Used to indicate a derived record (e.g., a record that represents +the average of other records such as a computed baseline). +Should be Y or null." +--EVAL ,Evaluator ,Char ,"Record +Qualifier","Role of the person who provided the evaluation. Used only for +results that are subjective (e.g., assigned by a person or a +group). Examples: ADJUDICATION COMMITTEE, +INDEPENDENT ASSESSOR, RADIOLOGIST." +--EVALID ,"Evaluator +Identifier",Char ,"Variable +Qualifier of +--EVAL","Used to distinguish multiple evaluators with the same role +recorded in --EVAL. Examples: RADIOLOGIST1 or +RADIOLOGIST2" +--ACPTFL ,"Accepted Record +Flag",Char ,"Record +Qualifier","In cases where more than one assessor provides an evaluation of +a result or response, this flag identifies the record that is +considered, by an independent assessor, to be the accepted +evaluation. Expected to be Y or null." +--TOX ,Toxicity ,Char ,"Variable +Qualifier of +--TOXGR","Description of toxicity quantified by --TOXGR such as NCI +CTCAE Short Name. Examples: HYPERCALCEMIA, +HYPOCALCEMIA. Sponsor should specify which scale and +version is used in the Sponsor Comments column of the Define +XML document." +--TOXGR ,Toxicity Grade ,Char ,"Record +Qualifier","Records toxicity grade using a standard toxicity scale (such as +the NCI CTCAE). Sponsor should specify which scale and +version is used in the Sponsor Comments column of the Define +data definition document. Example: 2." +--SEV ,Severity ,Char ,"Record +Qualifier","Describes the severity or intensity of a particular finding. +Examples: MILD, MODERATE, SEVERE." +--DTHREL ,"Relationship to +Death",Char ,"Record +Qualifier","Describes the relationship of a particular finding to the death of +a subject. Examples: Y, N or U." +--LLOQ ,"Lower Limit of +Quantitation",Num ,"Variable +Qualifier of +--STRESC and +--STRESN","Indicates the lower limit of quantitation for an assay. Units will +be those used for --STRESU." +--ULOQ ,"Upper Limit of +Quantitation",Num ,"Variable +Qualifier of +--STRESC and +--STRESN","Indicates the upper limit of quantitation for an assay. Units will +be those used for --STRESU." +--EXCLFL ,"Exclude from +Statistics",Char ,"Record +Qualifier","Indicates whether the values in the result variables for this +record should be excluded from summary statistical calculations +such as Mean, Standard Deviation, and Count (and others). +Expected to be Y or null. --EXCLFL should not be used when - +-STAT is NOT DONE. Not to be used with human clinical +trials." +--REASEX ,"Reason for +Exclusion from +Statistics",Char ,"Record +Qualifier","Reason excluded from statistics. Used in conjunction with -- +EXCLFL when its value is Y. Not to be used with human +clinical trials" diff --git a/data-raw/ig_source/sdtm_model/1.5/Findings_Observation_Class.csv b/data-raw/ig_source/sdtm_model/1.5/Findings_Observation_Class.csv new file mode 100644 index 0000000..7d7a730 --- /dev/null +++ b/data-raw/ig_source/sdtm_model/1.5/Findings_Observation_Class.csv @@ -0,0 +1,305 @@ +"Variable +Name ",Variable Label ,Type ,Role ,Description +Topic Variable,,,, +--TESTCD ,"Short Name of +Measurement, Test or +Examination",Char ,Topic ,"Short character value for --TEST used as a column name when +converting a dataset from a vertical format to a horizontal format. +The short value can be up to 8 characters. Examples: PLAT, +SYSBP, RRMIN, EYEEXAM." +Qualifier Variables,,,, +--TEST ,"Name of +Measurement, Test or +Examination",Char ,"Synonym +Qualifier of +--TESTCD","Long name For --TESTCD. Examples: Platelet, Systolic Blood +Pressure, Summary (Min) RR Duration, Eye Examination." +--MODIFY ,Modified Term ,Char ,"Synonym +Qualifier of +--ORRES","If the value of --ORRES is modified for coding purposes, then the +modified text is placed here." +--TSTDTL ,"Measurement, Test or +Examination Detail",Char ,"Variable +Qualifier of +--TESTCD +and --TEST","Further description of --TESTCD and --TEST. Example: ""The +percentage of cells with +1 intensity of staining"" when MITEST += Thyroid Transcription Factor 1." +--CAT ,Category ,Char ,"Grouping +Qualifier","Used to define a category of topic-variable values. Examples: +HEMATOLOGY, URINALYSIS, CHEMISTRY, HAMILTON +DEPRESSION SCALE, SF36, EGFR MUTATION ANALYSIS." +--SCAT ,Subcategory ,Char ,"Grouping +Qualifier","Used to define a further categorization of --CAT values. +Example: WBC DIFFERENTIAL." +--POS ,"Position of Subject +During Observation",Char ,"Record +Qualifier","Position of the subject during a measurement or examination. +Examples: SUPINE, STANDING, SITTING." +--BODSYS ,"Body System or +Organ Class",Char ,"Record +Qualifier","Body System or Organ Class that is involved for a finding from +the standard hierarchy for dictionary-coded results. Example: +MedDRA SOC." +--ORRES ,"Result or Finding in +Original Units",Char ,"Result +Qualifier","Result of the measurement or finding as originally received or +collected. Examples: 120, <1, POS." +--ORRESU ,Original Units ,Char ,"Variable +Qualifier of +--ORRES","Unit for --ORRES. Examples: in, LB, kg/L." +--ORNRLO ,"Normal Range Lower +Limit-Original Units",Char ,"Variable +Qualifier of +--ORRES","Lower end of normal range or reference range for results stored in +--ORRES." +--ORNRHI ,"Normal Range Upper +Limit-Original Units",Char ,"Variable +Qualifier of +--ORRES","Upper end of normal range or reference range for results stored in +--ORRES." +--ORREF ,"Reference Result in +Original Units",Char ,"Variable +Qualifier of +--ORRES","Reference value for the result or finding as originally received or +collected. --ORREF uses the same units as --ORRES, if +applicable. Examples: value from predicted normal value in +spirometry tests." +--STRESC ,"Result or Finding in +Standard Format",Char ,"Result +Qualifier","Contains the result value for all findings, copied or derived from +--ORRES in a standard format or in standard units. --STRESC +should store all results or findings in character format; if results +are numeric, they should also be stored in numeric format in +--STRESN. For example, if various tests have results ""NONE"", +""NEG"", and ""NEGATIVE"" in --ORRES and these results +effectively have the same meaning, they could be represented in +standard format in --STRESC as ""NEGATIVE""." +--STRESN ,"Numeric +Result/Finding in +Standard Units",Num ,"Result +Qualifier","Used for continuous or numeric results or findings in standard +format; copied in numeric format from --STRESC. --STRESN +should store all numeric test results or findings." +--STRESU ,Standard Units ,Char ,"Variable +Qualifier of +--STRESC +and +--STRESN","Standardized units used for --STRESC and --STRESN. Example: +mol/L." +--STNRLO ,"Normal Range Lower +Limit-Standard Units",Num ,"Variable +Qualifier of +--STRESC +and +--STRESN","Lower end of normal range or reference range for standardized +results (e.g., --STRESC, --STRESN) represented in standardized +units (-STRESU)." +--STNRHI ,"Normal Range Upper +Limit-Standard Units",Num ,"Variable +Qualifier of +--STRESC +and +--STRESN","Upper end of normal range or reference range for standardized +results (e.g., --STRESC, --STRESN) represented in standardized +units (-STRESU)." +--STNRC ,"Normal Range for +Character Results",Char ,"Variable +Qualifier of +--STRESC","Normal range or reference range for results stored in --STRESC +that are character in ordinal or categorical scale. Example: +Negative to Trace." +--STREFC ,"Reference Result in +Standard Format",Char ,"Variable +Qualifier of +--STRESC","Reference value for the result or finding copied or derived from +--ORREF in a standard format." +--STREFN ,"Numeric Reference +Result in Std Units",Num ,"Variable +Qualifier of +--STRESN","Reference value for continuous or numeric results or findings in +standard format or in standard units. --STREFN uses the same +units as --STRESN, if applicable." +--NRIND ,"Normal/Reference +Range Indicator",Char ,"Variable +Qualifier of +--ORRES","Used to indicate the value is outside the normal range or +reference range. May be defined by --ORNRLO and --ORNRHI +or other objective criteria. Examples: Y, N; HIGH, LOW; +NORMAL; ABNORMAL." +--RESCAT ,Result Category ,Char ,"Variable +Qualifier of +--ORRES","Used to categorize the result of a finding. Example: +MALIGNANT or BENIGN for tumor findings. RESISTANCE +VARIANT for genetic variation." +--CHRON ,Chronicity of Finding ,Char ,"Variable +Qualifier of +--STRESC","Characterization of the duration of a biological process resulting +in a particular finding. Examples: ACUTE, CHRONIC, +SUBACUTE." +--DISTR ,"Distribution Pattern of +Finding",Char ,"Variable +Qualifier of +--STRESC","Description of the distribution pattern of a finding within the +examined area. Examples: FOCAL, MULTIFOCAL, DIFFUSE, +FOCAL MULTIFOCAL." +--STAT ,Completion Status ,Char ,"Record +Qualifier","Used to indicate that a question was not asked or a test was not +done, or a test was attempted but did not generate a result. Should +be null or have a value of NOT DONE." +--REASND ,Reason Not Done ,Char ,"Record +Qualifier","Reason not done. Used in conjunction with --STAT when value is +NOT DONE." +--XFN ,External File Path ,Char ,"Record +Qualifier","Filename for an external file, such as one for an ECG waveform +or a medical image." +--NAM ,"Laboratory/Vendor +Name",Char ,"Record +Qualifier","Name or identifier of the vendor (e.g., laboratory) that provided +the test results." +--LOINC ,LOINC Code ,Char ,"Synonym +Qualifier of +--TESTCD","Logical Observation Identifiers Names and Codes (LOINC) code +for the topic variable such as a lab test." +--SPEC ,"Specimen Material +Type",Char ,"Record +Qualifier","Defines the type of specimen used for a measurement. Examples: +SERUM, PLASMA, URINE, DNA, RNA." +--ANTREG ,Anatomical Region ,Char ,"Variable +Qualifier of +--SPEC","Defines the specific anatomical or biological region of a tissue, +organ specimen or the region from which the specimen is +obtained, as defined in the protocol, such as a section or part of +what is described in the --SPEC variable. Examples: CORTEX, +MEDULLA, MUCOSA" +--SPCCND ,Specimen Condition ,Char ,"Record +Qualifier",Defines the condition of the specimen. Example: CLOUDY. +--SPCUFL ,"Specimen Usability +for the Test",Char ,"Record +Qualifier","Describes the usability of the specimen for the test. The value +will be N if the specimen is not usable, and null if the specimen is +usable." +--LOC ,"Location Used for the +Measurement",Char ,"Record +Qualifier","Anatomical location of the subject relevant to the collection of +the measurement. Examples: RECTAL for temperature, ARM for +blood pressure." +--LAT ,Laterality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing +laterality. Examples: RIGHT, LEFT, BILATERAL" +--DIR ,Directionality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing +directionality. Examples: ANTERIOR, LOWER, PROXIMAL" +--PORTOT ,Portion or Totality ,Char ,"Variable +Qualifier of +--LOC","Qualifier for anatomical location or specimen further detailing the +distribution, which means arrangement of, apportioning of. +Examples: ENTIRE, SINGLE, SEGMENT, MANY." +--METHOD ,"Method of Test or +Examination",Char ,"Record +Qualifier","Method of the test or examination. Examples: EIA (Enzyme +Immunoassay), ELECTROPHORESIS, DIPSTICK" +--RUNID ,Run ID ,Char ,"Record +Qualifier","A unique identifier for a particular run of a test on a particular +batch of samples." +--ANMETH ,Analysis Method ,Char ,"Record +Qualifier","Analysis method applied to obtain a summarized result. Analysis +method describes the method of secondary processing applied to +a complex observation result (e.g. an image or a genetic +sequence)." +--LEAD ,"Lead Identified to +Collect Measurements",Char ,"Record +Qualifier","Lead or leads identified to capture the measurement for a test +from an instrument. Examples: LEAD I, LEAD V2, LEAD CM5." +--CSTATE ,Consciousness State ,Char ,"Record +Qualifier","The consciousness state of the subject at the time of +measurement. Examples: CONSCIOUS, SEMI-CONSCIOUS, +UNCONSCIOUS" +--LOBXFL ,"Last Observation +Before Exposure Flag",Char ,"Record +Qualifier","Operationally-derived indicator used to identify the last non +missing value prior to RFXSTDTC. Should be Y or null." +--BLFL ,Baseline Flag ,Char ,"Record +Qualifier",Indicator used to identify a baseline value. Should be Y or null. +--FAST ,Fasting Status ,Char ,"Record +Qualifier","Indicator used to identify fasting status. Valid values include Y, +N, U or null if not relevant." +--DRVFL ,Derived Flag ,Char ,"Record +Qualifier","Used to indicate a derived record (e.g., a record that represents +the average of other records such as a computed baseline). Should +be Y or null." +--EVAL ,Evaluator ,Char ,"Record +Qualifier","Role of the person who provided the evaluation. Used only for +results that are subjective (e.g., assigned by a person or a group). +Examples: ADJUDICATION COMMITTEE, INDEPENDENT +ASSESSOR, RADIOLOGIST." +--EVALID ,Evaluator Identifier ,Char ,"Variable +Qualifier of +--EVAL","Used to distinguish multiple evaluators with the same role +recorded in --EVAL. Examples: RADIOLOGIST1, +RADIOLOGIST2." +--ACPTFL ,Accepted Record Flag ,Char ,"Record +Qualifier","In cases where more than one assessor provides an evaluation of a +result or response, this flag identifies the record that is considered +to be the accepted evaluation. Expected values can include Y, N +or null. This is not intended to be an analysis flag to indicate +acceptability for a given analysis" +--TOX ,Toxicity ,Char ,"Variable +Qualifier of +--TOXGR","Description of toxicity quantified by --TOXGR such as NCI +CTCAE Short Name. Examples: HYPERCALCEMIA, +HYPOCALCEMIA. Sponsor should specify which scale and +version is used in the Sponsor Comments column of the Define +XML document." +--TOXGR ,Toxicity Grade ,Char ,"Record +Qualifier","Records toxicity grade using a standard toxicity scale (such as the +NCI CTCAE). Sponsor should specify which scale and version is +used in the Sponsor Comments column of the Define data +definition document. Example: 2." +--SEV ,Severity ,Char ,"Record +Qualifier","Describes the severity or intensity of a particular finding. +Examples: MILD, MODERATE, SEVERE." +--DTHREL ,Relationship to Death ,Char ,"Record +Qualifier","Describes the relationship of a particular finding to the death of a +subject. Examples: Y, N or U. Not to be used with human clinical +trials." +--LLOQ ,"Lower Limit of +Quantitation",Num ,"Variable +Qualifier of +--STRESC +and +--STRESN","Indicates the lower limit of quantitation for an assay. Units will +be those used for --STRESU." +--ULOQ ,"Upper Limit of +Quantitation",Num ,"Variable +Qualifier of +--STRESC +and +--STRESN","Indicates the upper limit of quantitation for an assay. Units will +be those used for --STRESU." +--EXCLFL ,"Exclude from +Statistics",Char ,"Record +Qualifier","Indicates whether the values in the result variables for this record +should be excluded from summary statistical calculations such as +Mean, Standard Deviation, and Count (and others). Expected to +be Y or null. --EXCLFL should not be used when --STAT is +NOT DONE. Not to be used with human clinical trials." +--REASEX ,"Reason for Exclusion +from Statistics",Char ,"Record +Qualifier","Reason excluded from statistics. Used in conjunction with +--EXCLFL when its value is Y. Not to be used with human +clinical trials." +--USCHFL ,Unscheduled Flag ,Char ,"Record +Qualifier","Indicates whether the timing of a performed test or observation +was unscheduled. If a test or observation was performed based +upon a schedule defined in the protocol, this flag should be null. +Expected values are Y or null. Not to be used with human clinical +trials. This variable would not be needed when information on planned assessments is provided, such as when the Trial Visits +(TV) and Subject Visits (SV) domains are used." +--REPNUM ,Repetition Number ,Num ,"Record +Qualifier","The instance number of a test that is repeated within a given +timeframe for the same test. The level of granularity can vary, +e.g., within a time point or within a visit. For example, multiple +measurements of blood pressure or multiple analyses of a sample." diff --git a/data-raw/ig_source/sdtm_model/1.6/Findings_Observation_Class.csv b/data-raw/ig_source/sdtm_model/1.6/Findings_Observation_Class.csv new file mode 100644 index 0000000..53d28e5 --- /dev/null +++ b/data-raw/ig_source/sdtm_model/1.6/Findings_Observation_Class.csv @@ -0,0 +1,64 @@ +Variable Name,Variable Label,Type,Role,Description +Topic Variable,,,, +--TESTCD,"Short Name of Measurement, Test or Examination",Char,Topic,"Short character value for --TEST used as a column name when converting a dataset from a vertical format to a horizontal format. The short value can be up to 8 characters. Examples: PLAT, SYSBP, RRMIN, EYEEXAM." +Qualifier Variables,,,, +--TEST,"Name of Measurement, Test or Examination",Char,Synonym Qualifier of --TESTCD,"Long name For --TESTCD. Examples: Platelet, Systolic Blood Pressure, Summary (Min) RR Duration, Eye Examination." +--MODIFY,Modified Term,Char,Synonym Qualifier of --ORRES,"If the value of --ORRES is modified for coding purposes, then the modified text is placed here." +--TSTDTL,"Measurement, Test or Examination Detail",Char,Variable Qualifier of --TESTCD and --TEST,"Further description of --TESTCD and --TEST. Example: ""The percentage of cells with +1 intensity of staining"" when MITEST = Thyroid Transcription Factor 1." +--CAT,Category,Char,Grouping Qualifier,"Used to define a category of topic-variable values. Examples: HEMATOLOGY, URINALYSIS, CHEMISTRY, HAMD 17, SF36 V2.0 ACUTE, EGFR MUTATION ANALYSIS." +--SCAT,Subcategory,Char,Grouping Qualifier,Used to define a further categorization of --CAT values. Example: WBC DIFFERENTIAL. +--POS,Position of Subject During Observation,Char,Record Qualifier,"Position of the subject during a measurement or examination. Examples: SUPINE, STANDING, SITTING." +--BODSYS,Body System or Organ Class,Char,Record Qualifier,Body System or Organ Class that is involved for a finding from the standard hierarchy for dictionary-coded results. Example: MedDRA SOC. +--ORRES,Result or Finding in Original Units,Char,Result Qualifier,"Result of the measurement or finding as originally received or collected. Examples: 120, <1, POS." +--ORRESU,Original Units,Char,Variable Qualifier of --ORRES,"Unit for --ORRES. Examples: in, LB, kg/L." +--ORNRLO,Normal Range Lower Limit-Original Units,Char,Variable Qualifier of --ORRES,Lower end of normal range or reference range for results stored in --ORRES. +--ORNRHI,Normal Range Upper Limit-Original Units,Char,Variable Qualifier of --ORRES,Upper end of normal range or reference range for results stored in --ORRES. +--ORREF,Reference Result in Original Units,Char,Variable Qualifier of --ORRES,"Reference value for the result or finding as originally received or collected. --ORREF uses the same units as --ORRES, if applicable. Examples: value from predicted normal value in spirometry tests." +--STRESC,Result or Finding in Standard Format,Char,Result Qualifier,"Contains the result value for all findings, copied or derived from --ORRES in a standard format or in standard units. --STRESC should store all results or findings in character format; if results are numeric, they should also be stored in numeric format in --STRESN. For example, if various tests have results ""NONE"", ""NEG"", and ""NEGATIVE"" in --ORRES and these results effectively have the same meaning, they could be represented in standard format in --STRESC as ""NEGATIVE""." +--STRESN,Numeric Result/Finding in Standard Units,Num,Result Qualifier,Used for continuous or numeric results or findings in standard format; copied in numeric format from --STRESC. --STRESN should store all numeric test results or findings. +--STRESU,Standard Units,Char,Variable Qualifier of --STRESC and --STRESN,Standardized units used for --STRESC and --STRESN. Example: mol/L. +--STNRLO,Normal Range Lower Limit-Standard Units,Num,Variable Qualifier of --STRESC and --STRESN,"Lower end of normal range or reference range for standardized results (e.g., --STRESC, --STRESN) represented in standardized units (--STRESU)." +--STNRHI,Normal Range Upper Limit-Standard Units,Num,Variable Qualifier of --STRESC and --STRESN,"Upper end of normal range or reference range for standardized results (e.g., --STRESC, --STRESN) represented in standardized units (--STRESU)." +--STNRC,Normal Range for Character Results,Char,Variable Qualifier of --STRESC,Normal range or reference range for results stored in --STRESC that are character in ordinal or categorical scale. Example: Negative to Trace. +--STREFC,Reference Result in Standard Format,Char,Variable Qualifier of --STRESC,Reference value for the result or finding copied or derived from --ORREF in a standard format. +--STREFN,Numeric Reference Result in Std Units,Num,Variable Qualifier of --STRESN,"Reference value for continuous or numeric results or findings in standard format or in standard units. --STREFN uses the same units as --STRESN, if applicable." +--NRIND,Normal/Reference Range Indicator,Char,Variable Qualifier of --ORRES,"Used to indicate the value is outside the normal range or reference range. May be defined by --ORNRLO and --ORNRHI or other objective criteria. Examples: Y, N; HIGH, LOW; NORMAL; ABNORMAL." +--RESCAT,Result Category,Char,Variable Qualifier of --ORRES,Used to categorize the result of a finding. Example: MALIGNANT or BENIGN for tumor findings. RESISTANCE VARIANT for genetic variation. +--CHRON,Chronicity of Finding,Char,Variable Qualifier of --STRESC,"Characterization of the duration of a biological process resulting in a particular finding. Examples: ACUTE, CHRONIC, SUBACUTE." +--DISTR,Distribution Pattern of Finding,Char,Variable Qualifier of --STRESC,"Description of the distribution pattern of a finding within the examined area. Examples: FOCAL, MULTIFOCAL, DIFFUSE, FOCAL MULTIFOCAL." +--RESLOC,Result Location of Finding,Char,Result Qualifier,Location where the result was observed (as opposed to the location specified for examination). This location may have a higher degree of specificity than the location specified for examination. Not to be used with human clinical trials. +--STAT,Completion Status,Char,Record Qualifier,"Used to indicate that a question was not asked or a test was not done, or a test was attempted but did not generate a result. Should be null or have a value of NOT DONE." +--REASND,Reason Not Done,Char,Record Qualifier,Reason not done. Used in conjunction with --STAT when value is NOT DONE. +--XFN,External File Path,Char,Record Qualifier,"Filename for an external file, such as one for an ECG waveform or a medical image." +--NAM,Laboratory/Vendor Name,Char,Record Qualifier,"Name or identifier of the vendor (e.g., laboratory) that provided the test results." +--LOINC,LOINC Code,Char,Synonym Qualifier of --TESTCD,Logical Observation Identifiers Names and Codes (LOINC) code for the topic variable such as a lab test. +--SPEC,Specimen Material Type,Char,Record Qualifier,"Defines the type of specimen used for a measurement. Examples: SERUM, PLASMA, URINE, DNA, RNA." +--ANTREG,Anatomical Region,Char,Variable Qualifier of --SPEC,"Defines the specific anatomical or biological region of a tissue, organ specimen or the region from which the specimen is obtained, as defined in the protocol, such as a section or part of what is described in the --SPEC variable. Examples: CORTEX, MEDULLA, MUCOSA." +--SPCCND,Specimen Condition,Char,Record Qualifier,Defines the condition of the specimen. Example: CLOUDY. +--SPCUFL,Specimen Usability for the Test,Char,Record Qualifier,"Describes the usability of the specimen for the test. The value will be N if the specimen is not usable, and null if the specimen is usable." +--LOC,Location Used for the Measurement,Char,Record Qualifier,"Anatomical location of the subject relevant to the collection of the measurement. Examples: RECTAL for temperature, ARM for blood pressure." +--LAT,Laterality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing laterality. Examples: RIGHT, LEFT, BILATERAL." +--DIR,Directionality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing directionality. Examples: ANTERIOR, LOWER, PROXIMAL." +--PORTOT,Portion or Totality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing the distribution, which means arrangement of, apportioning of. Examples: ENTIRE, SINGLE, SEGMENT, MANY." +--METHOD,Method of Test or Examination,Char,Record Qualifier,"Method of the test or examination. Examples: EIA (Enzyme Immunoassay), ELECTROPHORESIS, DIPSTICK." +--RUNID,Run ID,Char,Record Qualifier,A unique identifier for a particular run of a test on a particular batch of samples. +--ANMETH,Analysis Method,Char,Record Qualifier,Analysis method applied to obtain a summarized result. Analysis method describes the method of secondary processing applied to a complex observation result (e.g. an image or a genetic sequence). +--LEAD,Lead Identified to Collect Measurements,Char,Record Qualifier,"Lead or leads identified to capture the measurement for a test from an instrument. Examples: LEAD I, LEAD V2, LEAD CM5." +--CSTATE,Consciousness State,Char,Record Qualifier,"The consciousness state of the subject at the time of measurement. Examples: CONSCIOUS, SEMI-CONSCIOUS, UNCONSCIOUS." +--LOBXFL,Last Observation Before Exposure Flag,Char,Record Qualifier,Operationally-derived indicator used to identify the last non-missing value prior to RFXSTDTC. Should be Y or null. +--BLFL,Baseline Flag,Char,Record Qualifier,Indicator used to identify a baseline value. Should be Y or null. +--FAST,Fasting Status,Char,Record Qualifier,"Indicator used to identify fasting status. Valid values include Y, N, U, or null if not relevant." +--DRVFL,Derived Flag,Char,Record Qualifier,"Used to indicate a derived record (e.g., a record that represents the average of other records such as a computed baseline). Should be Y or null." +--EVAL,Evaluator,Char,Record Qualifier,"Role of the person who provided the evaluation. Used only for results that are subjective (e.g., assigned by a person or a group). Examples: ADJUDICATION COMMITTEE, INDEPENDENT ASSESSOR, RADIOLOGIST." +--EVALID,Evaluator Identifier,Char,Variable Qualifier of --EVAL,"Used to distinguish multiple evaluators with the same role recorded in --EVAL. Examples: RADIOLOGIST1, RADIOLOGIST2." +--ACPTFL,Accepted Record Flag,Char,Record Qualifier,"In cases where more than one assessor provides an evaluation of a result or response, this flag identifies the record that is considered to be the accepted evaluation. Expected values can include Y, N or null. This is not intended to be an analysis flag to indicate acceptability for a given analysis." +--TOX,Toxicity,Char,Variable Qualifier of --TOXGR,"Description of toxicity quantified by --TOXGR such as NCI CTCAE Short Name. Examples: HYPERCALCEMIA, HYPOCALCEMIA. Sponsor should specify which scale and version is used in the Sponsor Comments column of the Define-XML document." +--TOXGR,Toxicity Grade,Char,Record Qualifier,Records toxicity grade using a standard toxicity scale (such as the NCI CTCAE). Sponsor should specify which scale and version is used in the Sponsor Comments column of the Define data definition document. Example: 2. +--SEV,Severity,Char,Record Qualifier,"Describes the severity or intensity of a particular finding. Examples: MILD, MODERATE, SEVERE." +--DTHREL,Relationship to Death,Char,Record Qualifier,"Describes the relationship of a particular finding to the death of a subject. Examples: Y, N, or U. Not to be used with human clinical trials." +--LLOQ,Lower Limit of Quantitation,Num,Variable Qualifier of --STRESC and --STRESN,Indicates the lower limit of quantitation for an assay. Units will be those used for --STRESU. +--ULOQ,Upper Limit of Quantitation,Num,Variable Qualifier of --STRESC and --STRESN,Indicates the upper limit of quantitation for an assay. Units will be those used for --STRESU. +--EXCLFL,Exclude from Statistics,Char,Record Qualifier,"Indicates whether the values in the result variables for this record should be excluded from summary statistical calculations such as Mean, Standard Deviation, and Count (and others). Expected to be Y or null. --EXCLFL should not be used when --STAT is NOT DONE. Not to be used with human clinical trials." +--REASEX,Reason for Exclusion from Statistics,Char,Record Qualifier,Reason excluded from statistics. Used in conjunction with --EXCLFL when its value is Y. Not to be used with human clinical trials. +--USCHFL,Unscheduled Flag,Char,Record Qualifier,"Indicates whether the timing of a performed test or observation was unscheduled. If a test or observation was performed based upon a schedule defined in the protocol, this flag should be null. Expected values are Y or null. Not to be used with human clinical trials. This variable would not be needed when information on planned assessments is provided, such as when the Trial Visits (TV) and Subject Visits (SV) domains are used." +--REPNUM,Repetition Number,Num,Record Qualifier,"The instance number of a test that is repeated within a given timeframe for the same test. The level of granularity can vary, e.g., within a time point or within a visit. For example, multiple measurements of blood pressure or multiple analyses of a sample." diff --git a/data-raw/ig_source/sdtm_model/1.7/Findings_Observation_Class.csv b/data-raw/ig_source/sdtm_model/1.7/Findings_Observation_Class.csv new file mode 100644 index 0000000..d376467 --- /dev/null +++ b/data-raw/ig_source/sdtm_model/1.7/Findings_Observation_Class.csv @@ -0,0 +1,64 @@ +Variable Name,Variable Label,Type,Role,Description +Topic Variable,,,, +--TESTCD,"Short Name of Measurement, Test, or Exam",Char,Topic,"Short character value for --TEST used as a column name when converting a dataset from a vertical format to a horizontal format. The short value can be up to 8 characters. Examples: ""PLAT"", ""SYSBP"", ""RRMIN"", ""EYEEXAM""." +Qualifier Variables,,,, +--TEST,"Name of Measurement, Test, or Exam",Char,Synonym Qualifier of --TESTCD,"Long name For --TESTCD. Examples: Platelets, Systolic Blood Pressure, Summary (Min) RR Duration, Eye Examination." +--MODIFY,Modified Term,Char,Synonym Qualifier of --ORRES,"If the value of --ORRES is modified for coding purposes, then the modified text is placed here." +--TSTDTL,"Measurement, Test, or Examination Detail",Char,Variable Qualifier of --TESTCD and --TEST,"Further description of --TESTCD and --TEST. Example: ""The percentage of cells with +1 intensity of staining"" when MITEST = ""Thyroid Transcription Factor 1""." +--CAT,Category,Char,Grouping Qualifier,"Used to define a category of topic-variable values. Examples: ""HEMATOLOGY"", ""URINALYSIS"", ""CHEMISTRY"", ""HAMD 17"", ""SF36 V2.0 ACUTE"", ""EGFR MUTATION ANALYSIS""." +--SCAT,Subcategory,Char,Grouping Qualifier,"Used to define a further categorization of --CAT values. Example: ""WBC DIFFERENTIAL""." +--POS,Position of Subject During Observation,Char,Record Qualifier,"Position of the subject during a measurement or examination. Examples: ""SUPINE"", ""STANDING"", ""SITTING""." +--BODSYS,Body System or Organ Class,Char,Record Qualifier,Body System or Organ Class that is involved for a finding from the standard hierarchy for dictionary-coded results. Example: MedDRA SOC. +--ORRES,Result or Finding in Original Units,Char,Result Qualifier,"Result of the measurement or finding as originally received or collected. Examples: ""120"", ""<1"", ""POS""." +--ORRESU,Original Units,Char,Variable Qualifier of --ORRES and --ORREF,"Unit for --ORRES and --ORREF. Examples: ""in"", ""LB"", ""kg/L""." +--ORNRLO,Normal Range Lower Limit-Original Units,Char,Variable Qualifier of --ORRES,Lower end of normal range or reference range for results stored in --ORRES. +--ORNRHI,Normal Range Upper Limit-Original Units,Char,Variable Qualifier of --ORRES,Upper end of normal range or reference range for results stored in --ORRES. +--ORREF,Reference Result in Original Units,Char,Variable Qualifier of --ORRES,"Reference value for the result or finding as originally received or collected. --ORREF uses the same units as --ORRES, if applicable. Examples: value from predicted normal value in spirometry tests." +--STRESC,Result or Finding in Standard Format,Char,Result Qualifier,"Contains the result value for all findings, copied or derived from --ORRES in a standard format or in standard units. --STRESC should store all results or findings in character format; if results are numeric, they should also be stored in numeric format in --STRESN. For example, if various tests have results ""NONE"", ""NEG"", and ""NEGATIVE"" in --ORRES and these results effectively have the same meaning, they could be represented in standard format in --STRESC as ""NEGATIVE""." +--STRESN,Numeric Result/Finding in Standard Units,Num,Result Qualifier,Used for continuous or numeric results or findings in standard format; copied in numeric format from --STRESC. --STRESN should store all numeric test results or findings. +--STRESU,Standard Units,Char,Variable Qualifier of --STRESC and --STRESN and --STREFC and --STREFN,"Standardized units used for --STRESC, --STRESN, --STREFC, and --STREFN. Example: ""mol/L""." +--STNRLO,Normal Range Lower Limit-Standard Units,Num,Variable Qualifier of --STRESC and --STRESN,"Lower end of normal range or reference range for standardized results (e.g., --STRESC, --STRESN) represented in standardized units (--STRESU)." +--STNRHI,Normal Range Upper Limit-Standard Units,Num,Variable Qualifier of --STRESC and --STRESN,"Upper end of normal range or reference range for standardized results (e.g., --STRESC, --STRESN) represented in standardized units (--STRESU)." +--STNRC,Normal Range for Character Results,Char,Variable Qualifier of --STRESC,"Normal range or reference range for results stored in --STRESC that are character in ordinal or categorical scale. Example: ""Negative to Trace""." +--STREFC,Reference Result in Standard Format,Char,Variable Qualifier of --STRESC,Reference value for the result or finding copied or derived from --ORREF in a standard format. +--STREFN,Numeric Reference Result in Std Units,Num,Variable Qualifier of --STRESN,"Reference value for continuous or numeric results or findings in standard format or in standard units. --STREFN uses the same units as --STRESN, if applicable." +--NRIND,Normal/Reference Range Indicator,Char,Variable Qualifier of --ORRES,"Used to indicate the value is outside the normal range or reference range. May be defined by --ORNRLO and --ORNRHI or other objective criteria. Examples: ""Y"", ""N""; ""HIGH"", ""LOW""; ""NORMAL"", ""ABNORMAL""." +--RESCAT,Result Category,Char,Variable Qualifier of --ORRES,"Used to categorize the result of a finding. Example: ""MALIGNANT"" or ""BENIGN"" for tumor findings." +--CHRON,Chronicity of Finding,Char,Variable Qualifier of --STRESC,"Characterization of the duration of a biological process resulting in a particular finding. Examples: ""ACUTE"", ""CHRONIC"", ""SUBACUTE""." +--DISTR,Distribution Pattern of Finding,Char,Variable Qualifier of --STRESC,"Description of the distribution pattern of a finding within the examined area. Examples: ""FOCAL"", ""MULTIFOCAL"", ""DIFFUSE"", ""FOCAL"", ""MULTIFOCAL""." +--RESLOC,Result Location of Finding,Char,Result Qualifier,Location where the result was observed (as opposed to the location specified for examination). This location may have a higher degree of specificity than the location specified for examination. Not to be used with human clinical trials. +--STAT,Completion Status,Char,Record Qualifier,"Used to indicate that a question was not asked or a test was not done, or a test was attempted but did not generate a result. Should be null or have a value of ""NOT DONE""." +--REASND,Reason Not Done,Char,Record Qualifier,"Reason not done. Used in conjunction with --STAT when value is ""NOT DONE""." +--XFN,External File Path,Char,Record Qualifier,"Filename for an external file, such as one for an ECG waveform or a medical image." +--NAM,Laboratory/Vendor Name,Char,Record Qualifier,"Name or identifier of the vendor (e.g., laboratory) that provided the test results." +--LOINC,LOINC Code,Char,Synonym Qualifier of --TESTCD,Logical Observation Identifiers Names and Codes (LOINC) code for the topic variable such as a lab test. +--SPEC,Specimen Material Type,Char,Record Qualifier,"Defines the type of specimen used for a measurement. Examples: ""SERUM"", ""PLASMA"", ""URINE"", ""DNA"", ""RNA""." +--ANTREG,Anatomical Region,Char,Variable Qualifier of --SPEC,"Defines the specific anatomical or biological region of a tissue, organ specimen or the region from which the specimen is obtained, as defined in the protocol, such as a section or part of what is described in the --SPEC variable. Examples: ""CORTEX"", ""MEDULLA"", ""MUCOSA""." +--SPCCND,Specimen Condition,Char,Record Qualifier,"Defines the condition of the specimen. Example: ""CLOUDY""." +--SPCUFL,Specimen Usability for the Test,Char,Record Qualifier,"Describes the usability of the specimen for the test. The value will be ""N"" if the specimen is not usable, and null if the specimen is usable." +--LOC,Location Used for the Measurement,Char,Record Qualifier,"Anatomical location of the subject relevant to the collection of the measurement. Examples: ""RECTAL"" for temperature, ""ARM"" for blood pressure." +--LAT,Laterality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing laterality. Examples: ""RIGHT"", ""LEFT"", ""BILATERAL""." +--DIR,Directionality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing directionality. Examples: ""ANTERIOR"", ""LOWER"", ""PROXIMAL""." +--PORTOT,Portion or Totality,Char,Variable Qualifier of --LOC,"Qualifier for anatomical location or specimen further detailing the distribution, which means arrangement of, apportioning of. Examples: ""ENTIRE"", ""SINGLE"", ""SEGMENT"", ""MANY""." +--METHOD,Method of Test or Examination,Char,Record Qualifier,"Method of the test or examination. Examples: ""EIA"" (enzyme immunoassay), ""ELECTROPHORESIS"", ""DIPSTICK""." +--RUNID,Run ID,Char,Record Qualifier,A unique identifier for a particular run of a test on a particular batch of samples. +--ANMETH,Analysis Method,Char,Record Qualifier,"Analysis method applied to obtain a summarized result. Analysis method describes the method of secondary processing applied to a complex observation result (e.g., an image or a genetic sequence)." +--LEAD,Lead Identified to Collect Measurements,Char,Record Qualifier,"Lead or leads identified to capture the measurement for a test from an instrument. Examples: ""LEAD I"", ""LEAD V2"", ""LEAD CM5""." +--CSTATE,Consciousness State,Char,Record Qualifier,"The consciousness state of the subject at the time of measurement. Examples: ""CONSCIOUS"", ""SEMI-CONSCIOUS"", ""UNCONSCIOUS""." +--LOBXFL,Last Observation Before Exposure Flag,Char,Record Qualifier,"Operationally-derived indicator used to identify the last non-missing value prior to RFXSTDTC. Should be ""Y"" or null." +--BLFL,Baseline Flag,Char,Record Qualifier,"Indicator used to identify a baseline value. Should be ""Y"" or null." +--FAST,Fasting Status,Char,Record Qualifier,"Indicator used to identify fasting status. Valid values include ""Y"", ""N"", ""U"", or null if not relevant." +--DRVFL,Derived Flag,Char,Record Qualifier,"Used to indicate a derived record (e.g., a record that represents the average of other records such as a computed baseline). Should be ""Y"" or null." +--EVAL,Evaluator,Char,Record Qualifier,"Role of the person who provided the evaluation. Used only for results that are subjective (e.g., assigned by a person or a group). Examples: ""ADJUDICATION COMMITTEE"", ""INDEPENDENT ASSESSOR"", ""RADIOLOGIST""." +--EVALID,Evaluator Identifier,Char,Variable Qualifier of --EVAL,"Used to distinguish multiple evaluators with the same role recorded in --EVAL. Examples: ""RADIOLOGIST1"", ""RADIOLOGIST2""." +--ACPTFL,Accepted Record Flag,Char,Record Qualifier,"In cases where more than one assessor provides an evaluation of a result or response, this flag identifies the record that is considered to be the accepted evaluation. Expected values can include ""Y"", ""N"", or null. This is not intended to be an analysis flag to indicate acceptability for a given analysis." +--TOX,Toxicity,Char,Variable Qualifier of --TOXGR,"Description of toxicity quantified by --TOXGR such as NCI CTCAE Short Name. Examples: ""HYPERCALCEMIA"", ""HYPOCALCEMIA"". Sponsor should specify which scale and version is used in the Sponsor Comments column of the Define-XML document." +--TOXGR,Toxicity Grade,Char,Record Qualifier,Records toxicity grade using a standard toxicity scale (such as the NCI CTCAE). Sponsor should specify which scale and version is used in the Sponsor Comments column of the Define data definition document. Example: 2. +--SEV,Severity,Char,Record Qualifier,"Describes the severity or intensity of a particular finding. Examples: ""MILD"", ""MODERATE"", ""SEVERE""." +--DTHREL,Relationship to Death,Char,Record Qualifier,"Describes the relationship of a particular finding to the death of a subject. Examples: ""Y"", ""N"", or ""U"". Not to be used with human clinical trials." +--LLOQ,Lower Limit of Quantitation,Num,Variable Qualifier of --STRESC and --STRESN,Indicates the lower limit of quantitation for an assay. Units will be those used for --STRESU. +--ULOQ,Upper Limit of Quantitation,Num,Variable Qualifier of --STRESC and --STRESN,Indicates the upper limit of quantitation for an assay. Units will be those used for --STRESU. +--EXCLFL,Exclude from Statistics,Char,Record Qualifier,"Indicates whether the values in the result variables for this record should be excluded from summary statistical calculations such as Mean, Standard Deviation, and Count (and others). Expected to be Y or null. --EXCLFL should not be used when --STAT is ""NOT DONE"". Not to be used with human clinical trials." +--REASEX,Reason for Exclusion from Statistics,Char,Record Qualifier,"Reason excluded from statistics. Used in conjunction with --EXCLFL when its value is ""Y"". Not to be used with human clinical trials." +--USCHFL,Unscheduled Flag,Char,Record Qualifier,"Indicates whether the timing of a performed test or observation was unscheduled. If a test or observation was performed based upon a schedule defined in the protocol, this flag should be null. Expected values are ""Y"" or null. Not to be used with human clinical trials. This variable would not be needed when information on planned assessments is provided, such as when the Trial Visits (TV) and Subject Visits (SV) domains are used." +--REPNUM,Repetition Number,Num,Record Qualifier,"The instance number of a test that is repeated within a given timeframe for the same test. The level of granularity can vary (e.g., within a time point or within a visit). For example, multiple measurements of blood pressure or multiple analyses of a sample." diff --git a/data-raw/ig_source/sdtmig_3.2/PP-specification.csv b/data-raw/ig_source/sdtmig_3.2/PP-specification.csv new file mode 100644 index 0000000..b3cbd0d --- /dev/null +++ b/data-raw/ig_source/sdtmig_3.2/PP-specification.csv @@ -0,0 +1,45 @@ +Variable Name,Variable Label,Type,"Controlled Terms, Codelist or Format",Role,CDISC Notes,Core +STUDYID,Study Identifier,Char,,Identifier,Unique identifier for a study.,Req +DOMAIN,Domain Abbreviation,Char,PP,Identifier,Two-character abbreviation for the domain.,Req +USUBJID,Unique Subject Identifier,Char,,Identifier,Unique subject identifier within the submission.,Req +PPSEQ,Sequence Number,Num,,Identifier,"Sequence Number given to ensure uniqueness of subject records within a domain. +May be any valid number.",Req +PPGRPID,Group ID,Char,,Identifier,"Used to tie together a block of related records in a single domain to support +relationships within the domain and between domains.",Perm +PPTESTCD,Parameter Short Name,Char,(PKPARMCD),Topic,"Short name of the pharmacokinetic parameter. It can be used as a column name when converting a dataset from a vertical to a horizontal format. The value in PPTESTCD cannot be longer than 8 characters, nor can it start with a number (e.g., “1TEST”). PPTESTCD cannot contain characters other than letters, numbers, or underscores. Examples: AUCALL, +TMAX, CMAX.",Req +PPTEST,Parameter Name,Char,(PKPARM),"Synonym +Qualifier","Name of the pharmacokinetic parameter. The value in PPTEST cannot be longer +than 40 characters. Examples: AUC All, Time of CMAX, Max Conc.",Req +PPCAT,Parameter Category,Char,*,"Grouping +Qualifier","Used to define a category of related records. For PP, this should be the name of the +analyte in PCTEST whose profile the parameter is associated with.",Exp +PPSCAT,Parameter Subcategory,Char,*,"Grouping +Qualifier","Categorization of the model type used to calculate the PK parameters. Examples +include COMPARTMENTAL, NON-COMPARTMENTAL.",Perm +PPORRES,"Result or Finding in Original +Units",Char,,"Result +Qualifier",Result of the measurement or finding as originally received or collected.,Exp +PPORRESU,Original Units,Char,(PKUNIT),"Variable +Qualifier","Original units in which the data were collected. The unit for PPORRES. Example: +ng/L.",Exp +PPSTRESC,Character Result/Finding in Standard Format,Char,,Result Qualifier,"Contains the result value for all findings, copied or derived from PPORRES in a standard format or standard units. PPSTRESC should store all results or findings in character format; if results are numeric, they should also be stored in numeric format in PPSTRESN.",Exp +PPSTRESN,Numeric Result/Finding in Standard Units,Num,,Result Qualifier,"Used for continuous or numeric results or findings in standard format; copied in numeric format from PPSTRESC. PPSTRESN should store all numeric test results +or findings.",Exp +PPSTRESU,Standard Units,Char,(PKUNIT),"Variable +Qualifier",Standardized unit used for PPSTRESC and PPSTRESN.,Exp +PPSTAT,Completion Status,Char,(ND),"Record +Qualifier","Used to indicate that a parameter was not calculated. Should be null if a result exists +in PPORRES.",Perm +PPREASND,Reason Parameter Not Calculated,Char,,Record Qualifier,"Describes why a parameter was not calculated, such as INSUFFICIENT DATA. Used in conjunction with PPSTAT when value is NOT DONE.",Perm +PPSPEC,Specimen Material Type,Char,(SPECTYPE),Record Qualifier,"Defines the type of specimen used for a measurement. If multiple specimen types are used for a calculation (e.g., serum and urine for renal clearance), then this field should be left +blank. Examples: SERUM, PLASMA, URINE.",Exp +PPDTC,Date/Time of Parameter Calculations,Char,ISO 8601,Timing,Nominal date/time of parameter calculations.,Perm +PPRFTDTC,Date/Time of Reference Point,Char,ISO 8601,Timing,"Date/time of the reference time point from the PC records used to calculate a +parameter record. The values in PPRFTDTC should be the same as that in PCRFTDTC for related records.",Exp +PPSTINT,"Planned Start of Assessment +Interval",Char,ISO 8601,Timing,"The start of a planned evaluation or assessment interval relative to the Time Point +Reference.",Perm +PPENINT,"Planned End of Assessment +Interval",Char,ISO 8601,Timimg,"The end of a planned evaluation or assessment interval relative to the Time Point +Reference.",Perm diff --git a/data-raw/ig_source/sdtmig_3.2/Supplemental_Qualifiers-specification.csv b/data-raw/ig_source/sdtmig_3.2/Supplemental_Qualifiers-specification.csv new file mode 100644 index 0000000..c8149a2 --- /dev/null +++ b/data-raw/ig_source/sdtmig_3.2/Supplemental_Qualifiers-specification.csv @@ -0,0 +1,18 @@ +Variable,Variable Label,Type,"Controlled Terms, Codelist +or Format",CDISC Notes,Core +STUDYID,Study Identifier,Char,,Study Identifier of the Parent record(s).,Req +RDOMAIN,Related Domain Abbreviation,Char,DOMAIN,Two-character abbreviation for the domain of the parent record(s).,Req +USUBJID,"Unique +Subject Identifier",Char,,Unique Subject Identifier of the Parent record(s).,Req +IDVAR,Identifying Variable,Char,*,"Identifying variable in the dataset that identifies the related record(s). Examples: --SEQ, --GRPID.",Exp +IDVARVAL,Identifying Variable Value,Char,,Value of identifying variable of the parent record(s).,Exp +QNAM,Qualifier Variable Name,Char,*,"The short name of the Qualifier variable, which is used as a column name in a domain view with data from the parent domain. The value in QNAM cannot be longer than 8 characters, nor can it start with a number (e.g., “1TEST”). QNAM cannot contain characters other than letters, numbers, or underscores. This will often be the column +name in the sponsor’s operational dataset.",Req +QLABEL,Qualifier Variable Label,Char,,"This is the long name or label associated with QNAM. The value in QLABEL cannot be longer than 40 characters. +This will often be the column label in the sponsor’s original dataset.",Req +QVAL,Data Value,Char,,"Result of, response to, or value associated with QNAM. A +value for this column is required; no records can be in SUPP-- with a null value for QVAL.",Req +QORIG,Origin,Char,,"Since QVAL can represent a mixture of collected (on a CRF), derived, or assigned items, QORIG is used to indicate the origin of this data. Examples include CRF, ASSIGNED, or DERIVED. See Section 4: 4.1.1.8, +Origin Metadata.",Req +QEVAL,Evaluator,Char,*,"Used only for results that are subjective (e.g., assigned by a person or a group). Should be null for records that contain objectively collected or derived data. Some examples include ADJUDICATION COMMITTEE, +STATISTICIAN, DATABASE ADMINISTRATOR, CLINICAL COORDINATOR, etc.",Exp diff --git a/data-raw/raw/adam/ADaM_Terminology_2010-03-05.rds b/data-raw/raw/adam/ADaM_Terminology_2010-03-05.rds index 20cceb7..ef9c148 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2010-03-05.rds and b/data-raw/raw/adam/ADaM_Terminology_2010-03-05.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2010-10-06.rds b/data-raw/raw/adam/ADaM_Terminology_2010-10-06.rds index 9153d50..a097d19 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2010-10-06.rds and b/data-raw/raw/adam/ADaM_Terminology_2010-10-06.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2011-01-07.rds b/data-raw/raw/adam/ADaM_Terminology_2011-01-07.rds index f48e918..0bb7fb3 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2011-01-07.rds and b/data-raw/raw/adam/ADaM_Terminology_2011-01-07.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2011-07-22.rds b/data-raw/raw/adam/ADaM_Terminology_2011-07-22.rds index c518fdb..861627d 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2011-07-22.rds and b/data-raw/raw/adam/ADaM_Terminology_2011-07-22.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2014-09-26.rds b/data-raw/raw/adam/ADaM_Terminology_2014-09-26.rds index 8be5ac5..a5b8dcd 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2014-09-26.rds and b/data-raw/raw/adam/ADaM_Terminology_2014-09-26.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2015-12-18.rds b/data-raw/raw/adam/ADaM_Terminology_2015-12-18.rds index 61835c6..a2bfe0d 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2015-12-18.rds and b/data-raw/raw/adam/ADaM_Terminology_2015-12-18.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2016-03-25.rds b/data-raw/raw/adam/ADaM_Terminology_2016-03-25.rds index 4f2ecd6..e8d71d4 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2016-03-25.rds and b/data-raw/raw/adam/ADaM_Terminology_2016-03-25.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2016-09-30.rds b/data-raw/raw/adam/ADaM_Terminology_2016-09-30.rds index 74cc579..fd49c00 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2016-09-30.rds and b/data-raw/raw/adam/ADaM_Terminology_2016-09-30.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2016-12-16.rds b/data-raw/raw/adam/ADaM_Terminology_2016-12-16.rds index 9eea515..bfcf07f 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2016-12-16.rds and b/data-raw/raw/adam/ADaM_Terminology_2016-12-16.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2017-03-31.rds b/data-raw/raw/adam/ADaM_Terminology_2017-03-31.rds index e10d731..76da130 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2017-03-31.rds and b/data-raw/raw/adam/ADaM_Terminology_2017-03-31.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2017-09-29.rds b/data-raw/raw/adam/ADaM_Terminology_2017-09-29.rds index c51f0c2..95d93bc 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2017-09-29.rds and b/data-raw/raw/adam/ADaM_Terminology_2017-09-29.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2018-12-21.rds b/data-raw/raw/adam/ADaM_Terminology_2018-12-21.rds index f67c1a8..ec6709c 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2018-12-21.rds and b/data-raw/raw/adam/ADaM_Terminology_2018-12-21.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2019-01-07.rds b/data-raw/raw/adam/ADaM_Terminology_2019-01-07.rds index c1e74ea..bee4765 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2019-01-07.rds and b/data-raw/raw/adam/ADaM_Terminology_2019-01-07.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2019-03-29.rds b/data-raw/raw/adam/ADaM_Terminology_2019-03-29.rds index c9ccbfc..6402aca 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2019-03-29.rds and b/data-raw/raw/adam/ADaM_Terminology_2019-03-29.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2019-12-20.rds b/data-raw/raw/adam/ADaM_Terminology_2019-12-20.rds index 0ca8226..e1d57d4 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2019-12-20.rds and b/data-raw/raw/adam/ADaM_Terminology_2019-12-20.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2020-03-27.rds b/data-raw/raw/adam/ADaM_Terminology_2020-03-27.rds index 180a21d..0111693 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2020-03-27.rds and b/data-raw/raw/adam/ADaM_Terminology_2020-03-27.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2020-06-26.rds b/data-raw/raw/adam/ADaM_Terminology_2020-06-26.rds index 9a69e81..43c9ffb 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2020-06-26.rds and b/data-raw/raw/adam/ADaM_Terminology_2020-06-26.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2020-09-25.rds b/data-raw/raw/adam/ADaM_Terminology_2020-09-25.rds index ff1ad90..70047eb 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2020-09-25.rds and b/data-raw/raw/adam/ADaM_Terminology_2020-09-25.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2020-11-06.rds b/data-raw/raw/adam/ADaM_Terminology_2020-11-06.rds index 2b1e4d0..a831746 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2020-11-06.rds and b/data-raw/raw/adam/ADaM_Terminology_2020-11-06.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2021-12-17.rds b/data-raw/raw/adam/ADaM_Terminology_2021-12-17.rds index 30dcb3c..ec2208f 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2021-12-17.rds and b/data-raw/raw/adam/ADaM_Terminology_2021-12-17.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2022-06-24.rds b/data-raw/raw/adam/ADaM_Terminology_2022-06-24.rds index c0aa126..fcca291 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2022-06-24.rds and b/data-raw/raw/adam/ADaM_Terminology_2022-06-24.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2023-03-31.rds b/data-raw/raw/adam/ADaM_Terminology_2023-03-31.rds index 5a283f1..fa79c37 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2023-03-31.rds and b/data-raw/raw/adam/ADaM_Terminology_2023-03-31.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2023-06-30.rds b/data-raw/raw/adam/ADaM_Terminology_2023-06-30.rds index adeb941..4dd229e 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2023-06-30.rds and b/data-raw/raw/adam/ADaM_Terminology_2023-06-30.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2024-03-29.rds b/data-raw/raw/adam/ADaM_Terminology_2024-03-29.rds index 9bc679c..26d6d20 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2024-03-29.rds and b/data-raw/raw/adam/ADaM_Terminology_2024-03-29.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2024-09-27.rds b/data-raw/raw/adam/ADaM_Terminology_2024-09-27.rds index bacedf8..47537ce 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2024-09-27.rds and b/data-raw/raw/adam/ADaM_Terminology_2024-09-27.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2025-03-28.rds b/data-raw/raw/adam/ADaM_Terminology_2025-03-28.rds index 5db78bb..979e878 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2025-03-28.rds and b/data-raw/raw/adam/ADaM_Terminology_2025-03-28.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2025-09-26.rds b/data-raw/raw/adam/ADaM_Terminology_2025-09-26.rds index ddd8ba3..388748e 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2025-09-26.rds and b/data-raw/raw/adam/ADaM_Terminology_2025-09-26.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2026-03-27.rds b/data-raw/raw/adam/ADaM_Terminology_2026-03-27.rds index 71c110d..0e01c37 100644 Binary files a/data-raw/raw/adam/ADaM_Terminology_2026-03-27.rds and b/data-raw/raw/adam/ADaM_Terminology_2026-03-27.rds differ diff --git a/data-raw/raw/adam/ADaM_Terminology_2026-09-25.rds b/data-raw/raw/adam/ADaM_Terminology_2026-09-25.rds new file mode 100644 index 0000000..f6caf6b Binary files /dev/null and b/data-raw/raw/adam/ADaM_Terminology_2026-09-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2007-03-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2007-03-06.rds index 1c803fe..a332434 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2007-03-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2007-03-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2007-04-20.rds b/data-raw/raw/sdtm/SDTM_Terminology_2007-04-20.rds index 273ec37..2dbf1f9 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2007-04-20.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2007-04-20.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2007-04-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2007-04-26.rds index 86028c4..7389b49 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2007-04-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2007-04-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2007-05-31.rds b/data-raw/raw/sdtm/SDTM_Terminology_2007-05-31.rds index 5040811..95783b1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2007-05-31.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2007-05-31.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2007-06-05.rds b/data-raw/raw/sdtm/SDTM_Terminology_2007-06-05.rds index 209b2ec..1473d02 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2007-06-05.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2007-06-05.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-01-15.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-01-15.rds index 61e8f8f..733cc46 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-01-15.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-01-15.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-01-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-01-25.rds index 7874e9f..a328a0e 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-01-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-01-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-08-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-08-26.rds index 3e37461..19f57b5 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-08-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-08-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-22.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-22.rds index 8449c54..1d008a1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-22.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-22.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-24.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-24.rds index 6818c8b..274882a 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-24.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-24.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-30.rds index fdb8ad2..b759b62 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-09-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-09-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-10-09.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-10-09.rds index f4027c8..4d9589d 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-10-09.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-10-09.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2008-10-15.rds b/data-raw/raw/sdtm/SDTM_Terminology_2008-10-15.rds index fc08ddc..ad1338e 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2008-10-15.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2008-10-15.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2009-02-17.rds b/data-raw/raw/sdtm/SDTM_Terminology_2009-02-17.rds index d60046a..89dc611 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2009-02-17.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2009-02-17.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2009-02-18.rds b/data-raw/raw/sdtm/SDTM_Terminology_2009-02-18.rds index 65f81b0..79c67df 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2009-02-18.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2009-02-18.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2009-05-01.rds b/data-raw/raw/sdtm/SDTM_Terminology_2009-05-01.rds index a9a6108..c892e01 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2009-05-01.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2009-05-01.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2009-07-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2009-07-06.rds index 8c0eab0..3fac2a2 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2009-07-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2009-07-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2009-10-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2009-10-06.rds index 8c0211b..4e2c777 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2009-10-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2009-10-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2010-03-05.rds b/data-raw/raw/sdtm/SDTM_Terminology_2010-03-05.rds index 539cb3c..07b30dc 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2010-03-05.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2010-03-05.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2010-04-08.rds b/data-raw/raw/sdtm/SDTM_Terminology_2010-04-08.rds index bcc1c51..9abdf7c 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2010-04-08.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2010-04-08.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2010-07-02.rds b/data-raw/raw/sdtm/SDTM_Terminology_2010-07-02.rds index d787aa4..8a32728 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2010-07-02.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2010-07-02.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2010-10-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2010-10-06.rds index 297db37..ae2788e 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2010-10-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2010-10-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2010-10-22.rds b/data-raw/raw/sdtm/SDTM_Terminology_2010-10-22.rds index 8ee6ab6..f44a6ce 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2010-10-22.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2010-10-22.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2011-01-07.rds b/data-raw/raw/sdtm/SDTM_Terminology_2011-01-07.rds index 85efa4b..168c106 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2011-01-07.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2011-01-07.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2011-04-08.rds b/data-raw/raw/sdtm/SDTM_Terminology_2011-04-08.rds index 957c432..16511e6 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2011-04-08.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2011-04-08.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2011-06-10.rds b/data-raw/raw/sdtm/SDTM_Terminology_2011-06-10.rds index 65cb1b7..bfdfff7 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2011-06-10.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2011-06-10.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2011-07-22.rds b/data-raw/raw/sdtm/SDTM_Terminology_2011-07-22.rds index 4830219..744e228 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2011-07-22.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2011-07-22.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2011-12-09.rds b/data-raw/raw/sdtm/SDTM_Terminology_2011-12-09.rds index 8fd7072..d7982b3 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2011-12-09.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2011-12-09.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2012-03-23.rds b/data-raw/raw/sdtm/SDTM_Terminology_2012-03-23.rds index c575ba9..e1d73de 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2012-03-23.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2012-03-23.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2012-06-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2012-06-29.rds index 9c60c65..bcc4cf9 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2012-06-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2012-06-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2012-08-03.rds b/data-raw/raw/sdtm/SDTM_Terminology_2012-08-03.rds index fc9b543..8864e03 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2012-08-03.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2012-08-03.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2012-12-21.rds b/data-raw/raw/sdtm/SDTM_Terminology_2012-12-21.rds index cb9bb3b..323cffd 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2012-12-21.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2012-12-21.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2013-04-12.rds b/data-raw/raw/sdtm/SDTM_Terminology_2013-04-12.rds index 21c5c2b..b8b9f17 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2013-04-12.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2013-04-12.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2013-06-28.rds b/data-raw/raw/sdtm/SDTM_Terminology_2013-06-28.rds index c8bb019..c787253 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2013-06-28.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2013-06-28.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2013-10-04.rds b/data-raw/raw/sdtm/SDTM_Terminology_2013-10-04.rds index d1845e3..79f523b 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2013-10-04.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2013-10-04.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2013-12-20.rds b/data-raw/raw/sdtm/SDTM_Terminology_2013-12-20.rds index ec5d4d5..7b4e21f 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2013-12-20.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2013-12-20.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2014-03-28.rds b/data-raw/raw/sdtm/SDTM_Terminology_2014-03-28.rds index be691c1..03625a4 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2014-03-28.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2014-03-28.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2014-06-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2014-06-27.rds index 3c9144e..0ed4641 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2014-06-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2014-06-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2014-09-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2014-09-26.rds index f199d17..660bf65 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2014-09-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2014-09-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2014-10-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2014-10-06.rds index 5c67796..4a58c17 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2014-10-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2014-10-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2014-12-19.rds b/data-raw/raw/sdtm/SDTM_Terminology_2014-12-19.rds index b836ed1..89744c1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2014-12-19.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2014-12-19.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2015-03-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2015-03-27.rds index 8a3534b..d105768 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2015-03-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2015-03-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2015-06-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2015-06-26.rds index 0827095..c999605 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2015-06-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2015-06-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2015-09-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2015-09-25.rds index 81e8768..6476c3d 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2015-09-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2015-09-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2015-12-18.rds b/data-raw/raw/sdtm/SDTM_Terminology_2015-12-18.rds index 9cd98cc..45f16ee 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2015-12-18.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2015-12-18.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2016-03-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2016-03-25.rds index d374ad3..f6cdb36 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2016-03-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2016-03-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2016-06-24.rds b/data-raw/raw/sdtm/SDTM_Terminology_2016-06-24.rds index 0eeb358..80d890a 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2016-06-24.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2016-06-24.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2016-09-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2016-09-30.rds index 9de4a98..dc59d31 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2016-09-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2016-09-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2016-12-16.rds b/data-raw/raw/sdtm/SDTM_Terminology_2016-12-16.rds index ba4384b..e7142c7 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2016-12-16.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2016-12-16.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2017-03-31.rds b/data-raw/raw/sdtm/SDTM_Terminology_2017-03-31.rds index edd1b1b..3cfdc03 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2017-03-31.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2017-03-31.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2017-06-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2017-06-30.rds index 5726e1e..d2f62ab 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2017-06-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2017-06-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2017-09-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2017-09-29.rds index 567fa21..dcec6f8 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2017-09-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2017-09-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2017-12-22.rds b/data-raw/raw/sdtm/SDTM_Terminology_2017-12-22.rds index 1b13248..f304245 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2017-12-22.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2017-12-22.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2018-03-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2018-03-30.rds index 13f5d3f..913f9b5 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2018-03-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2018-03-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2018-06-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2018-06-29.rds index f9a6895..347a518 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2018-06-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2018-06-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2018-09-28.rds b/data-raw/raw/sdtm/SDTM_Terminology_2018-09-28.rds index 832bd3d..18e75a4 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2018-09-28.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2018-09-28.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2018-12-21.rds b/data-raw/raw/sdtm/SDTM_Terminology_2018-12-21.rds index b2517a6..5b94cee 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2018-12-21.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2018-12-21.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2019-01-07.rds b/data-raw/raw/sdtm/SDTM_Terminology_2019-01-07.rds index 3061590..96a60c7 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2019-01-07.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2019-01-07.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2019-03-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2019-03-29.rds index 652cb27..fdc40c2 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2019-03-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2019-03-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2019-06-28.rds b/data-raw/raw/sdtm/SDTM_Terminology_2019-06-28.rds index d306633..aee9552 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2019-06-28.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2019-06-28.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2019-09-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2019-09-27.rds index 5acfa3b..efd98ae 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2019-09-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2019-09-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2019-12-20.rds b/data-raw/raw/sdtm/SDTM_Terminology_2019-12-20.rds index 5854691..bf979d4 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2019-12-20.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2019-12-20.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-03-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-03-27.rds index af33d21..3b890b1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-03-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-03-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-05-08.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-05-08.rds index 56d32ab..96ffe57 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-05-08.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-05-08.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-06-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-06-26.rds index 1327cf4..71983de 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-06-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-06-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-09-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-09-25.rds index fbd9f0f..67146ef 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-09-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-09-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-11-06.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-11-06.rds index a6619fd..8e8e3ab 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-11-06.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-11-06.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2020-12-18.rds b/data-raw/raw/sdtm/SDTM_Terminology_2020-12-18.rds index b769474..91cadd6 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2020-12-18.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2020-12-18.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2021-03-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2021-03-26.rds index 7a81bdb..4724a6f 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2021-03-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2021-03-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2021-06-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2021-06-25.rds index e285692..f6ab659 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2021-06-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2021-06-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2021-09-24.rds b/data-raw/raw/sdtm/SDTM_Terminology_2021-09-24.rds index 11f5729..c476670 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2021-09-24.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2021-09-24.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2021-12-17.rds b/data-raw/raw/sdtm/SDTM_Terminology_2021-12-17.rds index 6d5824e..6e343f1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2021-12-17.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2021-12-17.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2022-03-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2022-03-25.rds index f8d70c8..124db28 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2022-03-25.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2022-03-25.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2022-06-24.rds b/data-raw/raw/sdtm/SDTM_Terminology_2022-06-24.rds index 307d208..099b280 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2022-06-24.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2022-06-24.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2022-09-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2022-09-30.rds index 89c6e46..3f2e060 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2022-09-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2022-09-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2022-12-16.rds b/data-raw/raw/sdtm/SDTM_Terminology_2022-12-16.rds index 5760ef0..c9b84b4 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2022-12-16.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2022-12-16.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2023-03-31.rds b/data-raw/raw/sdtm/SDTM_Terminology_2023-03-31.rds index 9b5d0af..a704102 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2023-03-31.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2023-03-31.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2023-06-30.rds b/data-raw/raw/sdtm/SDTM_Terminology_2023-06-30.rds index c9e6231..0d4ee7c 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2023-06-30.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2023-06-30.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2023-09-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2023-09-29.rds index acf5539..5d88004 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2023-09-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2023-09-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2023-12-15.rds b/data-raw/raw/sdtm/SDTM_Terminology_2023-12-15.rds index 5ab1135..8f7f968 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2023-12-15.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2023-12-15.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2024-03-29.rds b/data-raw/raw/sdtm/SDTM_Terminology_2024-03-29.rds index e7dd927..1aa4db1 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2024-03-29.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2024-03-29.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2024-09-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2024-09-27.rds index d13f054..ddb441c 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2024-09-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2024-09-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2025-03-28.rds b/data-raw/raw/sdtm/SDTM_Terminology_2025-03-28.rds index 9aae2a0..3d29603 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2025-03-28.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2025-03-28.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2025-09-26.rds b/data-raw/raw/sdtm/SDTM_Terminology_2025-09-26.rds index 8801457..672c7ef 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2025-09-26.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2025-09-26.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2026-03-27.rds b/data-raw/raw/sdtm/SDTM_Terminology_2026-03-27.rds index ecaa3b5..c6cbb01 100644 Binary files a/data-raw/raw/sdtm/SDTM_Terminology_2026-03-27.rds and b/data-raw/raw/sdtm/SDTM_Terminology_2026-03-27.rds differ diff --git a/data-raw/raw/sdtm/SDTM_Terminology_2026-09-25.rds b/data-raw/raw/sdtm/SDTM_Terminology_2026-09-25.rds new file mode 100644 index 0000000..b2be952 Binary files /dev/null and b/data-raw/raw/sdtm/SDTM_Terminology_2026-09-25.rds differ diff --git a/data-raw/utils_ig.R b/data-raw/utils_ig.R new file mode 100644 index 0000000..50f1c4e --- /dev/null +++ b/data-raw/utils_ig.R @@ -0,0 +1,87 @@ +# Helpers for building versioned SDTM/ADaM implementation-guide (IG) variable +# metadata from the CSV transcriptions under data-raw/ig_source/. +# Sourced by build_ig_sdtm.R and build_ig_adam.R. +# +# Those source CSVs are column-inconsistent in minor ways across files and +# CDISC versions (a stray blank header cell here, "Codelist/ Controlled +# Terms" vs "Codelist / Controlled Terms" there, "Variable" vs +# "Variable Name"), evidently from how each was originally transcribed from +# a CDISC PDF/Word table. read_ig_csv() normalises all of that by matching +# column *names* (not position) against the canonical fields every one of +# these tables can carry, rather than assuming a fixed column order. + +# Read one IG source CSV and return it with canonical column names: +# variable, label, type, core, codelist, role, notes. Any canonical column +# absent from this particular file (e.g. "role" in an ADaM spec) is filled +# with NA. Blank/duplicate header cells (transcription artifacts) are +# dropped before matching. +read_ig_csv <- function(path) { + # These CSVs are transcriptions of CDISC Word/PDF tables and are encoded + # as Windows-1252 (smart quotes, non-breaking spaces), not UTF-8; reading + # as UTF-8 silently mangles those characters into mojibake instead of + # erroring, so the encoding must be stated explicitly. + raw <- utils::read.csv(path, check.names = FALSE, stringsAsFactors = FALSE, + na.strings = "", fileEncoding = "windows-1252") + # Collapse embedded newlines/extra whitespace in header cells so matching + # is robust to how the CSV happened to wrap a multi-word header. + nm <- gsub("\\s+", " ", trimws(names(raw))) + nm[is.na(nm) | !nzchar(nm)] <- NA_character_ + names(raw) <- nm + raw <- raw[, !is.na(names(raw)) & !duplicated(names(raw)), drop = FALSE] + + pick <- function(pattern, exclude = NULL) { + hit <- grepl(pattern, names(raw), ignore.case = TRUE) + if (!is.null(exclude)) hit <- hit & !grepl(exclude, names(raw), ignore.case = TRUE) + if (!any(hit)) return(rep(NA_character_, nrow(raw))) + as.character(raw[[which(hit)[1L]]]) + } + + data.frame( + variable = pick("^Variable( Name)?$", exclude = "Label"), + label = pick("Variable Label"), + type = pick("^Type$"), + core = pick("^Core$"), + codelist = pick("Codelist|Controlled Terms"), + role = pick("^Role$"), + notes = pick("CDISC Notes|^Description$"), + stringsAsFactors = FALSE + ) +} + +# Extract a codelist submission value (e.g. "PKPARMCD") from the free-text +# "Codelist/Controlled Terms" column, e.g. "(PKPARMCD)" -> "PKPARMCD". CDISC +# also uses this column for a non-codelist marker ("*" = extensible list not +# further specified in the IG) or a format note ("ISO 8601"); neither names +# an actual codelist, so both return NA. +parse_codelist_token <- function(x) { + text <- ifelse(is.na(x), "", x) + pos <- regexpr("\\(([A-Za-z0-9_]+)\\)", text) + hit <- pos > 0L + token <- rep(NA_character_, length(x)) + # regmatches(text, pos) returns matches only for the TRUE positions of + # `hit`, in order, so it lines up with token[hit] element-for-element. + matched <- regmatches(text, pos) + token[hit] <- sub("^\\((.*)\\)$", "\\1", matched) + # A handful of IG tables reference a codelist by bare name (no + # parentheses), e.g. SUPP--'s RDOMAIN -> "DOMAIN". + bare_ok <- is.na(token) & grepl("^[A-Z][A-Z0-9_]*$", text) + token[bare_ok] <- text[bare_ok] + token +} + +# Recover a documented maximum character length from CDISC Notes text, e.g. +# "cannot be longer than 8 characters" -> 8L. CDISC implementation guides do +# not publish a Length column at all (length is a sponsor/define.xml +# choice); this recovers the few lengths the IG text states explicitly as a +# hard rule, rather than guessing one for every variable. +parse_documented_length <- function(notes) { + text <- ifelse(is.na(notes), "", notes) + pos <- regexpr("longer than (\\d+) character", text, ignore.case = TRUE) + hit <- pos > 0L + len <- rep(NA_integer_, length(notes)) + # regmatches(text, pos) returns matches only for the TRUE positions of + # `hit`, in order, so it lines up with len[hit] element-for-element. + matched <- regmatches(text, pos) + len[hit] <- suppressWarnings(as.integer(sub("\\D*(\\d+).*", "\\1", matched))) + len +} diff --git a/data-raw/utils_nci.R b/data-raw/utils_nci.R index 8a47b06..8e40326 100644 --- a/data-raw/utils_nci.R +++ b/data-raw/utils_nci.R @@ -20,6 +20,17 @@ raw_ct_path <- function(type, date) { sprintf("%s_Terminology_%s.rds", label, date_str)) } +# Return the local cache path for a release's raw (unparsed) NCI text file. +# Used only transiently during a re-parse (see rebuild_ct.R style scripts); +# ordinary fetches use a tempfile instead (below), since the parsed, +# XZ-compressed RDS cache is ~10x more compact and serves the same +# avoid-re-download purpose for everyday use. A full re-download (as was +# done when the 2012-on codelist_name bug below was fixed) is an acceptable, +# infrequent cost for the rare case of a future parser fix. +raw_ct_text_path <- function(type, date) { + sub("\\.rds$", ".txt", raw_ct_path(type, date)) +} + # Return the parsed CT data frame for a release, using the local RDS cache. # If the RDS does not exist, downloads the NCI text file to a tempfile, # parses it, saves the result as an RDS, and returns the data frame. @@ -66,15 +77,36 @@ parse_nci_ct_txt <- function(local_path, release_date) { "raw_synonyms", "raw_definition", "raw_nci_term" ) - # Identify codelist-level rows (Code == Codelist Code) - is_list_row <- df$raw_code == df$raw_clst_code + # Identify codelist-level (header) rows. Two NCI file conventions are seen + # across vintages: files from ~2012 onward leave "Codelist Code" blank on + # a codelist's own header row (its Code is the codelist's C-code, with + # nothing "above" it to reference); files through ~2011 instead repeat the + # codelist's C-code in both Code and Codelist Code. Testing for either + # covers the whole archive. (A header-row Codelist Code that is blank, not + # self-referential, was previously undetected here, which silently left + # codelist_name NA for every row of every release from 2012 on.) + # A handful of old SDTM archive releases (scattered across 2007-2010, plus + # one in 2017) use further, rarer header-row conventions this cannot + # detect - e.g. the 2008-08-26 file's header rows carry a stray, + # non-blank Codelist Code (so is_list_row is FALSE for them, leaving + # codelist_name NA on their term rows); a few individual lines elsewhere + # are outright malformed at the source (e.g. an embedded newline or a + # missing tab), producing garbage - full sentences, not C-codes - in + # codelist_code. No further rule here recovers those without risking a + # false match on genuine data elsewhere. test-data_integrity.R asserts the + # *current* release is unaffected and bounds the historical total, rather + # than enumerating every affected release precisely. None are PK-related. + is_list_row <- df$raw_clst_code == "" | is.na(df$raw_clst_code) | + df$raw_code == df$raw_clst_code extensible <- rep(NA, nrow(df)) extensible[df$raw_extensible == "Yes"] <- TRUE extensible[df$raw_extensible == "No"] <- FALSE result <- data.frame( - codelist_code = df$raw_clst_code, + # A header row's own Codelist Code field is blank (or self-referential); + # its own C-code is always in Code. + codelist_code = ifelse(is_list_row, df$raw_code, df$raw_clst_code), codelist_name = ifelse(is_list_row, df$raw_submission_value, NA_character_), codelist_label = df$raw_clst_label, extensible = extensible, @@ -115,20 +147,67 @@ fetch_current_release_date <- function(type = c("sdtm", "adam")) { max(dates) } -# List all archived version dates for a CT type by parsing the Apache -# directory listing HTML +# List all archived version dates for a CT type. +# +# NCI's EVS FTP site was rebuilt as a JavaScript single-page app at some +# point in 2024-2025; the Archive/ directory URL now serves that app's +# empty HTML shell (the actual listing is fetched client-side), so scraping +# it for file names - the previous approach here - silently finds nothing. +# This instead calls the JSON API the app itself uses +# (GET /ftp1/folder?folder=, an S3 ListObjectsV2-shaped response) and +# reads file names from its `Contents[].Key` field. +# +# That response is capped at 1000 keys per call; a `NextContinuationToken` +# is present when there are more, but no continuation-token/token/next query +# parameter this was tried against changes the response, and the live site's +# own app never requests a second page either - so pagination is not +# available at all through this endpoint, not just unimplemented here. This +# still finds every release date needed in practice: S3 keys sort +# lexicographically, ASCII digits sort before letters, and plain dated +# release files ("SDTM Terminology 2024-09-27.txt") are therefore returned +# as a contiguous, complete block ahead of every other file that shares the +# "SDTM/ADaM Terminology" prefix (e.g. "... Terminology Changes ..."), +# which is what exhausts the 1000-key cap first. Confirmed empirically for +# both types as of 2026-09: IsTruncated is TRUE for SDTM (many more +# "Changes"/CDASH files follow) and FALSE for ADaM, and either way every +# dated release file already present is captured. If SDTM/ADaM's own dated +# files ever alone exceed 1000, or a filename sorting ahead of them is +# introduced, this would silently miss the oldest dates - `message()` below +# surfaces IsTruncated so that becoming a real risk is at least visible. list_archive_dates <- function(type = c("sdtm", "adam")) { type <- match.arg(type) - archive_url <- switch(type, sdtm = SDTM_ARCHIVE, adam = ADAM_ARCHIVE) - html <- tryCatch( - readLines(archive_url, warn = FALSE), - error = function(e) character(0) - ) - dates <- regmatches(html, gregexpr("\\d{4}-\\d{2}-\\d{2}", html)) - dates <- unique(unlist(dates)) + folder <- switch(type, sdtm = "CDISC/SDTM/Archive/", adam = "CDISC/ADaM/Archive/") + label <- switch(type, sdtm = "SDTM", adam = "ADaM") + + listing <- tryCatch(fetch_folder_listing(folder), error = function(e) NULL) + if (is.null(listing)) return(as.Date(character(0L))) + if (isTRUE(listing$IsTruncated)) { + message(sprintf( + "list_archive_dates(\"%s\"): folder listing is truncated at %d entries; ", + type, length(listing$Contents) + ), "see the comment above this function if dates now look incomplete.") + } + + keys <- vapply(listing$Contents, function(x) x$Key, character(1L)) + pattern <- sprintf("%s Terminology ([0-9]{4}-[0-9]{2}-[0-9]{2})\\.txt$", label) + hits <- regmatches(keys, regexpr(pattern, keys)) + dates <- sub(pattern, "\\1", hits) sort(as.Date(dates)) } +# Fetch one page (up to 1000 entries) of the JSON folder-listing API behind +# NCI's EVS FTP file browser (see list_archive_dates() for the API and its +# no-further-pagination limitation). +fetch_folder_listing <- function(folder) { + url <- paste0("https://evs.nci.nih.gov/ftp1/folder?folder=", + utils::URLencode(folder, reserved = TRUE)) + tmp <- tempfile(fileext = ".json") + on.exit(unlink(tmp)) + download.file(url, tmp, quiet = TRUE, mode = "wb") + jsonlite::fromJSON(paste(readLines(tmp, warn = FALSE), collapse = "\n"), + simplifyVector = FALSE) +} + # Build URL for an archived CT file archive_url <- function(type, date) { date_str <- format(as.Date(date), "%Y-%m-%d") diff --git a/data/ct_adam.rda b/data/ct_adam.rda index 358611a..58f1697 100644 Binary files a/data/ct_adam.rda and b/data/ct_adam.rda differ diff --git a/data/ct_sdtm.rda b/data/ct_sdtm.rda index cd432c0..a7b0579 100644 Binary files a/data/ct_sdtm.rda and b/data/ct_sdtm.rda differ diff --git a/data/datasets_catalogue.rda b/data/datasets_catalogue.rda index 7a1c744..d7bf28c 100644 Binary files a/data/datasets_catalogue.rda and b/data/datasets_catalogue.rda differ diff --git a/data/ig_adam.rda b/data/ig_adam.rda new file mode 100644 index 0000000..ac49d45 Binary files /dev/null and b/data/ig_adam.rda differ diff --git a/data/ig_sdtm.rda b/data/ig_sdtm.rda new file mode 100644 index 0000000..60686c6 Binary files /dev/null and b/data/ig_sdtm.rda differ diff --git a/man/build_domain_spec.Rd b/man/build_domain_spec.Rd new file mode 100644 index 0000000..0dcc8ee --- /dev/null +++ b/man/build_domain_spec.Rd @@ -0,0 +1,67 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/build_domain_spec.R +\name{build_domain_spec} +\alias{build_domain_spec} +\title{Build a variable specification for PP, SUPPPP, or ADPP} +\usage{ +build_domain_spec( + domain = c("PP", "SUPPPP", "ADPP"), + ig_version = NULL, + ct_version = NULL, + adsl = TRUE +) +} +\arguments{ +\item{domain}{One of \code{"PP"}, \code{"SUPPPP"}, or \code{"ADPP"}.} + +\item{ig_version}{IG version to use: an SDTMIG version (for \code{PP}/ +\code{SUPPPP}) or an ADaMIG version (for \code{ADPP}). +\code{NULL} uses the newest available for that IG.} + +\item{ct_version}{CT version to resolve codelist ids against; passed to +\code{\link{get_ct}}. \code{NULL} uses the newest available.} + +\item{adsl}{For \code{domain = "ADPP"} only: whether to union in the +ADaMIG ADSL variables (default \code{TRUE}), since a real ADPP dataset +carries ADSL's subject-level variables (treatment, demographics, ...) +alongside its own BDS variables. \code{FALSE} returns the BDS variables +alone. Ignored (with a warning) for \code{domain != "ADPP"}.} +} +\value{ +A data frame with columns \code{variable}, \code{label}, + \code{type}, \code{length}, \code{core}, \code{order}, \code{source} + (\code{"SDTMIG"} for \code{PP}/\code{SUPPPP}; \code{"BDS"} or + \code{"ADSL"} for \code{ADPP}), and \code{codelist_id} (the codelist's + CT C-code, e.g. \code{"C85839"} for PPTESTCD's PKPARMCD codelist; + \code{NA} when the variable has no codelist or the referenced codelist + name is not found in the CT version used). ADSL-sourced \code{ADPP} rows + have \code{core} forced to \code{"Perm"} regardless of their Core + designation in ADSL itself: from ADPP's perspective, merging in an + ADSL variable is a common but optional choice, not a requirement ADSL's + own Core reflects. +} +\description{ +Combines \code{\link{get_ig}} (variable name, label, type, core, order) +with \code{\link{get_ct}} (codelist id lookup) into a single, ready-to-use +variable specification for one of the three PK datasets. \code{PP} and +\code{SUPPPP} draw on the SDTMIG (\code{SUPPPP} from the generic SUPP-- +structure, since CDISC has no domain-specific SUPPPP table); \code{ADPP} +draws on the ADaMIG BDS (Basic Data Structure) table, since ADPP is a BDS +dataset and CDISC has no ADPP-specific table either, optionally unioned +with the ADaMIG ADSL table (see \code{adsl} below), since a real ADPP +also carries ADSL's subject-level variables. +} +\details{ +This does not add PP-inherited traceability variables (\code{PPTESTCD}, +\code{PPTEST}, and the rest of PP's variables that a BDS dataset built +from PP typically carries forward). Neither the ADaMIG BDS nor ADSL +tables define those; which of PP's variables to carry into ADPP, and +under what names, is a downstream derivation choice (e.g. admiral's own +conventions), not IG metadata this function can source. +} +\examples{ +build_domain_spec("PP") +build_domain_spec("SUPPPP") +build_domain_spec("ADPP") # BDS + ADSL (default) +build_domain_spec("ADPP", adsl = FALSE) # BDS only +} diff --git a/man/get_ig.Rd b/man/get_ig.Rd new file mode 100644 index 0000000..22da92b --- /dev/null +++ b/man/get_ig.Rd @@ -0,0 +1,49 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/get_ig.R +\name{get_ig} +\alias{get_ig} +\title{Retrieve CDISC implementation-guide variable metadata} +\usage{ +get_ig(standard = c("sdtm", "adam"), version = NULL) +} +\arguments{ +\item{standard}{One of \code{"sdtm"} or \code{"adam"}.} + +\item{version}{A version string present in the \code{version} column +(e.g. \code{"3.2"} for SDTMIG, \code{"1.7"} for the SDTM Model, +\code{"1.2"} for ADaMIG). \code{NULL} (the default) returns all +versions.} +} +\value{ +A data frame: \code{\link{ig_sdtm}} or \code{\link{ig_adam}}, + optionally filtered to one version. +} +\description{ +Mirrors \code{\link{get_ct}}, but for implementation-guide (IG) variable +metadata rather than controlled terminology. Unlike CT, which uses a +single validity-date timeline per standard, \code{ig_sdtm} bundles two +independently-versioned sources (the SDTM Model and the SDTMIG; see +\code{\link{ig_sdtm}}), so there is no single "latest" snapshot to default +to: \code{version = NULL} returns every source and version, for the +caller to filter further (by \code{source}/\code{domain}/\code{class} for +\code{ig_sdtm}, or \code{dataset}/\code{category} for \code{ig_adam}). +\code{\link{build_domain_spec}} does this filtering for the PP, SUPPPP, +and ADPP datasets specifically. +} +\details{ +\strong{SDTMIG coverage.} The SDTMIG PP domain and the generic SUPP-- +structure are only available at version 3.2, because that is as far as +the Rsdtm source this package copies from goes (see +\code{data-raw/ig_source/README.md}); no newer SDTMIG's PP/SUPP-- tables +were available to source. As a result, PP variables CDISC added or +renamed after SDTMIG 3.2 are absent from \code{ig_sdtm} - notably +\code{PPANMETH}, \code{EPOCH}, and \code{PTAETORD} (added later), and the +\code{PPDTC} to \code{PPPDTC} rename (SDTMIG 3.2 still has \code{PPDTC}). +Sourcing a newer SDTMIG - via a CDISC Library API key or a newer public +transcription - would close this gap. +} +\examples{ +get_ig("sdtm") +get_ig("sdtm", version = "3.2") +get_ig("adam", version = "1.2") +} diff --git a/man/ig_adam.Rd b/man/ig_adam.Rd new file mode 100644 index 0000000..6282737 --- /dev/null +++ b/man/ig_adam.Rd @@ -0,0 +1,45 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/data.R +\docType{data} +\name{ig_adam} +\alias{ig_adam} +\title{ADaM implementation-guide variable metadata} +\format{ +A data frame with columns: +\describe{ + \item{dataset}{\code{"ADSL"} or \code{"BDS"}.} + \item{version}{ADaMIG version, e.g. \code{"1.2"}.} + \item{category}{The Rsdtm source file's variable-category name (e.g. + \code{"ADSL_Treatment_Variables"}, \code{"Timing_Variables_BDS_Datasets"}), + kept for provenance; ADaMIG itself does not group these tables this + way.} + \item{order}{Row order within its category file, as published.} + \item{variable}{Variable name, e.g. \code{"AVAL"}.} + \item{label}{Variable label.} + \item{type}{\code{"Char"} or \code{"Num"}.} + \item{core}{ADaMIG Core designation (\code{"Req"}/\code{"Exp"}/ + \code{"Perm"}/\code{"Cond"}).} + \item{codelist}{Codelist submission value referenced by this variable, + parsed the same way as \code{\link{ig_sdtm}}'s \code{codelist} + column; see there for details and caveats.} + \item{length}{Maximum character length when the IG text states one + explicitly; \code{NA} otherwise. See \code{\link{ig_sdtm}}.} + \item{notes}{CDISC Notes text for the variable.} +} +} +\source{ +\url{https://github.com/humanpred/Rsdtm}; see + \code{data-raw/ig_source/README.md} for full attribution. +} +\usage{ +ig_adam +} +\description{ +Versioned ADaMIG variable metadata: the ADSL (subject-level) variable +table and the generic BDS (Basic Data Structure) variable table (used for +ADPP, a BDS-structured dataset), for ADaMIG versions 1.0, 1.1, and 1.2. +Use \code{\link{get_ig}} to retrieve it, and +\code{\link{build_domain_spec}} to build a ready-to-use ADPP variable +spec from it (joined to CT for codelist ids). +} +\keyword{datasets} diff --git a/man/ig_sdtm.Rd b/man/ig_sdtm.Rd new file mode 100644 index 0000000..6505c98 --- /dev/null +++ b/man/ig_sdtm.Rd @@ -0,0 +1,59 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/data.R +\docType{data} +\name{ig_sdtm} +\alias{ig_sdtm} +\title{SDTM implementation-guide variable metadata} +\format{ +A data frame with columns: +\describe{ + \item{source}{\code{"SDTM_MODEL"} or \code{"SDTMIG"}.} + \item{version}{SDTM Model version (\code{"1.4"}-\code{"1.7"}) for + \code{source == "SDTM_MODEL"} rows; SDTMIG version (\code{"3.2"}) for + \code{source == "SDTMIG"} rows. The two are independent numbering + systems; see \code{\link{get_ig}}.} + \item{class}{General observation class, e.g. \code{"Findings"}. + \code{NA} for \code{SDTMIG} rows.} + \item{domain}{\code{"PP"} or \code{"SUPPQUAL"} for \code{SDTMIG} rows. + \code{NA} for \code{SDTM_MODEL} rows.} + \item{order}{Row order within its source table, as published.} + \item{variable}{Variable name, e.g. \code{"PPTESTCD"}.} + \item{label}{Variable label.} + \item{type}{\code{"Char"} or \code{"Num"}.} + \item{role}{CDISC variable role, e.g. \code{"Topic"}. \code{NA} for + ADaM rows (not applicable, and not present in \code{ig_adam}).} + \item{core}{SDTMIG Core designation (\code{"Req"}/\code{"Exp"}/ + \code{"Perm"}). \code{NA} for \code{SDTM_MODEL} rows (the model does + not designate Core; that is an IG-level concept).} + \item{codelist}{Codelist submission value referenced by this variable + (e.g. \code{"PKPARMCD"}), parsed from the IG's free-text + "Controlled Terms" column. Look up its codelist C-code via + \code{\link{get_ct}}'s \code{codelist_name}/\code{codelist_code} + columns, as \code{\link{build_domain_spec}} does. \code{NA} when the + variable has no codelist, or the column instead names a format + (e.g. "ISO 8601") or an unspecified extensible list ("*").} + \item{length}{Maximum character length, when the IG text states one + explicitly (e.g. PPTESTCD's 8-character limit); \code{NA} otherwise, + since CDISC implementation guides do not otherwise publish a Length + column (length is a sponsor/define.xml choice).} + \item{notes}{CDISC Notes / Description text for the variable.} +} +} +\source{ +\url{https://github.com/humanpred/Rsdtm}; see + \code{data-raw/ig_source/README.md} for full attribution. +} +\usage{ +ig_sdtm +} +\description{ +Versioned SDTM Model and SDTMIG variable metadata: the Model's Findings +general-observation-class variables (versions 1.4-1.7), the SDTMIG PP +domain, and the SDTMIG generic SUPP-- qualifier structure (used for +SUPPPP; version 3.2 only - see \code{data-raw/ig_source/README.md} for +why no newer SDTMIG version's PP/SUPP-- tables were available to source). +Use \code{\link{get_ig}} to retrieve it, and +\code{\link{build_domain_spec}} to build a ready-to-use PP/SUPPPP/ADPP +variable spec from it (joined to CT for codelist ids). +} +\keyword{datasets} diff --git a/tests/testthat/test-attach.R b/tests/testthat/test-attach.R new file mode 100644 index 0000000..d4fa7a3 --- /dev/null +++ b/tests/testthat/test-attach.R @@ -0,0 +1,84 @@ +# Regression tests for the "works only after library()" bug: lazy-loaded +# package data (ct_sdtm, ct_adam, datasets_catalogue) is wired into the +# search path only when a package is *attached*. Loading just the namespace +# (as `::` does) does not make an unqualified reference to that data resolve, +# even from inside the package's own functions. See R/utils.R's .pkg_data() +# for the fix and rationale. + +# Locate a genuine, buildable package source tree, if one is available in +# this test run. devtools::test()/pkgload::load_all() set the working +# directory to the package root; R CMD check instead runs tests against an +# already-installed copy with no source tree alongside it, in which case the +# ambient installation (found via .libPaths()) already *is* the build under +# test, and there is nothing to rebuild. +locate_pkg_source_root <- function() { + candidates <- unique(c( + getwd(), + tryCatch( + normalizePath(file.path(testthat::test_path(), "..", ".."), mustWork = FALSE), + error = function(e) character(0L) + ) + )) + for (root in candidates) { + has_desc <- file.exists(file.path(root, "DESCRIPTION")) + r_files <- if (dir.exists(file.path(root, "R"))) { + list.files(file.path(root, "R"), pattern = "[.]R$") + } else { + character(0L) + } + if (has_desc && length(r_files) > 0L) return(root) + } + NULL +} + +test_that("get_ct works via cdiscdata:: alone, no library(), in a fresh subprocess", { + skip_on_cran() + skip_if_not_installed("callr") + + root <- locate_pkg_source_root() + if (is.null(root)) { + # No source tree alongside the tests (e.g. R CMD check): the ambient + # installation under .libPaths() is the build under test. + lib <- .libPaths() + } else { + skip_if_not_installed("pkgbuild") + build_dir <- withr::local_tempdir() + lib <- withr::local_tempdir() + tarball <- pkgbuild::build( + root, dest_path = build_dir, quiet = TRUE, vignettes = FALSE + ) + # Installed in a separate subprocess, not in this session: when running + # under devtools::test(), cdiscdata is already loaded here via pkgload, + # and install.packages() refuses to (re)install a package that is + # currently in use in the calling session, even into an unrelated + # library path. + callr::r( + function(tarball, lib) { + utils::install.packages(tarball, repos = NULL, type = "source", + lib = lib, quiet = TRUE) + }, + args = list(tarball = tarball, lib = lib) + ) + lib <- c(lib, .libPaths()) + } + + sdtm <- callr::r(function() cdiscdata::get_ct("sdtm"), libpath = lib) + expect_s3_class(sdtm, "data.frame") + expect_gt(nrow(sdtm), 0L) + expect_true("C66731" %in% sdtm$codelist_code) + + adam <- callr::r(function() cdiscdata::get_ct("adam"), libpath = lib) + expect_s3_class(adam, "data.frame") + expect_gt(nrow(adam), 0L) + + datasets <- callr::r(function() cdiscdata::list_datasets(), libpath = lib) + expect_s3_class(datasets, "data.frame") + expect_gt(nrow(datasets), 0L) + + versions <- callr::r(function() cdiscdata::cdiscdata_versions(), libpath = lib) + expect_s3_class(versions, "data.frame") + + avail <- callr::r(function() cdiscdata::available_ct_versions("sdtm"), libpath = lib) + expect_type(avail, "character") + expect_gt(length(avail), 0L) +}) diff --git a/tests/testthat/test-build_domain_spec.R b/tests/testthat/test-build_domain_spec.R new file mode 100644 index 0000000..1785704 --- /dev/null +++ b/tests/testthat/test-build_domain_spec.R @@ -0,0 +1,138 @@ +test_that("build_domain_spec rejects invalid domain", { + expect_error(build_domain_spec("XX")) +}) + +test_that("build_domain_spec returns expected columns for PP", { + pp <- build_domain_spec("PP") + expect_s3_class(pp, "data.frame") + expect_equal(names(pp), + c("variable", "label", "type", "length", "core", "order", + "source", "codelist_id")) + expect_gt(nrow(pp), 0L) + expect_true(all(pp$source == "SDTMIG")) +}) + +test_that("build_domain_spec resolves PPTESTCD/PPTEST/PPSTAT codelist ids against CT", { + pp <- build_domain_spec("PP") + expect_equal(pp$codelist_id[pp$variable == "PPTESTCD"], "C85839") + expect_equal(pp$codelist_id[pp$variable == "PPTEST"], "C85493") + expect_equal(pp$codelist_id[pp$variable == "PPSTAT"], "C66789") + expect_equal(pp$length[pp$variable == "PPTESTCD"], 8L) +}) + +test_that("build_domain_spec SUPPPP returns the 10 standard SUPP-- variables", { + supp <- build_domain_spec("SUPPPP") + expect_setequal( + supp$variable, + c("STUDYID", "RDOMAIN", "USUBJID", "IDVAR", "IDVARVAL", "QNAM", + "QLABEL", "QVAL", "QORIG", "QEVAL") + ) +}) + +test_that("build_domain_spec ADPP defaults to exactly one (the newest) ADaMIG version", { + adpp <- build_domain_spec("ADPP") + expect_gt(nrow(adpp), 0L) + expect_equal(sum(duplicated(adpp$variable)), 0L) +}) + +test_that("build_domain_spec ADPP with an explicit older version differs from the default", { + adpp_latest <- build_domain_spec("ADPP", ig_version = "1.0") + adpp_default <- build_domain_spec("ADPP") + expect_false(identical(sort(adpp_latest$variable), sort(adpp_default$variable))) +}) + +test_that("build_domain_spec ADPP defaults to adsl = TRUE and unions ADSL variables", { + adpp <- build_domain_spec("ADPP") + expect_true(all(c("BDS", "ADSL") %in% adpp$source)) + # ADSL-only variables (not also defined by BDS) are present... + expect_true("ARM" %in% adpp$variable[adpp$source == "ADSL"]) + # ...marked Perm regardless of their Core designation in ADSL itself + # (ARM is "Req" in ADSL_Treatment_Variables.csv) + expect_equal(adpp$core[adpp$variable == "ARM"], "Perm") + # no duplicates even though BDS and ADSL share base identifier variables + expect_equal(sum(duplicated(adpp$variable)), 0L) +}) + +test_that("build_domain_spec ADPP with adsl = FALSE returns BDS variables only", { + adpp <- build_domain_spec("ADPP", adsl = FALSE) + expect_true(all(adpp$source == "BDS")) + expect_false("ARM" %in% adpp$variable) +}) + +test_that("shared BDS/ADSL variables keep the BDS version, not duplicated", { + adpp <- build_domain_spec("ADPP") + expect_equal(adpp$source[adpp$variable == "STUDYID"], "BDS") + expect_equal(sum(adpp$variable == "STUDYID"), 1L) +}) + +test_that("build_domain_spec warns (classed) when adsl is passed for a non-ADPP domain", { + w <- expect_warning( + build_domain_spec("PP", adsl = FALSE), + class = "cdiscdata_warning_adsl_ignored" + ) + expect_match(conditionMessage(w), "ignored", fixed = TRUE) +}) + +test_that("build_domain_spec aborts (classed) on unknown ig_version", { + e_pp <- expect_error( + build_domain_spec("PP", ig_version = "9.9"), + class = "cdiscdata_error_ig_version_unavailable" + ) + expect_match(conditionMessage(e_pp), "not available", fixed = TRUE) + + e_adpp <- expect_error( + build_domain_spec("ADPP", ig_version = "9.9"), + class = "cdiscdata_error_ig_version_unavailable" + ) + expect_match(conditionMessage(e_adpp), "not available", fixed = TRUE) +}) + +test_that("build_domain_spec aborts informatively on unknown ct_version", { + expect_error(build_domain_spec("PP", ct_version = "1900-01-01"), regexp = "not available") +}) + +test_that("build_domain_spec aborts (classed) when an SDTMIG version has no PP/SUPPQUAL rows", { + # Not reachable via the public API with the currently bundled ig_sdtm + # (SDTMIG's one version, 3.2, always has both PP and SUPPQUAL rows); this + # exercises the defensive check directly by mocking get_ig() to return a + # version that validates but has no rows for either domain. + fake_sdtm <- data.frame( + source = "SDTMIG", version = "9.9", class = NA_character_, + domain = "OTHER", order = 1L, variable = "X", label = "X", type = "Char", + role = NA_character_, core = "Req", codelist = NA_character_, + length = NA_integer_, notes = NA_character_, stringsAsFactors = FALSE + ) + testthat::local_mocked_bindings( + get_ig = function(standard, version = NULL) { + if (standard == "sdtm") fake_sdtm else get_ig(standard, version) + }, + .package = "cdiscdata" + ) + e <- expect_error( + build_domain_spec("PP"), + class = "cdiscdata_error_no_ig_variables" + ) + expect_match(conditionMessage(e), "No SDTMIG 'PP' variables found", fixed = TRUE) +}) + +test_that("build_domain_spec aborts (classed) when an ADaMIG version has no BDS rows", { + # Same rationale as the SDTMIG test above: not reachable with the + # currently bundled ig_adam (every version has BDS rows), so mocked. + fake_adam <- data.frame( + dataset = "OTHER", version = "9.9", category = "X", order = 1L, + variable = "X", label = "X", type = "Char", core = "Req", + codelist = NA_character_, length = NA_integer_, notes = NA_character_, + stringsAsFactors = FALSE + ) + testthat::local_mocked_bindings( + get_ig = function(standard, version = NULL) { + if (standard == "adam") fake_adam else get_ig(standard, version) + }, + .package = "cdiscdata" + ) + e <- expect_error( + build_domain_spec("ADPP"), + class = "cdiscdata_error_no_ig_variables" + ) + expect_match(conditionMessage(e), "No ADaMIG BDS variables found", fixed = TRUE) +}) diff --git a/tests/testthat/test-data_integrity.R b/tests/testthat/test-data_integrity.R index 127dc2c..27812bd 100644 --- a/tests/testthat/test-data_integrity.R +++ b/tests/testthat/test-data_integrity.R @@ -54,3 +54,86 @@ test_that("ct_sdtm has expected columns", { "synonyms", "definition", "valid_from", "valid_to") %in% names(ct_sdtm))) }) + +test_that("PK parameter and PK unit codelists are present in the latest SDTM CT", { + ct <- get_ct("sdtm") + headers <- ct[is.na(ct$term_code), ] + pk <- headers[headers$codelist_name %in% c("PKPARMCD", "PKPARM", "PKUNIT"), ] + expect_equal(nrow(pk), 3L) + expect_equal(pk$codelist_code[pk$codelist_name == "PKPARMCD"], "C85839") + expect_equal(pk$codelist_code[pk$codelist_name == "PKPARM"], "C85493") + expect_equal(pk$codelist_code[pk$codelist_name == "PKUNIT"], "C85494") +}) + +test_that("the current (latest) SDTM and ADaM CT release has no codelist_name/codelist_code gaps", { + # The NCI SDTM archive has several old (2007-2010, plus one 2017) releases + # with source-data-level header-row quirks this parser cannot always + # recover from (see data-raw/utils_nci.R): an unrecognised third + # header-row convention, and a handful of genuinely malformed lines. Every + # instance found so far is confined to those archival releases (pinned by + # the loose historical bound below); what actually matters for any real + # use of this package - the current release - is asserted strictly here. + current_sdtm <- get_ct("sdtm") + expect_false(anyNA(current_sdtm$codelist_name)) + expect_false(anyNA(current_sdtm$codelist_code)) + expect_true(all(nzchar(current_sdtm$codelist_code))) + + current_adam <- get_ct("adam") + expect_false(anyNA(current_adam$codelist_name)) + expect_false(anyNA(current_adam$codelist_code)) +}) + +test_that("historical codelist_name/codelist_code gaps stay within a known bound", { + # Loose regression guard (not a precise historical audit - see the + # previous test) against a future parser change silently reintroducing + # the 2012-on regression this fix addressed, which affected 100% of rows. + expect_lt(sum(is.na(ct_sdtm$codelist_name)), 3000L) + expect_lt(sum(is.na(ct_sdtm$term_code) & is.na(ct_sdtm$codelist_code)), 200L) +}) + +# Gap-detection thresholds below are calibrated against verified NCI +# publishing history (checked directly against NCI's own file listing API; +# see data-raw/utils_nci.R's list_archive_dates()), not against an assumed +# fixed cadence, because that assumption does not hold: +# +# - SDTM CT was reliably quarterly (~90-day gaps) from 2015 through +# 2024-03-29, then NCI cleanly shifted to semi-annual releases +# (March/September, ~182-day gaps) from 2024-09-27 on. No release between +# 2024-03-29 and today is missing - confirmed by directly querying NCI's +# file-listing API for every "SDTM Terminology .txt" key in the +# archive - so a bound has to clear the real 182-day gap, not flag it. +# - ADaM CT has never been reliably quarterly even historically: gaps of +# 266-448 days appear repeatedly from 2017 to 2023, well before the 2024 +# SDTM cadence change, because NCI does not publish an ADaM CT release +# every time it publishes an SDTM one. +# +# A single ~120-day bound (the originally proposed threshold) would treat +# essentially every 2024-on SDTM gap, and most ADaM gaps in any era, as a +# skipped release; each type's threshold instead clears its own real +# maximum observed gap by a comfortable margin while still catching a +# release skipped outright (e.g. a full year with no new SDTM release, or +# no ADaM release for well over its historical worst case). +test_that("no gap between consecutive SDTM CT release dates exceeds 200 days since 2015", { + dates <- sort(unique(ct_sdtm$valid_from[ct_sdtm$valid_from >= as.Date("2015-01-01")])) + gaps <- as.numeric(diff(dates)) + worst <- which.max(gaps) + expect_lt(gaps[worst], 200, + label = sprintf("gap from %s to %s", dates[worst], dates[worst + 1L])) +}) + +test_that("no gap between consecutive ADaM CT release dates exceeds 500 days since 2015", { + dates <- sort(unique(ct_adam$valid_from[ct_adam$valid_from >= as.Date("2015-01-01")])) + gaps <- as.numeric(diff(dates)) + worst <- which.max(gaps) + expect_lt(gaps[worst], 500, + label = sprintf("gap from %s to %s", dates[worst], dates[worst + 1L])) +}) + +test_that("the latest available SDTM and ADaM CT release is not implausibly stale", { + # A freshness check independent of the gap tests above: whichever release + # is newest should be recent (allowing generously for this package's own + # refresh cadence, not NCI's), so a long-broken fetch workflow is still + # caught even if every individual historical gap happens to look fine. + expect_lt(as.numeric(Sys.Date() - max(ct_sdtm$valid_from)), 365) + expect_lt(as.numeric(Sys.Date() - max(ct_adam$valid_from)), 365) +}) diff --git a/tests/testthat/test-get_ig.R b/tests/testthat/test-get_ig.R new file mode 100644 index 0000000..0f0b67b --- /dev/null +++ b/tests/testthat/test-get_ig.R @@ -0,0 +1,78 @@ +test_that("get_ig returns a data frame for sdtm and adam", { + expect_s3_class(get_ig("sdtm"), "data.frame") + expect_s3_class(get_ig("adam"), "data.frame") +}) + +test_that("get_ig rejects invalid standard", { + expect_error(get_ig("other")) +}) + +test_that("get_ig(version = NULL) returns every source/version", { + sdtm <- get_ig("sdtm") + expect_setequal(unique(sdtm$source), c("SDTM_MODEL", "SDTMIG")) + expect_setequal(sdtm$version[sdtm$source == "SDTM_MODEL"], c("1.4", "1.5", "1.6", "1.7")) + expect_setequal(sdtm$version[sdtm$source == "SDTMIG"], "3.2") + + adam <- get_ig("adam") + expect_setequal(unique(adam$version), c("1.0", "1.1", "1.2")) + expect_setequal(unique(adam$dataset), c("ADSL", "BDS")) +}) + +test_that("get_ig filters to one version when given", { + sdtm_32 <- get_ig("sdtm", version = "3.2") + expect_true(all(sdtm_32$version == "3.2")) + expect_true(all(sdtm_32$source == "SDTMIG")) + + adam_10 <- get_ig("adam", version = "1.0") + expect_true(all(adam_10$version == "1.0")) +}) + +test_that("get_ig aborts (classed) on unknown version", { + e_sdtm <- expect_error( + get_ig("sdtm", version = "9.9"), + class = "cdiscdata_error_ig_version_unavailable" + ) + expect_match(conditionMessage(e_sdtm), "not available", fixed = TRUE) + + e_adam <- expect_error( + get_ig("adam", version = "9.9"), + class = "cdiscdata_error_ig_version_unavailable" + ) + expect_match(conditionMessage(e_adam), "not available", fixed = TRUE) +}) + +test_that("ig_sdtm has expected columns and no NA variable/version", { + ig <- get_ig("sdtm") + expect_true(all(c("source", "version", "class", "domain", "order", + "variable", "label", "type", "role", "core", "codelist", + "length", "notes") %in% names(ig))) + expect_false(anyNA(ig$variable)) + expect_false(anyNA(ig$version)) +}) + +test_that("ig_adam has expected columns and no NA variable/version", { + ig <- get_ig("adam") + expect_true(all(c("dataset", "version", "category", "order", "variable", + "label", "type", "core", "codelist", "length", "notes") %in% + names(ig))) + expect_false(anyNA(ig$variable)) + expect_false(anyNA(ig$version)) +}) + +test_that("SDTMIG PP domain contains PPTESTCD with the PKPARMCD codelist token", { + pp <- get_ig("sdtm", version = "3.2") + pp <- pp[pp$domain == "PP", ] + expect_true("PPTESTCD" %in% pp$variable) + expect_equal(pp$codelist[pp$variable == "PPTESTCD"], "PKPARMCD") + expect_equal(pp$length[pp$variable == "PPTESTCD"], 8L) +}) + +test_that("SUPPQUAL structure has the 10 standard SUPP-- variables", { + supp <- get_ig("sdtm", version = "3.2") + supp <- supp[supp$domain == "SUPPQUAL", ] + expect_setequal( + supp$variable, + c("STUDYID", "RDOMAIN", "USUBJID", "IDVAR", "IDVARVAL", "QNAM", + "QLABEL", "QVAL", "QORIG", "QEVAL") + ) +}) diff --git a/tests/testthat/test-list_datasets.R b/tests/testthat/test-list_datasets.R index dccc021..0f466d1 100644 --- a/tests/testthat/test-list_datasets.R +++ b/tests/testthat/test-list_datasets.R @@ -5,7 +5,7 @@ test_that("list_datasets returns a data frame", { test_that("list_datasets contains expected dataset names", { ds <- list_datasets()$dataset - expect_true(all(c("ct_sdtm", "ct_adam", + expect_true(all(c("ct_sdtm", "ct_adam", "ig_sdtm", "ig_adam", "define_xml_schema", "define_xml_stylesheet") %in% ds)) }) @@ -18,5 +18,5 @@ test_that("list_datasets has required columns", { test_that("list_datasets type values are expected set", { types <- unique(list_datasets()$type) - expect_true(all(types %in% c("CT", "Schema", "Stylesheet"))) + expect_true(all(types %in% c("CT", "IG", "Schema", "Stylesheet"))) })