skills/science/stat-modeling-tools/SKILL.md
Statistical modeling workflow guide for hypothesis tests, effect-size reporting, statsmodels regression, diagnostics, and structured result export. Use when the user asks for statistical test selection, OLS or logistic regression, coefficient tables, inference, or reproducible statistical summaries for scientific datasets.
npx skillsauth add drugclaw/drugclaw stat-modeling-toolsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Use this skill when the user needs reproducible statistical analysis rather than only visual inspection.
Typical triggers:
which python3 || true
python3 - <<'PY'
mods = ["numpy", "pandas", "scipy", "statsmodels"]
for name in mods:
try:
__import__(name)
print(f"{name}: ok")
except Exception as exc:
print(f"{name}: missing ({exc})")
PY
If key modules are missing, say so explicitly and recommend the optional drug-sandbox image documented in docs/operations/science-runtime.md.
templates/stat_test_report.pytemplates/statsmodels_regression.pypython3 templates/stat_test_report.py \
--input stats/assay.csv \
--test independent_ttest \
--value-column response \
--group-column arm \
--group-a control \
--group-b treated \
--output stats/assay_ttest.csv \
--summary stats/assay_ttest.json
Supported baseline tests in the bundled template:
independent_ttestpaired_ttestmannwhitneychi_squarepearsonspearmanUse this for quick but explicit statistical reporting.
python3 templates/statsmodels_regression.py \
--input stats/cohort.csv \
--model ols \
--outcome response \
--feature age \
--feature dose \
--feature biomarker \
--output stats/ols_coefficients.csv \
--summary stats/ols_summary.json
Supported baseline models in the bundled template:
olslogitpoissonUse this for:
For Kaplan-Meier, Cox models, and time-to-event workflows, activate survival-analysis-tools.
For static or interactive figures, activate scientific-visualization-tools.
For study design, reproducibility planning, or manuscript critique, activate scientific-workflow-tools or clinical-research-tools.
tools
Survival and time-to-event workflow guide for Kaplan-Meier summaries, log-rank tests, and Cox proportional hazards models with reproducible outputs. Use when the user asks for time-to-event analysis, censored data summaries, hazard ratios, or survival-group comparison for research datasets.
tools
Research-method workflow guide for hypothesis framing, peer-review style critique, reproducibility planning, study-design checks, and scientific-writing structure. Use when the user asks for manuscript critique, research-gap framing, hypothesis generation, reproducibility checklists, or study-planning support that should stay on the research side rather than patient-care decisions.
tools
Scientific visualization workflow guide for publication-ready static figures with seaborn or matplotlib and interactive figures with Plotly. Use when the user asks for scientific plots, cohort or assay figures, publication graphics, dashboards, or reusable plotting scripts for research datasets.
tools
Drug-patent landscape workflow guide for searching US patents via the PatentsView API, classifying pharmaceutical claim types (NCE, formulation, method-of-use, polymorph, combination, biologic, process), grouping by patent family and assignee, estimating expiry timelines, and cross-referencing the FDA Orange Book for marketed-drug exclusivity windows. Use when the user asks about patent coverage, IP white-space, patent cliffs, or competitive filing activity around a drug, target, or compound class without asking for legal counsel.