|
| 1 | +# Snakemake workflow: dna-seq-gatk-variant-calling |
| 2 | + |
| 3 | +[](https://snakemake.readthedocs.io) |
| 4 | +[](https://cdn.rawgit.com/snakemake-workflows/dna-seq-gatk-variant-calling/master/.test/report.html) |
| 5 | + |
| 6 | +This Snakemake pipeline implements the [GATK best-practices workflow](https://software.broadinstitute.org/gatk/best-practices/workflow?id=11145) for calling small genomic variants. |
| 7 | + |
| 8 | +## Authors |
| 9 | + |
| 10 | +* Johannes Köster (https://koesterlab.github.io) |
| 11 | + |
| 12 | + |
| 13 | +## Usage |
| 14 | + |
| 15 | +In any case, if you use this workflow in a paper, don't forget to give credits to the authors by citing the URL of this (original) repository and, if available, its DOI (see above). |
| 16 | + |
| 17 | + |
| 18 | +#### Step 1: Obtain a copy of this workflow |
| 19 | + |
| 20 | +1. Create a new github repository using this workflow [as a template](https://help.github.com/en/articles/creating-a-repository-from-a-template). |
| 21 | +2. [Clone](https://help.github.com/en/articles/cloning-a-repository) the newly created repository to your local system, into the place where you want to perform the data analysis. |
| 22 | + |
| 23 | +#### Step 2: Configure workflow |
| 24 | + |
| 25 | +Configure the workflow according to your needs via editing the file `config.yaml`. |
| 26 | + |
| 27 | +#### Step 3: Execute workflow |
| 28 | + |
| 29 | +Test your configuration by performing a dry-run via |
| 30 | + |
| 31 | + snakemake --use-conda -n |
| 32 | + |
| 33 | +Execute the workflow locally via |
| 34 | + |
| 35 | + snakemake --use-conda --cores $N |
| 36 | + |
| 37 | +using `$N` cores or run it in a cluster environment via |
| 38 | + |
| 39 | + snakemake --use-conda --cluster qsub --jobs 100 |
| 40 | + |
| 41 | +or |
| 42 | + |
| 43 | + snakemake --use-conda --drmaa --jobs 100 |
| 44 | + |
| 45 | +If you not only want to fix the software stack but also the underlying OS, use |
| 46 | + |
| 47 | + snakemake --use-conda --use-singularity |
| 48 | + |
| 49 | +in combination with any of the modes above. |
| 50 | +See the [Snakemake documentation](https://snakemake.readthedocs.io/en/stable/executable.html) for further details. |
| 51 | + |
| 52 | +#### Step 4: Investigate results |
| 53 | + |
| 54 | +After successful execution, you can create a self-contained interactive HTML report with all results via: |
| 55 | + |
| 56 | + snakemake --report report.html |
| 57 | + |
| 58 | +This report can, e.g., be forwarded to your collaborators. |
| 59 | +An example (using some trivial test data) can be seen [here](https://cdn.rawgit.com/snakemake-workflows/dna-seq-gatk-variant-calling/master/.test/report.html). |
| 60 | + |
| 61 | +#### Step 5: Commit changes |
| 62 | + |
| 63 | +Whenever you change something, don't forget to commit the changes back to your github copy of the repository: |
| 64 | + |
| 65 | + git commit -a |
| 66 | + git push |
| 67 | + |
| 68 | +#### Step 6: Contribute back |
| 69 | + |
| 70 | +In case you have also changed or added steps, please consider contributing them back to the original repository: |
| 71 | + |
| 72 | +1. [Fork](https://help.github.com/en/articles/fork-a-repo) the original repo to a personal or lab account. |
| 73 | +2. [Clone](https://help.github.com/en/articles/cloning-a-repository) the fork to your local system, to a different place than where you ran your analysis. |
| 74 | +3. Copy the modified files from your analysis to the clone of your fork, e.g., `cp -r envs rules scripts path/to/fork`. Make sure to **not** accidentally copy config file contents or sample sheets. |
| 75 | +4. Commit and push your changes to your fork. |
| 76 | +5. Create a [pull request](https://help.github.com/en/articles/creating-a-pull-request) against the original repository. |
| 77 | + |
| 78 | +## Testing |
| 79 | + |
| 80 | +Test cases are in the subfolder `.test`. They are automtically executed via continuous integration with Github actions. |
0 commit comments