Skip to content
Snippets Groups Projects
Commit d100d917 authored by Beibei Chen's avatar Beibei Chen
Browse files

fix path and bam indexing

parent b77bf445
No related merge requests found
#!/usr/bin/env nextflow #!/usr/bin/env nextflow
params.design="$baseDir/../test_data/samplesheet.csv" params.design="$baseDir/../test_data/samplesheet.csv"
params.bams = "$baseDir/../test_data/*.bam" params.bams = "$baseDir/../test_data/*.bam"
params.bais = "$baseDir/../test_data/*.bai" // params.bais = "$baseDir/../test_data/*.bai"
params.peaks = "$baseDir/../test_data/*.broadPeak" params.peaks = "$baseDir/../test_data/*.broadPeak"
params.genomepath="/project/shared/bicf_workflow_ref/GRCh37" params.genomepath="/project/shared/bicf_workflow_ref/GRCh37"
toppeakcount = 200 toppeakcount = 200
...@@ -17,25 +17,25 @@ ...@@ -17,25 +17,25 @@
diffbind_bams = Channel.fromPath(params.bams) diffbind_bams = Channel.fromPath(params.bams)
diffbind_peaks = Channel.fromPath(params.peaks) diffbind_peaks = Channel.fromPath(params.peaks)
meme_peaks = Channel.fromPath(params.peaks) meme_peaks = Channel.fromPath(params.peaks)
deeptools_bamindex = Channel.fromPath(params.bais) // deeptools_bamindex = Channel.fromPath(params.bais)
diffbind_bamindex = Channel.fromPath(params.bais) // diffbind_bamindex = Channel.fromPath(params.bais)
//process bamindex { process bamindex {
// publishDir "$baseDir/output/", mode: 'copy' publishDir "$baseDir/output/", mode: 'copy'
// input: input:
// file index_bam_files from index_bams file index_bam_files from index_bams
// output: output:
// file "*bai" into deeptools_bamindex file "*bai" into deeptools_bamindex
// file "*bai" into diffbind_bamindex file "*bai" into diffbind_bamindex
//
// script: script:
// """ """
// module load python/2.7.x-anaconda module load python/2.7.x-anaconda
// module load R/3.3.2-gccmkl module load R/3.3.2-gccmkl
// module load samtools/intel/1.3 module load samtools/intel/1.3
// samtools index $index_bam_files samtools index $index_bam_files
// """ """
//} }
process run_deeptools { process run_deeptools {
publishDir "$baseDir/output", mode: 'copy' publishDir "$baseDir/output", mode: 'copy'
...@@ -102,7 +102,7 @@ process run_chipseeker_originalpeak { ...@@ -102,7 +102,7 @@ process run_chipseeker_originalpeak {
""" """
module load python/2.7.x-anaconda module load python/2.7.x-anaconda
module load R/3.3.2-gccmkl module load R/3.3.2-gccmkl
Rscript $baseDir/scripts/runChipseeker.R $design_file ${species} Rscript $baseDir/scripts/runChipseeker.R $design_file ${params.genomepath}
""" """
} }
......
...@@ -8,7 +8,8 @@ args = commandArgs(trailingOnly=TRUE) ...@@ -8,7 +8,8 @@ args = commandArgs(trailingOnly=TRUE)
library(ChIPseeker) library(ChIPseeker)
#Parse the genome path and get genome version #Parse the genome path and get genome version
genome = unlist(strsplit(args[2],"[/]"))[-1] path_elements = unlist(strsplit(args[2],"[/]"))
genome = path_elements[length(path_elements)]
if(genome=="GRCh37") if(genome=="GRCh37")
{ {
......
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