BAMM analysis code — Python 3.12.14

These scripts reproduce the consolidated continuous prediction, held-out permutation importance, residual-tree rules and descriptive response clustering. They retain the original numerical procedures and seeds; only file routing and participant-identifier output were changed. No participant data, predictions, patient identifiers or trained model objects are included.

Install the listed dependencies. Supply the retained 559-record analysis spreadsheet privately:
python validate_patterns.py --input path/to/private_data.xlsx --output local_results
python explain_patterns.py --input path/to/private_data.xlsx --output local_results
python response_clustering.py --input path/to/private_data.xlsx --output local_results

Input: one sheet, one row per distinct participant, original columns as listed in INPUT_COLUMNS.txt. Tirzepatide has already been excluded. The two validation populations are all 559 records and all except DAPAGLIFLOZIN. No patient identifier is required. Baseline signatures define conservative cross-validation groups, not duplicate-patient classification. Outputs are local analytic files; they are not part of this supplement.

This study evaluates model-building procedures by nested internal validation. No externally validated clinical prescribing tool or single final deployable model is claimed. Earlier exploratory association/interactions and wider-predictor analyses are not the consolidated pipeline in these scripts.
