Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing Lint #33

Merged
merged 6 commits into from
Sep 9, 2019
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Initial release of `nf-core/sarek`, created with the [nf-core](http://nf-co.re/)
- [#20](https://github.com/nf-core/sarek/pull/20) - Add `markdownlint` config file
- [#21](https://github.com/nf-core/sarek/pull/21) - Add tests for latest Nextflow version as well
- [#21](https://github.com/nf-core/sarek/pull/21) - Add `genomes.config` for genomes without AWS iGenomes
- [#24](https://github.com/nf-core/sarek/pull/24) - Added GATK4 Mutect2 calling and filtering
- [#24](https://github.com/nf-core/sarek/pull/24) - Added GATK4 Mutect2 calling and filtering
- [#XXX](https://github.com/nf-core/sarek/pull/XXX) - Use Github actions for CI
- [#31](https://github.com/nf-core/sarek/pull/31) - Add nf-core lint
- [#31](https://github.com/nf-core/sarek/pull/31) - Add extra CI to GitHub Actions nf-core extra CI
Expand Down Expand Up @@ -75,7 +75,8 @@ Initial release of `nf-core/sarek`, created with the [nf-core](http://nf-co.re/)
- [#21](https://github.com/nf-core/sarek/pull/21) - Moved smallGRCh37 path to `genomes.config`
- [#24](https://github.com/nf-core/sarek/pull/24) - iGenomes config now contains germline resource for GATK4 Mutect2
- [#31](https://github.com/nf-core/sarek/pull/31) - Move extra CI to GitHub Actions nf-core extra CI
- [#32](https://github.com/nf-core/sarek/pull/32) - Install `ASCAT` with `conda` in the `environment.yml` file
- [#32](https://github.com/nf-core/sarek/pull/32), [#33](https://github.com/nf-core/sarek/pull/33) - Install `ASCAT` with `conda` in the `environment.yml` file
- [#33](https://github.com/nf-core/sarek/pull/33) - use workflow.manifest.version to specify workflow version in path to R scripts for control-FREEC and VEP processes

### `Removed`

Expand All @@ -101,6 +102,7 @@ Initial release of `nf-core/sarek`, created with the [nf-core](http://nf-co.re/)
- [#22](https://github.com/nf-core/sarek/pull/22) - Fix --singleCPUMem issue
- [#31](https://github.com/nf-core/sarek/pull/31) - Fix badges according to nf-core lint
- [#31](https://github.com/nf-core/sarek/pull/31) - Fix rcolorbrewer version according to nf-core lint
- [#33](https://github.com/nf-core/sarek/pull/33) - Fix MD Linting

## [2.3.FIX1] - 2019-03-04

Expand Down
2 changes: 1 addition & 1 deletion bin/scrape_software_versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

regexes = {
'AlleleCount': ['v_allelecount.txt', r"(\S+)"],
'ASCAT': ['v_ascat.txt', r"(\d\.\d+)"],
'ASCAT': ['v_ascat.txt', r"Version: (\S+)"],
'bcftools': ['v_bcftools.txt', r"bcftools (\S+)"],
'BWA': ['v_bwa.txt', r"Version: (\S+)"],
'FastQC': ['v_fastqc.txt', r"FastQC v(\S+)"],
Expand Down
5 changes: 2 additions & 3 deletions docs/output.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,8 @@ For all samples:

[GATK Mutect2](https://github.com/broadinstitute/gatk) calls somatic SNVs and indels via local assembly of haplotypes.

For further reading and documentation see the [Mutect2 manual](https://software.broadinstitute.org/gatk/documentation/tooldocs/current/org_broadinstitute_hellbender_tools_walkers_mutect_Mutect2.php).
It is recommended to have panel of normals [PON](https://gatkforums.broadinstitute.org/gatk/discussion/11136/how-to-call-somatic-mutations-using-gatk4-mutect2) for this version of Mutect2 using at
least 40 normal samples, and you can add your PON file to get filtered somatic calls.
For further reading and documentation see the [Mutect2 manual](https://software.broadinstitute.org/gatk/documentation/tooldocs/current/org_broadinstitute_hellbender_tools_walkers_mutect_Mutect2.php).
It is recommended to have panel of normals [PON](https://gatkforums.broadinstitute.org/gatk/discussion/11136/how-to-call-somatic-mutations-using-gatk4-mutect2) for this version of Mutect2 using at least 40 normal samples, and you can add your PON file to get filtered somatic calls.

For a Tumor/Normal pair only:
**Output directory: `results/VariantCalling/[TUMOR_vs_NORMAL]/Mutect2`**
Expand Down
30 changes: 18 additions & 12 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,17 +314,24 @@ If you prefer, you can specify the full path to your reference genome when you r
--genomeIndex '[path to the genome Index]'
```


### `--germlineResource`

The [germline resource VCF file](https://software.broadinstitute.org/gatk/documentation/tooldocs/current/org_broadinstitute_hellbender_tools_walkers_mutect_Mutect2.php#--germline-resource) (bgzipped and tabixed) needed by GATK4 Mutect2 is a collection of calls that are likely present in the sample, with allele frequencies.
The AF info field must be present.
You can find a smaller, stripped gnomAD VCF file (most of the annotation is removed and only calls signed by PASS are stored) in the iGenomes Annotation/GermlineResource folder.
To add your own germline resource supply

```bash
--germlineResource '[path to my resource.vcf.gz]'
```

### `--germlineResourceIndex`

The [germline resource VCF file](https://software.broadinstitute.org/gatk/documentation/tooldocs/current/org_broadinstitute_hellbender_tools_walkers_mutect_Mutect2.php#--germline-resource) (bgzipped and tabixed) needed
by GATK4 Mutect2 is a collection of calls that are likely present in the sample, with allele frequencies. The AF info field must be present.
You can find a smaller, stripped gnomAD VCF file (most of the annotation is removed and only calls signed by PASS are stored) in the iGenomes Annotation/GermlineResource folder. To add your own
germline resource supply
Tabix index of the germline resource specified at [`--germlineResource`](#--germlineResource).
To add your own germline resource supply

```bash
--germlineResource '[path to my resource.vcf.gz]' --germlineResourceIndex '[path to my resource.vcf.gz.idx]'
--germlineResourceIndex '[path to my resource.vcf.gz.idx]'
```

### `--intervals`
Expand Down Expand Up @@ -353,19 +360,18 @@ If you prefer, you can specify the full path to your reference genome when you r

### `--pon`

When a panel of normals [PON](https://gatkforums.broadinstitute.org/gatk/discussion/24057/how-to-call-somatic-mutations-using-gatk4-mutect2#latest) is defined, you will get filtered
somatic calls as a result. Without PON, there will be no calls with PASS in the INFO field, only an _unfiltered_ VCF is written. It is recommended to make your own panel-of-normals,
as it depends on sequencer and library preparation. For tests in iGenomes there is a dummy PON file in the Annotation/GermlineResource directory, but it _should not be used_ as a
real panel-of-normals file. Provide your PON by:

When a panel of normals [PON](https://gatkforums.broadinstitute.org/gatk/discussion/24057/how-to-call-somatic-mutations-using-gatk4-mutect2#latest) is defined, you will get filtered somatic calls as a result.
Without PON, there will be no calls with PASS in the INFO field, only an _unfiltered_ VCF is written.
It is recommended to make your own panel-of-normals, as it depends on sequencer and library preparation.
For tests in iGenomes there is a dummy PON file in the Annotation/GermlineResource directory, but it _should not be used_ as a real panel-of-normals file.
Provide your PON by:

```bash
--pon '[path to the PON VCF]'
```

If the PON file is bgzipped, there have to be a tabixed index file at the same directory.


### `--snpeffDb`

If you prefer, you can specify the DB version when you run the pipeline:
Expand Down
18 changes: 9 additions & 9 deletions main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,6 @@ process GetSoftwareVersions {
alleleCounter --version &> v_allelecount.txt || true
bcftools version > v_bcftools.txt 2>&1 || true
bwa &> v_bwa.txt 2>&1 || true
cat ${baseDir}/scripts/ascat.R | grep "ASCAT version" &> v_ascat.txt || true
configManta.py --version > v_manta.txt 2>&1 || true
configureStrelkaGermlineWorkflow.py --version > v_strelka.txt 2>&1 || true
echo "${workflow.manifest.version}" &> v_pipeline.txt 2>&1 || true
Expand All @@ -275,6 +274,7 @@ process GetSoftwareVersions {
multiqc --version &> v_multiqc.txt 2>&1 || true
qualimap --version &> v_qualimap.txt 2>&1 || true
R --version &> v_r.txt || true
R -e "library(ASCAT); help(package='ASCAT')" &> v_ascat.txt
samtools --version &> v_samtools.txt 2>&1 || true
tiddit &> v_tiddit.txt 2>&1 || true
vcftools --version &> v_vcftools.txt 2>&1 || true
Expand Down Expand Up @@ -1803,12 +1803,12 @@ process ControlFreecViz {
when: 'controlfreec' in tools

"""
cat /opt/conda/envs/sarek-2.5dev/bin/assess_significance.R | R --slave --args ${cnvTumor} ${ratioTumor}
cat /opt/conda/envs/sarek-2.5dev/bin/assess_significance.R | R --slave --args ${cnvNormal} ${ratioNormal}
cat /opt/conda/envs/sarek-2.5dev/bin/makeGraph.R | R --slave --args 2 ${ratioTumor} ${bafTumor}
cat /opt/conda/envs/sarek-2.5dev/bin/makeGraph.R | R --slave --args 2 ${ratioNormal} ${bafNormal}
perl /opt/conda/envs/sarek-2.5dev/bin/freec2bed.pl -f ${ratioTumor} > ${idSampleTumor}.bed
perl /opt/conda/envs/sarek-2.5dev/bin/freec2bed.pl -f ${ratioNormal} > ${idSampleNormal}.bed
cat /opt/conda/envs/sarek-${workflow.manifest.version}/bin/assess_significance.R | R --slave --args ${cnvTumor} ${ratioTumor}
cat /opt/conda/envs/sarek-${workflow.manifest.version}/bin/assess_significance.R | R --slave --args ${cnvNormal} ${ratioNormal}
cat /opt/conda/envs/sarek-${workflow.manifest.version}/bin/makeGraph.R | R --slave --args 2 ${ratioTumor} ${bafTumor}
cat /opt/conda/envs/sarek-${workflow.manifest.version}/bin/makeGraph.R | R --slave --args 2 ${ratioNormal} ${bafNormal}
perl /opt/conda/envs/sarek-${workflow.manifest.version}/bin/freec2bed.pl -f ${ratioTumor} > ${idSampleTumor}.bed
perl /opt/conda/envs/sarek-${workflow.manifest.version}/bin/freec2bed.pl -f ${ratioNormal} > ${idSampleNormal}.bed
"""
}

Expand Down Expand Up @@ -2069,7 +2069,7 @@ process VEP {
genome = params.genome == 'smallGRCh37' ? 'GRCh37' : params.genome
dir_cache = (params.vep_cache && params.annotation_cache) ? " \${PWD}/${dataDir}" : "/.vep"
cadd = (params.cadd_cache && params.cadd_WG_SNVs && params.cadd_InDels) ? "--plugin CADD,whole_genome_SNVs.tsv.gz,InDels.tsv.gz" : ""
genesplicer = params.genesplicer ? "--plugin GeneSplicer,/opt/conda/envs/sarek-2.5dev/bin/genesplicer,/opt/conda/envs/sarek-2.5dev/share/genesplicer-1.0-1/human,context=200,tmpdir=\$PWD/${reducedVCF}" : "--offline"
genesplicer = params.genesplicer ? "--plugin GeneSplicer,/opt/conda/envs/sarek-${workflow.manifest.version}/bin/genesplicer,/opt/conda/envs/sarek-${workflow.manifest.version}/share/genesplicer-1.0-1/human,context=200,tmpdir=\$PWD/${reducedVCF}" : "--offline"
"""
mkdir ${reducedVCF}

Expand Down Expand Up @@ -2132,7 +2132,7 @@ process VEPmerge {
genome = params.genome == 'smallGRCh37' ? 'GRCh37' : params.genome
dir_cache = (params.vep_cache && params.annotation_cache) ? " \${PWD}/${dataDir}" : "/.vep"
cadd = (params.cadd_cache && params.cadd_WG_SNVs && params.cadd_InDels) ? "--plugin CADD,whole_genome_SNVs.tsv.gz,InDels.tsv.gz" : ""
genesplicer = params.genesplicer ? "--plugin GeneSplicer,/opt/conda/envs/sarek-2.5dev/bin/genesplicer,/opt/conda/envs/sarek-2.5dev/share/genesplicer-1.0-1/human,context=200,tmpdir=\$PWD/${reducedVCF}" : "--offline"
genesplicer = params.genesplicer ? "--plugin GeneSplicer,/opt/conda/envs/sarek-${workflow.manifest.version}/bin/genesplicer,/opt/conda/envs/sarek-${workflow.manifest.version}/share/genesplicer-1.0-1/human,context=200,tmpdir=\$PWD/${reducedVCF}" : "--offline"
"""
mkdir ${reducedVCF}

Expand Down