summaryrefslogtreecommitdiff
path: root/node_modules/shiki/samples/nextflow.sample
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/shiki/samples/nextflow.sample')
-rw-r--r--node_modules/shiki/samples/nextflow.sample63
1 files changed, 63 insertions, 0 deletions
diff --git a/node_modules/shiki/samples/nextflow.sample b/node_modules/shiki/samples/nextflow.sample
new file mode 100644
index 0000000..a14adac
--- /dev/null
+++ b/node_modules/shiki/samples/nextflow.sample
@@ -0,0 +1,63 @@
+/*
+ * The following pipeline parameters specify the reference genomes
+ * and read pairs and can be provided as command line options
+ */
+params.reads = "$baseDir/data/ggal/ggal_gut_{1,2}.fq"
+params.transcriptome = "$baseDir/data/ggal/ggal_1_48850000_49020000.Ggal71.500bpflank.fa"
+params.outdir = "results"
+
+workflow {
+ read_pairs_ch = channel.fromFilePairs( params.reads, checkIfExists: true )
+
+ INDEX(params.transcriptome)
+ FASTQC(read_pairs_ch)
+ QUANT(INDEX.out, read_pairs_ch)
+}
+
+process INDEX {
+ tag "$transcriptome.simpleName"
+
+ input:
+ path transcriptome
+
+ output:
+ path 'index'
+
+ script:
+ """
+ salmon index --threads $task.cpus -t $transcriptome -i index
+ """
+}
+
+process FASTQC {
+ tag "FASTQC on $sample_id"
+ publishDir params.outdir
+
+ input:
+ tuple val(sample_id), path(reads)
+
+ output:
+ path "fastqc_${sample_id}_logs"
+
+ script:
+ """
+ fastqc.sh "$sample_id" "$reads"
+ """
+}
+
+process QUANT {
+ tag "$pair_id"
+ publishDir params.outdir
+
+ input:
+ path index
+ tuple val(pair_id), path(reads)
+
+ output:
+ path pair_id
+
+ script:
+ """
+ salmon quant --threads $task.cpus --libType=U -i $index -1 ${reads[0]} -2 ${reads[1]} -o $pair_id
+ """
+} \ No newline at end of file