Skip to content

Commit

Permalink
Merge pull request #202 from MaxUlysse/save_bam_mapped
Browse files Browse the repository at this point in the history
--save_bam_mapped works for every settings
  • Loading branch information
maxulysse authored May 8, 2020
2 parents d7370ef + 2b233ab commit 5db3d24
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Piellorieppe is one of the main massif in the Sarek National Park.
- [#180](https://github.com/nf-core/sarek/pull/180) - Now saving Mapped BAMs (and creating TSV) in minimal setting
- [#182](https://github.com/nf-core/sarek/pull/182) - Add possibility to run `HaplotypeCaller` without `dbsnp` so it can be used to actually generate vcfs to build a set of known sites (cf [gatkforums](https://gatkforums.broadinstitute.org/gatk/discussion/1247/what-should-i-use-as-known-variants-sites-for-running-tool-x))
- [#195](https://github.com/nf-core/sarek/pull/195) - Now creating TSV for duplicates marked BAMs in minimal setting
- [#195](https://github.com/nf-core/sarek/pull/195) - Add `--save_bam_mapped` params to save mapped BAMs.
- [#195](https://github.com/nf-core/sarek/pull/195), [#202](https://github.com/nf-core/sarek/pull/202) - Add `--save_bam_mapped` params to save mapped BAMs.
- [#197](https://github.com/nf-core/sarek/pull/197) - Add step `prepare_recalibration` to allow restart from DuplicatesMarked BAMs

### Changed
Expand Down
8 changes: 3 additions & 5 deletions main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -1239,7 +1239,7 @@ process IndexBamFile {
publishDir params.outdir, mode: params.publish_dir_mode,
saveAs: {
if (params.save_bam_mapped) "Preprocessing/${idSample}/Mapped/${it}"
null
else null
}

input:
Expand All @@ -1249,7 +1249,7 @@ process IndexBamFile {
set idPatient, idSample, file("${idSample}.bam"), file("${idSample}.bam.bai") into bam_mapped_merged_indexed
set idPatient, idSample into tsv_bam_indexed

when: !(params.known_indels)
when: params.save_bam_mapped || !(params.known_indels)

script:
"""
Expand Down Expand Up @@ -2136,8 +2136,6 @@ vcfMantaSingle = vcfMantaSingle.dump(tag:'Single Manta')
process TIDDIT {
tag {idSample}

publishDir "${params.outdir}/VariantCalling/${idSample}/TIDDIT", mode: params.publish_dir_mode

publishDir params.outdir, mode: params.publish_dir_mode,
saveAs: {
if (it == "TIDDIT_${idSample}.vcf") "VariantCalling/${idSample}/TIDDIT/${it}"
Expand Down Expand Up @@ -2812,7 +2810,7 @@ process MSIsensor_msi {

tag {idSampleTumor + "_vs_" + idSampleNormal}

publishDir "${params.outdir}/VariantCalling/${idSampleTumor}_vs_${idSampleNormal}/MSIsensor", mode: params.publishDirMode
publishDir "${params.outdir}/VariantCalling/${idSampleTumor}_vs_${idSampleNormal}/MSIsensor", mode: params.publish_dir_mode

input:
set idPatient, idSampleNormal, file(bamNormal), file(baiNormal), idSampleTumor, file(bamTumor), file(baiTumor) from pairBamMsisensor
Expand Down

0 comments on commit 5db3d24

Please sign in to comment.