Documentation

12.17 Documentation checks: DOC01-DOC03

The DOC family treats explanation as part of control-stream quality. DOC01 asks whether $PROBLEM is descriptive, DOC02 looks for parameter labels, and DOC03 looks for a useful header comment. These are not cosmetic checks: they reduce the chance that a technically valid model is run, reviewed, or interpreted under the wrong assumptions.

DOC01: describe the problem

$PROBLEM run1 may be legal but tells a reviewer almost nothing. Prefer a concise description that distinguishes population, endpoint, structural model, and major analysis stage when practical. If a file contains multiple problems, make each purpose clear and ensure later records are interpreted in the correct problem context.

DOC02: label parameters

Labels beside THETA, OMEGA, and SIGMA entries create a stable bridge between indices and scientific meanings. Include units or scale when ambiguity is possible: clearance in L/h, a logit parameter, or a residual variance are not interchangeable. Keep labels synchronized after reordering. A stale label can be more dangerous than no label because it appears authoritative.

DOC03: explain provenance

A header can identify the model purpose, source dataset, important assumptions, author/reviewer, and version-control reference. Do not place secrets, patient identifiers, or volatile absolute paths in it. qc-nm's correction header records the nlmx version, date, correction count, and evidence files; it complements rather than replaces scientific provenance.

Documentation checks necessarily use heuristics. A pass cannot judge whether prose is accurate, and a comment cannot establish compliance by itself. Review the source alongside the analysis plan, data specification, and execution evidence.

Common mistakes

  • Using a filename or ticket number as the only scientific description.
  • Copying parameter comments from an older model without verifying indices.
  • Treating an automatically generated correction banner as full provenance.
  • Embedding protected information or machine-specific paths in shared source.

Checklist

  • Write a distinctive $PROBLEM description.
  • Label every estimated and fixed parameter with meaning and units.
  • Add a concise header describing purpose and provenance.
  • Verify comments after every reordering or structural change.
  • Review documentation manually; do not rely on DOC status alone.

Further reading

See correction safety, output provenance, and validation boundary.