As a clinical trial statistician or programmer, answer two short questions in Your review: the task and the inputs and outputs. Agreeing with both approves this benchmark; disagreeing with either needs a comment. Propose a fix with the Edit button on any source file, or add it to your comments.
We suggest spending no more than 5 minutes on a review. The other tabs beside Your review are background for assessment, not under review.
Summary
README.mdPublic entries: Python and R. Passing coverage requires an installed inventory.
Goal: derive each subject's date of last exposure (TRTEDT) from the
exposure records, reporting the subjects with more than one record instead
of stopping the run.
Input: one spec.yaml declaring two datasets. DM carries one row per
subject. EX carries exposure records: subject, sequence number, start date
and end date.
Variables:
TRTEDTis the end date of the subject's exposure record that starts last, the later sequence number breaking a tie; a subject with one record takes that record's end date. It is blank when the subject has no exposure record or the selected record has no end date.
Lookups: LAST_EX names each subject's latest exposure record. The
subject is expected to appear once in the exposure records; one that
appears more often is reported, and the latest of its records is read.
The run report (adsl-checks.csv) has one row per item the run handled, each
naming the dataset (ARTIFACT), the kind of item (KIND), where the spec
states it (SPEC_PATH) and the item's name (NAME, identifying an input,
row source, reported event, column, or check): the run and its outcome
(OUTCOME), the input datasets read, the subjects built, then the two counts
of the exposure read: the subjects for which the latest record was chosen
among several, and those for which no record was found. Each count names
the column it feeds (TARGET) and the rule its answer stands in for
(RULE). One row per output column follows, with its missing values and
longest text, then the one check, which carries its label (ID), its
RULE and SEVERITY, the condition it found (CONDITION), and how many
subjects repeat out of how many subjects the exposure records hold (COUNT,
TOTAL). Its KEYS list each repeated subject once, in the order its first
exposure record appears, and its DETAILS name the subject columns, the
exposure dataset and the lookup.
Note: the repeated subjects are reported before any row is built and change nothing that is read: every subject still takes its latest record. Without the order and the choice of the last record, a repeated subject would have no record to read, so the check could not warn and would have to stop the run.
Inputs
Under review2 source filesExpected output
Under review13 expected rowsexpected/adsl-checks.csv
Edit10 rows| ARTIFACT | KIND | SPEC_PATH | NAME | ID | TARGET | RULE | SEVERITY | OUTCOME | CONDITION | COUNT | TOTAL | KEYS | DETAILS |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| adsl.csv | run | output | — | — | — | — | — | succeeded | — | 3 | — | — | {} |
| adsl.csv | input | input.DM | DM | — | — | — | — | — | — | 3 | — | — | {"bytes":55,"path":"input/dm.csv","profile":"csv"} |
| adsl.csv | input | input.EX | EX | — | — | — | — | — | — | 5 | — | — | {"bytes":223,"path":"input/ex.csv","profile":"csv"} |
| adsl.csv | rows | base | DM | — | — | — | — | — | — | 3 | 3 | — | {} |
| adsl.csv | handler | columns.TRTEDT.derivation.source.multiple_matches | multiple_matches | — | TRTEDT | LOOKUP-10 | — | — | — | 2 | — | — | {} |
| adsl.csv | handler | columns.TRTEDT.derivation.source.absent | absent | — | TRTEDT | LOOKUP-24 | — | — | — | 0 | — | — | {} |
| adsl.csv | column | columns.STUDYID | STUDYID | — | — | — | — | — | — | 0 | 3 | — | {"max_length":8} |
| adsl.csv | column | columns.USUBJID | USUBJID | — | — | — | — | — | — | 0 | 3 | — | {"max_length":3} |
| adsl.csv | column | columns.TRTEDT | TRTEDT | — | — | — | — | — | — | 0 | 3 | — | {} |
| adsl.csv | check | intermediates.LAST_EX.verifications[0].unique | unique | one-exposure-record | — | LOOKUP-17 | warning | violated | duplicate_intermediate_records | 2 | 3 | [{"STUDYID":"YAMAA-01","USUBJID":"P03"},{"STUDYID":"YAMAA-01","USUBJID":"P02"}] | {"columns":["STUDYID","USUBJID"],"dataset":"EX","intermediate":"LAST_EX"} |
expected/adsl.csv
Edit3 rows| STUDYID | USUBJID | TRTEDT |
|---|---|---|
| YAMAA-01 | 2024-01-30 | |
| YAMAA-01 | 2024-03-01 | |
| YAMAA-01 | 2024-02-28 |
Human review and assessment
| Dataset Name | Variable Name | Variable Label | Type | Codelist/Controlled Terms | Core | Computational Method | Origin |
|---|---|---|---|---|---|---|---|
| ADSL | STUDYID | Study Identifier | character | Copy value from DM.STUDYID. | Predecessor | ||
| ADSL | USUBJID | Unique Subject Identifier | character | Copy value from DM.USUBJID. | Predecessor | ||
| ADSL | TRTEDT | Date of Last Exposure to Treatment | numeric | ISO 8601 | Take EXENDTC from the last EX record matching on STUDYID and USUBJID, ordered by EX.EXSTDTC then EX.EXSEQ, and no match yields blank. | Derived |
| Version | Date | Author | Description | Reviewer | Sign-off |
|---|---|---|---|---|---|
| 1.7 | 2026-10-20 | yamaa docs build | Read a specification in the 1.0 surface as its 0.5 counterpart; state that missing values stay missing where a mapping declares no missing handler, and leave out a declared missing answer that restates a handler's default | ||
| 1.6 | 2026-10-17 | yamaa docs build | Describe collected date parts written as ISO 8601 date text and times of day counted in seconds since midnight | ||
| 1.5 | 2026-10-17 | yamaa docs build | Name collected precision in words instead of letter codes; state imputation fallbacks, minimum source precision, bounds ignored outside the collected period, and invalid text with no handler as an error; describe date and datetime shifts, imputation flag codes, and partial text giving no date part | ||
| 1.4 | 2026-10-15 | yamaa docs build | State datetime precision codes through the hour and minute, and complete only the time parts a collected datetime lacks | ||
| 1.3 | 2026-09-29 | yamaa docs build | Show study codelist names, external dictionaries, and ISO 8601 formats in variable rows; list the document's codelist values and metadata | ||
| 1.2 | 2026-09-29 | yamaa docs build | Classify ADaM copies from a declared input as Predecessor and recodes as Derived, and SDTM recodes of locally derived columns as Derived | ||
| 1.1 | 2026-09-29 | yamaa docs build | Resolve lookups into the donor record they select, and give every derivation shape a plain-language rule instead of its raw YAML | ||
| 1.0 | yamaa docs build | Initial generation from spec.yaml |
yamaa