zavolanlab/zarp

The Zavolab Automated RNA-seq Pipeline

Overview

Topics: bioinformatics rna-seq snakemake conda docker fair high-throughput pipeline reproducible-research singularity transcriptomics workflow

Latest release: v1.0.0-rc.1, Last update: 2024-11-02

Linting: linting: failed, Formatting:formatting: passed

Deployment

Step 1: Install Snakemake and Snakedeploy

Snakemake and Snakedeploy are best installed via the Mamba package manager (a drop-in replacement for conda). If you have neither Conda nor Mamba, it is recommended to install Miniforge. More details regarding Mamba can be found here.

When using Mamba, run

mamba create -c conda-forge -c bioconda --name snakemake snakemake snakedeploy

to install both Snakemake and Snakedeploy in an isolated environment. For all following commands ensure that this environment is activated via

conda activate snakemake

Step 2: Deploy workflow

With Snakemake and Snakedeploy installed, the workflow can be deployed as follows. First, create an appropriate project working directory on your system and enter it:

mkdir -p path/to/project-workdir
cd path/to/project-workdir

In all following steps, we will assume that you are inside of that directory. Then run

snakedeploy deploy-workflow https://github.com/zavolanlab/zarp . --tag v1.0.0-rc.1

Snakedeploy will create two folders, workflow and config. The former contains the deployment of the chosen workflow as a Snakemake module, the latter contains configuration files which will be modified in the next step in order to configure the workflow to your needs.

Step 3: Configure workflow

To configure the workflow, adapt config/config.yml to your needs following the instructions below.

Step 4: Run workflow

The deployment method is controlled using the --software-deployment-method (short --sdm) argument.

To run the workflow with automatic deployment of all required software via conda/mamba, use

snakemake --cores all --sdm conda

To run the workflow using apptainer/singularity, use

snakemake --cores all --sdm apptainer

Snakemake will automatically detect the main Snakefile in the workflow subfolder and execute the workflow module that has been defined by the deployment in step 2.

For further options such as cluster and cloud execution, see the docs.

Step 5: Generate report

After finalizing your data analysis, you can automatically generate an interactive visual HTML report for inspection of results together with parameters and code inside of the browser using

snakemake --report report.zip

Configuration

The following section is imported from the workflow’s config/README.md.

Dependencies installation

Install dependencies with:

mamba env create -f install/environment.yml

Activate environment

Activate the Conda environment with:

conda activate zarp

Run the workflow on your own samples

  1. Assuming that your current directory is the repository's root directory, create [...] and enter it, with:

    mkdir config/my_run
    cd config/my_run
  2. Create an empty sample table and a workflow configuration file:

    touch samples.tsv
    touch config.yaml
  3. Use your editor of choice to populate these files with appropriate values. Have a look at the examples in the tests/ directory to see what the files should look like, specifically:

More execution options

For more execution options, like sample fetching from SRA, inferring sample metadata from the data itself, cluster execution, and many more, visit ZARP general and in-depth pipeline docmentation.

Linting and formatting

Linting results

FileNotFoundError in file /tmp/tmp_8kwffte/zavolanlab-zarp-ac95347/workflow/Snakefile, line 16:
[Errno 2] No such file or directory: 'samples.tsv'
  File "/tmp/tmp_8kwffte/zavolanlab-zarp-ac95347/workflow/Snakefile", line 16, in <module>
  File "/home/michael/miniforge3/envs/snakemake-workflow-catalog/lib/python3.12/site-packages/pandas/io/parsers/readers.py", line 1026, in read_csv
  File "/home/michael/miniforge3/envs/snakemake-workflow-catalog/lib/python3.12/site-packages/pandas/io/parsers/readers.py", line 620, in _read
  File "/home/michael/miniforge3/envs/snakemake-workflow-catalog/lib/python3.12/site-packages/pandas/io/parsers/readers.py", line 1620, in __init__
  File "/home/michael/miniforge3/envs/snakemake-workflow-catalog/lib/python3.12/site-packages/pandas/io/parsers/readers.py", line 1880, in _make_engine
  File "/home/michael/miniforge3/envs/snakemake-workflow-catalog/lib/python3.12/site-packages/pandas/io/common.py", line 873, in get_handle

Formatting results

None