One key to open reproducible science is to provide rigorous organization of all workflow code. Not just for when you send your project to someone else. A future version of yourself will also benefit when you return to an organized workflow after some time away.
This repository provides a Python script and Jupyter Notebook both containing an example workflow structure for open reproducible science projects. The example workflow contains the following stages:
- Environment Setup
- User-Defined Variables
- Data Acquisition
- Data Preprocessing
- Data Processing
- Data Postprocessing
- Data Visualization
- Data Export
In addition to the example files that contain all workflow stages, this repository includes a Makefile to create placeholder scripts organized by workflow task, as follows:
01-code-scripts/
├── 01-acquire-data.py
├── 02-preprocess-data.py
├── 03-process-data.py
├── 04-postprocess-data.py
└── 05-visualize-data.py
Complementary resources:
To run this project locally, you will need:
To run this project in a web browser, click the icon below to launch the project with Binder:
Within Binder, click "New" and select "Terminal" to open a terminal in the root project folder.
From the terminal, you can create and activate the project Conda environment.
Create environment:
$ conda env create -f environment.yml
Activate environment:
$ conda activate reproducible-science
From the terminal (locally or within Binder), you can run the example workflow, create the placeholder scripts, and delete the placeholder scripts.
Run example workflow:
$ make run
Create placeholder scripts:
$ make scripts
Delete placeholder scripts:
$ make clean
Contains all example code.
Contains information required to create the Conda environment.
Contains instructions to execute the code.