Skip to content
Snippets Groups Projects
Commit d0d5114b authored by Gervaise Henry's avatar Gervaise Henry :cowboy:
Browse files

Add TPM calculation to nf

parent 1f1c6075
Branches
Tags
2 merge requests!37v0.0.1,!22Resolve "process_count"
Pipeline #6231 canceled with stages
in 2 minutes and 15 seconds
...@@ -38,6 +38,7 @@ referenceBase = "/project/BICF/BICF_Core/shared/gudmap/references" ...@@ -38,6 +38,7 @@ referenceBase = "/project/BICF/BICF_Core/shared/gudmap/references"
// Define script files // Define script files
script_bdbagFetch = Channel.fromPath("${baseDir}/scripts/bdbagFetch.sh") script_bdbagFetch = Channel.fromPath("${baseDir}/scripts/bdbagFetch.sh")
script_parseMeta = Channel.fromPath("${baseDir}/scripts/parseMeta.py") script_parseMeta = Channel.fromPath("${baseDir}/scripts/parseMeta.py")
script_calculateTPM = Channel.fromPath("${baseDir}/scripts/calculateTPM.R")
/* /*
* splitData: split bdbag files by replicate so fetch can occure in parallel, and rename files to replicate rid * splitData: split bdbag files by replicate so fetch can occure in parallel, and rename files to replicate rid
...@@ -335,7 +336,7 @@ process alignData { ...@@ -335,7 +336,7 @@ process alignData {
*dedupData: mark the duplicate reads, specifically focused on PCR or optical duplicates *dedupData: mark the duplicate reads, specifically focused on PCR or optical duplicates
*/ */
process dedupData { process dedupData {
tag "${repRID}" tag "${repRID}"git reset --soft HEAD^
publishDir "${outDir}/bam", mode: 'copy', pattern: "*.deduped.bam" publishDir "${outDir}/bam", mode: 'copy', pattern: "*.deduped.bam"
publishDir "${logsDir}", mode: 'copy', pattern: "*.dedup.{out,err}" publishDir "${logsDir}", mode: 'copy', pattern: "*.dedup.{out,err}"
...@@ -412,6 +413,7 @@ process makeFeatureCounts { ...@@ -412,6 +413,7 @@ process makeFeatureCounts {
publishDir "${logsDir}", mode: 'copy', pattern: "${repRID}.makeFetureCounts.{out,err}" publishDir "${logsDir}", mode: 'copy', pattern: "${repRID}.makeFetureCounts.{out,err}"
input: input:
path script_calculateTPM
tuple val (repRID1), path (bam), path (bai) from featureCountsIn tuple val (repRID1), path (bam), path (bai) from featureCountsIn
tuple val (repRID2), path (genome), path (gtf) from featureCountsRef tuple val (repRID2), path (genome), path (gtf) from featureCountsRef
...@@ -421,5 +423,6 @@ process makeFeatureCounts { ...@@ -421,5 +423,6 @@ process makeFeatureCounts {
script: script:
""" """
featureCounts -R SAM -p -G ${genome} -T `nproc` -a ${gtf} -o ${repRID}.featureCounts ${repRID}.sorted.deduped.bam featureCounts -R SAM -p -G ${genome} -T `nproc` -a ${gtf} -o ${repRID}.featureCounts ${repRID}.sorted.deduped.bam
Rscript calculateTPM.R --count "${repRID}.featureCounts"
""" """
} }
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment