Software is now as central to research as lab equipment, yet most researchers never learn how to build, test, and share it well. This book teaches the concepts, tools, and habits that help researchers get more done with less frustration, drawing on its authors’ decades of experience teaching software skills to scientists. It is grounded in three ideas: open science, reproducible research, and sustainable software.
It is written for researchers who already use Python for data analysis and are comfortable with basics like reading files, loops, and functions, but who want to take their coding further. Rather than offering a list of best practices, the book follows a running example: a small team writes and publishes a Python package that tests Zipf’s Law on classic novels from Project Gutenberg. It works as the main text for a one-semester course or for self-study, with many exercises, solutions, and a glossary of key terms.
Along the way, you will learn how to:
- Organize small and medium-sized data science projects
- Use the Unix shell to manage data and code efficiently
- Write Python programs that run from the command line
- Track and share work with Git and GitHub, and collaborate in a welcoming team
- Automate complex workflows with Make and make software configurable
- Test your code, measure test coverage, and handle errors
- Publish code and research openly and reproducibly
- Create Python packages that install in standard ways
The full text is free to read online and can be reused under a Creative Commons license. All royalties go to The Carpentries.
