Skip to content

Commit

Permalink
BugFix: Fixes Sample mismatch issue in JaBbA after chr coerce
Browse files Browse the repository at this point in the history
  • Loading branch information
tanubrata committed Feb 11, 2024
1 parent 306ecfc commit c6a0554
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 5 deletions.
4 changes: 2 additions & 2 deletions modules/local/jabba/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,8 @@ process COERCE_SEQNAMES {
label 'process_low'

container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'/gpfs/commons/home/tdey/lab/singularity_files/nextflow_singularity_cache/mskilab-jabba_cplex-latest.img':
'mskilab/jabba:latest' }"
'docker://mskilab/jabba_cplex:latest':
'mskilab/jabba_cplex:latest' }"

input:
tuple val(meta), path(file)
Expand Down
28 changes: 25 additions & 3 deletions subworkflows/local/jabba/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -66,18 +66,40 @@ workflow COV_JUNC_JABBA {
// Run COERCE_SEQNAMES to force inputs to be in common
COERCE_SEQNAMES_COV(cov_rds_jabba)
chr_coerced_cov_rds_jabba = COERCE_SEQNAMES_COV.out.file

chr_coerced_cov_rds_jabba_to_cross = chr_coerced_cov_rds_jabba.map { tuple ->
def (meta, cov) = tuple
[meta.patient, meta, cov] }
COERCE_SEQNAMES_SOM_SV(junction_jabba)
chr_coerced_junction_jabba = COERCE_SEQNAMES_SOM_SV.out.file
chr_coerced_junction_jabba_to_cross = chr_coerced_junction_jabba.map { tuple ->
def (meta, vcf) = tuple
[meta.patient, meta, vcf] }

COERCE_SEQNAMES_UNFIL_SOM_SV(j_supp_jabba)
chr_coerced_j_supp_jabba = COERCE_SEQNAMES_UNFIL_SOM_SV.out.file
chr_coerced_j_supp_jabba_to_cross = chr_coerced_j_supp_jabba.map { tuple ->
def (meta, vcf2) = tuple
[meta.patient, meta, vcf2] }

COERCE_SEQNAMES_HETS(het_pileups_wgs_jabba)
chr_coerced_het_pileups_wgs_jabba = COERCE_SEQNAMES_HETS.out.file
chr_coerced_het_pileups_wgs_jabba_to_cross = chr_coerced_het_pileups_wgs_jabba.map { tuple ->
def (meta, hets) = tuple
[meta.patient, meta, hets] }

input_jab = chr_coerced_cov_rds_jabba_to_cross.join(chr_coerced_het_pileups_wgs_jabba_to_cross)
.join(chr_coerced_junction_jabba_to_cross)
.join(chr_coerced_j_supp_jabba_to_cross)
.map{ tuples ->
[tuples[1]] + [tuples[2]] + [tuples[4]] + [tuples[6]] + [tuples[8]]
}
input_coerced_cov = input_jab.map{ meta, cov, hets, vcf, vcf2 -> [ meta, cov ] } //chr stripped cov
input_coerced_hets = input_jab.map{ meta, cov, hets, vcf, vcf2 -> [ meta, hets ] } //chr stripped hetpileups
input_coerced_vcf = input_jab.map{ meta, cov, hets, vcf, vcf2 -> [ meta, vcf ] } //chr stripped somatic sv
input_coerced_vcf2 = input_jab.map{ meta, cov, hets, vcf, vcf2 -> [ meta, vcf2 ] } //chr stripped unfiltered somatic sv

JABBA(chr_coerced_cov_rds_jabba, chr_coerced_junction_jabba, ploidy_jabba, chr_coerced_het_pileups_wgs_jabba,
cbs_seg_rds_jabba, cbs_nseg_rds_jabba, chr_coerced_j_supp_jabba, blacklist_junctions_jabba,
JABBA(input_coerced_cov, input_coerced_vcf, ploidy_jabba, input_coerced_hets,
cbs_seg_rds_jabba, cbs_nseg_rds_jabba, input_coerced_vcf2, blacklist_junctions_jabba,
geno_jabba, indel_jabba, tfield_jabba,
iter_jabba, rescue_window_jabba, rescue_all_jabba, nudgebalanced_jabba,
edgenudge_jabba, strict_jabba, allin_jabba, field_jabba, maxna_jabba,
Expand Down

0 comments on commit c6a0554

Please sign in to comment.