Skip to content
Snippets Groups Projects
Commit 92096435 authored by Venkat Malladi's avatar Venkat Malladi
Browse files

Change order of process. Made diffPeaks a when opperative.

parent 6b3c190b
Branches
Tags
No related merge requests found
......@@ -387,9 +387,6 @@ process consensusPeaks {
}
// Define channel to find number of unique experiments
noUniqueExperiments = uniqueExperiments.splitCsv(sep: '\t', header: true).toList()
// Annotate Peaks
process peakAnnotation {
......@@ -411,57 +408,51 @@ process peakAnnotation {
}
// Calculate Differential Binding Activity
process diffPeaks {
// Motif Search Peaks
process motifSearch {
publishDir "$baseDir/output/${task.process}", mode: 'copy'
input:
file designDiffPeaks
file designMotifSearch
output:
file '*_diffbind.bed' into diffPeaks
file '*_diffbind.csv' into diffPeaksCounts
file '*.pdf' into diffPeaksStats
file 'normcount_peaksets.txt' into normCountPeaks
file "*memechip" into motifSearch
script:
if (noUniqueExperiments.size() == 1) {
"""
touch no_diffbind.bed
touch no_diffbind.csv
touch no_heatmap.pdf
touch no_pca.pdf
touch normcount_peaksets.txt
"""
}
else {
"""
Rscript $baseDir/scripts/diff_peaks.R $designDiffPeaks
"""
}
"""
python3 $baseDir/scripts/motif_search.py -d $designMotifSearch -g $fasta -p $topPeakCount
"""
}
// Motif Search Peaks
process motifSearch {
// Define channel to find number of unique experiments
noUniqueExperiments = uniqueExperiments.splitCsv(sep: '\t', header: true).toList()
// Calculate Differential Binding Activity
process diffPeaks {
publishDir "$baseDir/output/${task.process}", mode: 'copy'
input:
file designMotifSearch
file designDiffPeaks
output:
file "*memechip" into motifSearch
file '*_diffbind.bed' into diffPeaks
file '*_diffbind.csv' into diffPeaksCounts
file '*.pdf' into diffPeaksStats
file 'normcount_peaksets.txt' into normCountPeaks
when:
noUniqueExperiments.size() > 1
script:
script:
"""
python3 $baseDir/scripts/motif_search.py -d $designMotifSearch -g $fasta -p $topPeakCount
Rscript $baseDir/scripts/diff_peaks.R $designDiffPeaks
"""
}
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