Review ask

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

Lifecycle: draftEditUnder review
What this benchmark means
README.md

Public entries: Python and R. Passing coverage requires an installed inventory.

Goal: require a value only on the rows a condition selects, and allow a share of the rows to lack one: a share at its limit, a deliberately violated warning over it, and a condition that selects no row.

Input: one spec.yaml over adverse events, one row per subject and event, each with a reported and a coded term (AETERM, AEDECOD), a seriousness flag (AESER), a death flag (AESDTH) and start and end dates (AESTDTC, AEENDTC).

Checks:

  • A coded term is required on every event with a reported term. Events without a reported term are not checked.
  • A death flag is required on every serious event. Events that are not serious, or whose seriousness is unknown, are not checked.
  • At most a quarter of the events may lack a start date, and the boundary counts as held.
  • At most a quarter of the events with a reported term may lack an end date. Exceeding that share produces a warning: the run still succeeds and the run report lists the affected events.
  • An end date is required on every event that resulted in death. If no event is selected, the share is zero and the check holds.

The run report (ae-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 events read and built, each output column with its missing values and longest text, then one row per check in column order. A check row carries its label (ID), the column it covers (TARGET), the rule it applies (RULE), its SEVERITY, and how many events failed out of every event of the dataset (COUNT, TOTAL). A held check leaves CONDITION and KEYS empty, reports zero failures and has empty details ({}). The violated warning names its condition, lists the affected events in KEYS, and reports in DETAILS its column and the number of events it checked.

Note: a check with a condition reads only the rows the condition selects; a row whose condition is false or unknown passes whatever it holds. A share is the selected rows lacking the value over the selected rows, so rows outside the condition count in neither, and a condition that selects no row has a share of zero.

Inputs

Under review
1 source file

input/ae_raw.csv

Edit
8 rows
input/ae_raw.csv
USUBJIDAESEQAETERMAEDECODAESERAESDTHAESTDTCAEENDTC
1HEADACHEHeadacheN—2024-01-032024-01-05
2NAUSEANauseaYN2024-01-10—
1RASHRashN——2024-02-09
2DIZZINESSDizziness——2024-02-152024-02-16
1FATIGUEFatigueYN—2024-03-20
2——N—2024-03-25—
1COUGHCoughN—2024-04-022024-04-06
2FEVERPyrexiaYN2024-04-10—

Expected output

Under review
24 expected rows

expected/ae-checks.csv

Edit
16 rows
expected/ae-checks.csv
ARTIFACTKINDSPEC_PATHNAMEIDTARGETRULESEVERITYOUTCOMECONDITIONCOUNTTOTALKEYSDETAILS
ae.csvrunoutput—————succeeded—8——{}
ae.csvinputinput.AE_RAWAE_RAW——————8——{"bytes":364,"path":"input/ae_raw.csv","profile":"csv"}
ae.csvrowsbaseAE_RAW——————88—{}
ae.csvcolumncolumns.USUBJIDUSUBJID——————08—{"max_length":3}
ae.csvcolumncolumns.AESEQAESEQ——————08—{}
ae.csvcolumncolumns.AETERMAETERM——————18—{"max_length":9}
ae.csvcolumncolumns.AEDECODAEDECOD——————18—{"max_length":9}
ae.csvcolumncolumns.AESERAESER——————18—{"max_length":1}
ae.csvcolumncolumns.AESDTHAESDTH——————58—{"max_length":1}
ae.csvcolumncolumns.AESTDTCAESTDTC——————28—{"max_length":10}
ae.csvcolumncolumns.AEENDTCAEENDTC——————38—{"max_length":10}
ae.csvcheckcolumns.AEDECOD.verifications[0].not_missingnot_missingcoded-when-reportedAEDECODCHECK-5errorheld—08—{}
ae.csvcheckcolumns.AESDTH.verifications[0].not_missingnot_missingdeath-when-seriousAESDTHCHECK-5errorheld—08—{}
ae.csvcheckcolumns.AESTDTC.verifications[0].not_missingnot_missingstart-mostly-presentAESTDTCCHECK-5errorheld—08—{}
ae.csvcheckcolumns.AEENDTC.verifications[0].not_missingnot_missingend-mostly-presentAEENDTCCHECK-5warningviolatednot_missing_failed28[{"AESEQ":2,"USUBJID":"S-1"},{"AESEQ":2,"USUBJID":"S-4"}]{"column":"AEENDTC","denominator":7}
ae.csvcheckcolumns.AEENDTC.verifications[1].not_missingnot_missingend-when-fatalAEENDTCCHECK-5errorheld—08—{}

expected/ae.csv

Edit
8 rows
expected/ae.csv
USUBJIDAESEQAETERMAEDECODAESERAESDTHAESTDTCAEENDTC
1HEADACHEHeadacheN—2024-01-032024-01-05
2NAUSEANauseaYN2024-01-10—
1RASHRashN——2024-02-09
2DIZZINESSDizziness——2024-02-152024-02-16
1FATIGUEFatigueYN—2024-03-20
2——N—2024-03-25—
1COUGHCoughN—2024-04-022024-04-06
2FEVERPyrexiaYN2024-04-10—
Shaded columns are derived— = missing value

Human review and assessment

Your review

2 questions and your comments · View benchmark discussions

Mapping spec

Generated from the benchmark YAML; do not edit by hand

Variable NameVariable LabelTypeLengthControlled Terms or FormatOriginCoreConversion DefinitionVariable TypeVariable OrderComments for Define
USUBJIDUnique Subject IdentifierCharCollectedCopy value from AE_RAW.USUBJID.SDTM1
AESEQSequence NumberNumCollectedCopy value from AE_RAW.AESEQ.SDTM2
AETERMReported Term for the Adverse EventCharCollectedCopy value from AE_RAW.AETERM.SDTM3
AEDECODDictionary-Derived TermCharCollectedCopy value from AE_RAW.AEDECOD.SDTM4
AESERSerious EventCharCollectedCopy value from AE_RAW.AESER.SDTM5
AESDTHResults in DeathCharCollectedCopy value from AE_RAW.AESDTH.SDTM6
AESTDTCStart Date/Time of Adverse EventCharCollectedCopy value from AE_RAW.AESTDTC.SDTM7
AEENDTCEnd Date/Time of Adverse EventCharCollectedCopy value from AE_RAW.AEENDTC.SDTM8
VersionDateAuthorDescriptionReviewerSign-off
1.72026-10-20yamaa docs buildRead 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.62026-10-17yamaa docs buildDescribe collected date parts written as ISO 8601 date text and times of day counted in seconds since midnight
1.52026-10-17yamaa docs buildName 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.42026-10-15yamaa docs buildState datetime precision codes through the hour and minute, and complete only the time parts a collected datetime lacks
1.32026-09-29yamaa docs buildShow study codelist names, external dictionaries, and ISO 8601 formats in variable rows; list the document's codelist values and metadata
1.22026-09-29yamaa docs buildClassify ADaM copies from a declared input as Predecessor and recodes as Derived, and SDTM recodes of locally derived columns as Derived
1.12026-09-29yamaa docs buildResolve lookups into the donor record they select, and give every derivation shape a plain-language rule instead of its raw YAML
1.0yamaa docs buildInitial generation from spec.yaml

yamaa code

Public calls generated from benchmark.yaml; results must match the expected output

R

Edit
3 lines
library(yamaa)yamaa_spec("spec.yaml")$run()$output

Python

Edit
3 lines
import yamaayamaa.spec("spec.yaml").run().output