developing-data-science-notebookslisted
Install: claude install-skill samuhs/mad-science
# Developing Data Science Notebooks
Applies engineering best practices to Jupyter notebooks so the research code is readable, reproducible, and ready to be productionized. Synthesized from: PLOS "Ten Simple Rules" (2019), Google Cloud Jupyter Notebook Manifesto, Cookiecutter Data Science (DrivenData), nbdev, papermill, and the arXiv study on notebook collaboration practices.
## Core Mindset
- **The notebook is exploration and narrative; the product is born from the modules extracted from it.** Treat the notebook like software, not a draft.
- Code that stabilizes gets refactored into functions and modules of your own installable package. The notebook becomes the orchestrator/consumer of that package.
- A "consolidated" notebook is one you can **Runtime → Restart & Run All** with zero errors, top to bottom.
## Checklist: Code Structure
Use this ordering when building the notebook top-down:
1. **Title + preamble (Markdown, H1)**: what the analysis answers, its purpose, audience. Write for your future self (over-explain).
2. **Imports isolated from logic** — never mix `import` statements with computation in the same cell (breaks doc generation and hides side effects; only top-level statements count — imports inside functions/`try` are fine).
3. **Parameters cell at the top** marked with the `parameters` tag (dates, thresholds, paths, file names) — everything that changes between runs. Never bury config in the middle.
4. **One cell = one meaningful step**: one transformation