-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcellrangers.nf
67 lines (55 loc) · 1.74 KB
/
cellrangers.nf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#!/usr/bin/ nextflow
nextflow.enable.dsl=1
/*
========================================================================================
QC Report Generator Nextflow Workflow
========================================================================================
Github :
Contact :
----------------------------------------------------------------------------------------
*/
Channel
.fromPath( params.samples_csv )
.splitCsv( header: true, sep: ',' )
.map { row -> row.sample_id }
.set { sample_id_ch }
(sample_id) = sample_id_ch.into(1)
/*
Channel
.fromPath( params.samples_csv )
.splitCsv( header: true, sep: ',' )
.map { row -> row.sample_id }
.set { sample_id }
*/
println """\
RNA Seq - N F P I P E L I N E
===================================
Experiment : ${params.experiment_id}
Samplesheet : ${params.in_key}
CellRangersOuts Directory : ${params.cellrangers_outdir}
QC Report input directory : ${params.qc_in_dir}
QC Report Output directory: ${params.qc_output}
"""
.stripIndent()
/* set ref directory e.g. (mouse,human,fly) */
ref = params.genomedir
process cellranger_count {
publishDir (
path: "${params.outdir}/cellrangersouts",
mode: 'copy',
overwrite: 'true',
)
input:
each sample_id
output:
file("${sample_id}/*") into cellrangers_outs
script:
"""
${params.cellranger_software_path}/cellranger count --id=$sample_id \
--transcriptome=${ref} \
--fastqs=${params.fastq_path}/$sample_id \
--sample=$sample_id \
--localcores=${params.cores} \
--localmem=${params.mem}
"""
}