Skip to content

Commit

Permalink
update input set mapping
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmyliu1326 committed May 3, 2024
1 parent 57c43bf commit 9c45d9d
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 29 deletions.
8 changes: 4 additions & 4 deletions nanopore_isolate_wgs.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
sample,fastq_dir
ERR7565110,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565110/
ERR7565112,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565112/
ERR7565113,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565113/
sample,fastq_1,fastq_2,fastq_dir,genome
ERR7565110,,,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565110/,
ERR7565112,,,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565112/,
ERR7565113,,,/mnt/cidgoh-object-storage/hackathon/seqqc/isolate_wgs/nanopore/sra_split/ERR7565113/,
6 changes: 3 additions & 3 deletions samplesheet_genome.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
sample,genome
GCA_010673125,/mnt/cidgoh-object-storage/hackathon/seqqc/genome_asm/GCA_010673125.1/GCA_010673125.1.fa
GCA_010798115,/mnt/cidgoh-object-storage/hackathon/seqqc/genome_asm/GCA_010798115.1/GCA_010798115.1.fa
sample,fastq_1,fastq_2,fastq_dir,genome
GCA_010673125,,,,/mnt/cidgoh-object-storage/hackathon/seqqc/genome_asm/GCA_010673125.1/GCA_010673125.1.fa.gz
GCA_010798115,,,,/mnt/cidgoh-object-storage/hackathon/seqqc/genome_asm/GCA_010798115.1/GCA_010798115.1.fa.gz
44 changes: 22 additions & 22 deletions subworkflows/local/utils_nfcore_bacpaq_pipeline/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -81,29 +81,29 @@ workflow PIPELINE_INITIALISATION {

Channel
.fromSamplesheet("input")
.map {
meta, fastq_1, fastq_2, fastq_dir, genome ->

// map illumina data
if (fastq_1) {
if (!fastq_2) {
return [ [ meta.id, single_end:true ], fastq_1 ]
} else {
return [ [ meta.id, single_end:false ], fastq_1, fastq_2 ]
}
}

// map nanopore data
if (fastq_dir) {
return [ [ meta.id, single_end:true ], fastq_dir ]
}

// map nanopore data
if (genome) {
return [ [ meta.id, single_end:true ], genome ]
}
// .map {
// meta, fastq_1, fastq_2, fastq_dir, genome ->

// // map illumina data
// if (fastq_1) {
// if (!fastq_2) {
// return [ [ id:meta.id, single_end: true ], fastq_1 ]
// } else {
// return [ [ id:meta.id, single_end: false ], fastq_1, fastq_2 ]
// }
// }

// // map nanopore data
// if (fastq_dir) {
// return [ [ id:meta.id, single_end: true ], fastq_dir ]
// }

// // map nanopore data
// if (genome) {
// return [ [ id:meta.id, single_end: true ], genome ]
// }

}
// }
// .groupTuple()
// .map {
// validateInputSamplesheet(it)
Expand Down
7 changes: 7 additions & 0 deletions workflows/bacpaq.nf
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,14 @@ workflow BACPAQ {
multiqc_report = ''

if (params.workflow == 'seqqc') {
// if (params.platform == 'illumina') {
// ch_input = samplesheet
// .map {
// return [id:meta.id]
// }
// }
// SEQQC ()

samplesheet.view()
}
else if (params.workflow == 'annotation') {
Expand Down

0 comments on commit 9c45d9d

Please sign in to comment.