Skip to content
Snippets Groups Projects
Unverified Commit a3c50d51 authored by Peter van 't Hof's avatar Peter van 't Hof Committed by GitHub
Browse files

Merge pull request #2 from biowdl/star

Star
parents 664f4787 19de2c0f
No related branches found
No related tags found
No related merge requests found
.idea/
star.wdl 0 → 100644
task Star {
String? preCommand
Array[File] inputR1
Array[File]? inputR2
String genomeDir
String outFileNamePrefix
String? outSAMtype = "BAM SortedByCoordinate"
String? readFilesCommand = "zcat"
Int? runThreadN
String? outStd
String? twopassMode
Array[String]? outSAMattrRGline
#TODO needs to be extended for all possible output extensions
Map[String, String] samOutputNames = {"BAM SortedByCoordinate": "sortedByCoord.out.bam"}
command {
set -e -o pipefail
mkdir -p ${sub(outFileNamePrefix, basename(outFileNamePrefix) + "$", "")}
${preCommand}
STAR \
--readFilesIn ${sep=',' inputR1} ${sep="," inputR2} \
--outFileNamePrefix ${outFileNamePrefix} \
--genomeDir ${genomeDir} \
${"--readFilesCommand " + readFilesCommand} \
${"--outSAMtype " + outSAMtype} \
${"--runThreadN " + runThreadN} \
${"--outStd " + outStd} \
${"--twopassMode " + twopassMode} \
${true="--outSAMattrRGline " false="" defined(outSAMattrRGline)} ${sep=" , " outSAMattrRGline}
}
output {
File bamFile = outFileNamePrefix + "Aligned." + samOutputNames["${outSAMtype}"]
}
runtime {
threads: runThreadN
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment