13.27 Worked example: profiles, covariates, and exposure
The Chapter 13 evidence uses a deterministic single-dose teaching dataset generated by pytools/ch13_examples.py. It is deliberately simple enough to audit and rich enough to exercise profiles, BLQ, covariates, exposure, mutation, custom output, SVG, PNG, CSV, JSON, and HTML.
Data and settings
There are 24 subjects, two dose levels (50 and 100 mg), seven postdose observations per subject, continuous WT/HT/AGE/CRCL, categorical SEX/RACE, and a changing CRCL value. The configuration derives BMI and LOGDV, groups by DOSE, facets by SEX, uses geometric means with 95% confidence intervals, enables observed exposure, and requests PNG plus SVG.
Mutation produces ch13_data_mutated.csv. LOGDV is missing on 24 dose rows because their DV is missing; the log records this expected context rather than hiding it.
Results
The run reports 192 records, 168 observations, 24 doses, and 19 BLQ observations. It creates 28 plot entries and 11 tables. Some standard IDs create both linear/log variants or pages, so 31 standalone figure files are reported. P22 is skipped because the dataset has one DVID; P23 is skipped because no PD DVID exists.
The custom scatter uses subject scope to plot dose-normalized Cmax against derived BMI, colored by SEX with an overall linear smoother. The custom table summarizes CMAX and AUCLAST by dose and SEX. Neither result is intended as a clinical conclusion; they demonstrate reproducible specification and review.

Common mistakes
- Treating deterministic synthetic patterns as external validation.
- Comparing output counts without recognizing scale variants/pages.
- Calling expected missing LOGDV on dose rows a data defect.
- Generalizing teaching units or thresholds to another study.
Checklist
- Run the generator with nlmx 4.3.0 or record another version.
- Reconcile counts and skipped reasons.
- Inspect settings, mutated data, figures, and tables together.
- Recalculate sample BMI/exposure values independently.
- Replace teaching choices with project-approved definitions.
Further reading
Open the configuration, csvdataset, txtsummary, and csvcustom table.