Agent skill · Data & Analytics

bio-clinical-biostatistics-cdisc-data

Reads, validates, and prepares CDISC SDTM and ADaM clinical trial data for analysis. Covers SDTM domain joins (DM, AE, EX, VS, LB, DS), ADaM architecture (ADSL, BDS, OCCDS, ADTTE) with traceability, treatment-emergent AE conventions, baseline derivation, SUPPQUAL/NSV handling, Define-XML 2.1, and Pinnacle 21 / CORE validation. Use when working with clinical trial datasets in CDISC SDTM/ADaM format, preparing analysis-ready data, or validating for regulatory submission.

BioTender-maxgithub.com/BioTender-maxGitHub ↗
claude-codeships scriptsNOASSERTION
Install
npx skills add BioTender-max/awesome-bio-agent-skills --skill cdisc-data-handling --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 3
SKILL.md size: 28 KB
Bundled scripts: yes
Path: skills/bioskills/cdisc-data-handling/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 135
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

Review
written from the skill's own SKILL.md · Aug 5, 2026

What it does

Reads, validates, and prepares CDISC SDTM and ADaM clinical trial data for analysis. Handles SDTM domain joins (DM, AE, EX, VS, LB, DS), ADaM architecture (ADSL, BDS, OCCDS, ADTTE) with traceability, treatment-emergent AE conventions, baseline derivation, SUPPQUAL/NSV handling, Define-XML 2.1, and Pinnacle 21 / CORE validation. Recommended when working with clinical trial datasets in CDISC SDTM/ADaM format, preparing analysis-ready data, or validating for regulatory submission.

How it works

  • Specifies loading methods for SDTM/ADaM data: Python-based approaches using pyreadstat.read_xport() and pandas merges, and R equivalents for metadata handling (haven.read_xpt, admiral, Pinnacle21/CORE).
  • Demonstrates how to load and merge SDTM domains into ADaM structures while preserving subject/event-level relationships and traceability.
  • Provides concrete examples: loading datasets, computing indicators (e.g., HAD_SERIOUS_AE), and performing left joins to preserve randomized subjects.
  • Documents aggregation strategies and how to aggregate event-level data before merging with DM to avoid row inflation.
  • Describes how to derive ADaM structures: ADSL (one row per subject), BDS (one row per subject/parameter/analysis-timepoint/flag) with required fields (USUBJID, STUDYID, PARAM, AVAL, ABLFL, etc.), and OCCDS/ADTT/EH specifics for TEAE and time-to-event analyses.
  • Includes executable code snippets showing how to compute ADLB from LB, derive ADY, BASE, CHG, PCHG, and how to build baselines.
  • Covers the ADaM CNSR convention for ADTTE and how to map CNSR to standard event indicators for survival analyses.
  • Emphasizes Define-XML 2.1 as metadata requirements for ADaM datasets and traceability.

When to use it

  • Use when working with clinical trial datasets in CDISC SDTM/ADaM format, preparing analysis-ready data, or validating for regulatory submission.
  • Use when requiring site-level and subject-level traceability from SDTM to ADaM, and when performing TEAE conventions, baseline derivation, or Define-XML/CORE validation steps.

What it can touch

  • Python: pyreadstat, pandas (pd.read_sas, pd.merge); specific function calls listed in examples: pyreadstat.read_xport(), pd.read_sas(), pd.merge().
  • R (conceptual equivalents): haven.read_xpt(), admiral, Pinnacle21/CORE for validation.
  • The skill folder ships executable scripts (no explicit external tools beyond the listed ones).

Caveats

  • Compatibility notes reference specific library versions (pyreadstat 1.2+, pandas 2.1+, numpy 1.26+; ADaMIG 1.3, OCCDS 1.1, Define-XML 2.1, Dataset-JSON v1.1) and reliance on regulatory guidance (FDA, ICH E2A/E9, etc.).
  • Warns about ADaM CNSR convention differences between R/Python survival packages and CDISC CNSR expectations; requires conversion when passing ADTTE results to analysis tooling.
  • License indicated as NOASSERTION; explicit licensing terms are not provided in the snippet.
From the SKILL.md

## Version Compatibility Reference examples tested with: pyreadstat 1.2+, pandas 2.1+, numpy 1.26+. CDISC standards referenced: SDTM 2.0 / SDTMIG 3.4 (SDTM 3.0 / SDTMIG 4.0 in public review through April 2026); ADaMIG v1.3 (2021); OCCDS v1.1 (Nov 2021); BDS-for-TTE v1.0; Define-XML 2.1 (FDA-recommended for studies starting on/after March 15, 2023); Dataset-JSON v1.1 (Dec 2025; FDA Federal Register notice April 2025); Pinnacle 21 Community 4.0+; CORE (CDISC Open Rules Engine, 2024). Before using code patterns, verify installed versions match. If versions differ: - Python: `pip show <package>` then `help(module.function)` to check signatures - R packages cited (essential for ADaM derivation): admiral (Roche/openpharma), metacore, metatools, xportr If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying. # CDISC SDTM and ADaM Data Handling **"Load clinical trial data"** -> Parse CDISC SDTM domain files; build or consume ADaM analysis-ready datasets; preserve subject-level and event-level structure; respect traceability and validation expectations for regulatory submission. - Python: `

What's inside
Steps it walks through
  1. Version Compatibility
  2. Aggregation Strategy Taxonomy -- Choose the Right Question
  3. Decision Tree by Scenario
  4. SDTM vs ADaM -- The Regulatory Layer Cake
  5. SDTM Domain Overview
  6. Reading .xpt Files
  7. SAS XPT v5 vs Dataset-JSON -- The 2025-2026 Transition
  8. Joining Domains -- The Right Way
  9. Aggregation strategy must follow the scientific question
  10. ADaM Architecture -- The Postdoc Deep Dive
  11. ADSL (Subject-Level) -- The Spine
  12. BDS (Basic Data Structure) -- Long Format Analysis Data
  13. OCCDS (Occurrence Data Structure) -- One Row per Event
  14. ADTTE (Time-to-Event) -- The CNSR Convention Trap
Ships with 2 files
  • examples/cdisc_data_preparation.py
  • usage-guide.md
Commands it runs
Pinnacle 21 Community (free; appropriate for non-pivotal trials)
p21-community validate --rules sdtmig-3.4 --output-dir validation_output study_data/
More from awesome-bio-agent-skills
All skills →
About this skill
What does the bio-clinical-biostatistics-cdisc-data skill do?

Reads, validates, and prepares CDISC SDTM and ADaM clinical trial data for analysis. Covers SDTM domain joins (DM, AE, EX, VS, LB, DS), ADaM architecture (ADSL, BDS, OCCDS, ADTTE) with traceability, treatment-emergent AE conventions, baseline derivation, SUPPQUAL/NSV handling, Define-XML 2.1, and Pinnacle 21 / CORE validation. Use when working with clinical trial datasets in CDISC SDTM/ADaM format, preparing analysis-ready data, or validating for regulatory submission.

How do I install it?

Run `npx skills add BioTender-max/awesome-bio-agent-skills --skill cdisc-data-handling --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From BioTender-max/awesome-bio-agent-skills, a repository with 135 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going