comparison slamdunk.xml @ 7:5a26589d95ad draft default tip

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/slamdunk commit b5aa6e762b55a9793dc7514efcda05eb2ccd529c"
author iuc
date Sat, 25 Sep 2021 18:21:39 +0000
parents 141f65f7c7c8
children
comparison
equal deleted inserted replaced
6:141f65f7c7c8 7:5a26589d95ad
1 <tool id="slamdunk" name="Slamdunk" version="@TOOL_VERSION@+galaxy3" profile="@PROFILE@"> 1 <tool id="slamdunk" name="Slamdunk" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@PROFILE@">
2 <description>- streamlining SLAM-seq analysis with ultra-high sensitivity</description> 2 <description>- streamlining SLAM-seq analysis with ultra-high sensitivity</description>
3 <macros> 3 <macros>
4 <import>macros.xml</import> 4 <import>macros.xml</import>
5 </macros> 5 </macros>
6 <expand macro="requirements" /> 6 <expand macro="requirements"/>
7 <version_command>slamdunk --version</version_command> 7 <version_command>slamdunk --version</version_command>
8 <command detect_errors="exit_code"><![CDATA[ 8 <command detect_errors="exit_code"><![CDATA[
9 #import re 9 #import re
10
11 mkdir fastq &&
12 #set $reads_id = re.sub('[^\w\-\.]', '_', str($reads.element_identifier))
13 ln -s '$reads' './fastq/$reads_id' &&
10 14
11 #if $reference_source.reference_source_selector == 'history': 15 #if $reference_source.reference_source_selector == 'history':
12 ln -f -s '$reference_source.ref_file' reference.fa && 16 ln -f -s '$reference_source.ref_file' reference.fa &&
13 #else: 17 #else:
14 ln -f -s '$reference_source.ref_file.fields.path' reference.fa && 18 ln -f -s '$reference_source.ref_file.fields.path' reference.fa &&
15 #end if 19 #end if
16 20
17 mkdir ./fastq && 21 slamdunk all -r reference.fa -b '$reference' -o ./out
18 #for $fastq in $reads:
19 #set $fastq_name = re.sub('[^\w\-\.]', '_', str($fastq.element_identifier))
20 ln -s '$fastq' './fastq/${fastq_name}' &&
21 #end for
22
23 slamdunk all -r reference.fa -b '$Reference' -o ./out
24 -t \${GALAXY_SLOTS:-1} 22 -t \${GALAXY_SLOTS:-1}
25 -n $multimapper.multimappers 23 -n $multimapper.multimappers
26 $multimapper.multimap 24 $multimapper.multimap
27 #if $multimapper.filterbed.bedtofilter: 25 #if $multimapper.filterbed.bedtofilter:
28 -fb $multimapper.filterbed.bedtofilter 26 -fb $multimapper.filterbed.bedtofilter
29 #end if 27 #end if
30 -5 $quantseq.trim5 28 -5 $quantseq.trim5
31 -a $quantseq.maxpolyA 29 -a $quantseq.maxpolyA
32 $advanced.endtoend 30 $advanced.endtoend
33 -mq $advanced.minMQ 31 -mq $advanced.minMQ
34 -mi $advanced.minID 32 -mi $advanced.minID
35 -nm=$advanced.maxNM 33 -nm=$advanced.maxNM
36 -mc $advanced.minCov 34 -mc $advanced.minCov
37 -mv $advanced.minVar 35 -mv $advanced.minVar
38 -mbq $advanced.minBaseQual 36 -mbq $advanced.minBaseQual
39 -rl $readLength 37 -rl $readLength
40 -c $covThresh 38 -c $covThresh
41 ./fastq/* 39 #if $advanced.vcf
40 --vcf $advanced.vcf
41 #end if
42 './fastq/$reads_id'
43
44 && mv out/filter/*_slamdunk_mapped_filtered.bam '$outputBam'
45 && mv out/count/*_slamdunk_mapped_filtered_tcount.tsv '$outputTsv'
46 #if not $advanced.vcf
47 && mv out/snp/*_slamdunk_mapped_filtered_snp.vcf '$outputVcf'
48 #end if
42 ]]></command> 49 ]]></command>
43 <inputs> 50 <inputs>
44 <expand macro="reference_files" /> 51 <expand macro="reference_files"/>
45 <param name="reads" type="data" format="fastqsanger,fastqsanger.gz" multiple="True" label="FASTQ files"/> 52 <param name="reads" type="data" format="fastqsanger,fastqsanger.gz" label="FASTQ files"/>
46 <section name="multimapper" title="Multimapper recovery" 53 <section name="multimapper" title="Multimapper recovery"
47 expanded="false"> 54 expanded="false">
48 <section name="filterbed" 55 <section name="filterbed"
49 title="Use separate 3' UTR bed to filter multimappers." expanded="false"> 56 title="Use separate 3' UTR bed to filter multimappers." expanded="false">
50 <param name="bedtofilter" type="data" format="bed" optional="true" 57 <param name="bedtofilter" argument="--filterbed" type="data" format="bed" optional="true"
51 label="Bed to filter" /> 58 label="Bed to filter"/>
52 </section> 59 </section>
53 <param name="multimappers" type="integer" min="1" value="1" 60 <param name="multimappers" argument="--topn" type="integer" min="1" value="1"
54 label="Maximum number of alignments to report per read" 61 label="Maximum number of alignments to report per read"
55 help="The maximum number of alignments is used to track multimapping read alignments. The more are allowed, the more sensitive the multimapper filtering will be, but also the longer the runtime will be. 100 was used in previous publications." /> 62 help="The maximum number of alignments is used to track multimapping read alignments. The more are allowed, the more sensitive the multimapper filtering will be, but also the longer the runtime will be. 100 was used in previous publications."/>
56 <param name="multimap" type="boolean" truevalue="--multimap" falsevalue="" 63 <param name="multimap" argument="--multimap" type="boolean" truevalue="--multimap" falsevalue=""
57 label="Use reference bed file to resolve multimappers." 64 label="Use reference bed file to resolve multimappers."
58 help="Enable multimapper recovery, requires -n to be set to a value > 1 to have impact." /> 65 help="Enable multimapper recovery, requires -n to be set to a value > 1 to have impact."/>
59 </section> 66 </section>
60 <section name="quantseq" title="Quantseq" expanded="false"> 67 <section name="quantseq" title="Quantseq" expanded="false">
61 <param name="trim5" type="integer" min="0" value="12" 68 <param name="trim5" argument="--trim-5p" type="integer" min="0" value="12"
62 label="Number of bp to remove from the 5' end of all reads" 69 label="Number of bp to remove from the 5' end of all reads"
63 help="For Lexogen's Quantseq kit and previous SLAM-seq papers a clipping of 12 bp from the 5' end is recommended." /> 70 help="For Lexogen's Quantseq kit and previous SLAM-seq papers a clipping of 12 bp from the 5' end is recommended."/>
64 <param name="maxpolyA" type="integer" min="0" value="4" 71 <param name="maxpolyA" argument="--max-polya" type="integer" min="0" value="4"
65 label="Maximum number of As at the 3' end of a read" 72 label="Maximum number of As at the 3' end of a read"
66 help="The maximum number of allowed As at the 3' end of a read. All A-stretches that exceed this threshold are clipped because they are likely part of the poly-A tail." /> 73 help="The maximum number of allowed As at the 3' end of a read. All A-stretches that exceed this threshold are clipped because they are likely part of the poly-A tail."/>
67 </section> 74 </section>
68 <section name="advanced" title="Advanced settings." expanded="false"> 75 <section name="advanced" title="Advanced settings." expanded="false">
69 <param name="endtoend" type="boolean" truevalue="--endtoend" falsevalue="" 76 <param name="endtoend" argument="--endtoend" type="boolean" truevalue="--endtoend" falsevalue=""
70 label="Enable end-to-end alignments for mapping." 77 label="Enable end-to-end alignments for mapping."
71 help="Enable end-to-end alignments for mapping in slamdunk with --endtoend" /> 78 help="Enable end-to-end alignments for mapping in slamdunk with --endtoend"/>
72 <param name="minMQ" type="integer" min="0" value="2" 79 <param name="minMQ" argument="--min-mq" type="integer" min="0" value="2"
73 label="Minimum mapping quality" 80 label="Minimum mapping quality"
74 help="Minimum mapping quality to consider alignments (default: 2)." /> 81 help="Minimum mapping quality to consider alignments (default: 2)."/>
75 <param name="minID" type="float" min="0" value="0.95" 82 <param name="minID" argument="--min-identity" type="float" min="0" value="0.95"
76 label="Minimum alignment identity" 83 label="Minimum alignment identity"
77 help="Minimum alignment-identity to consider alignments (default: 0.95)." /> 84 help="Minimum alignment-identity to consider alignments (default: 0.95)."/>
78 <param name="maxNM" type="integer" value="-1" 85 <param name="maxNM" argument="--max-nm" type="integer" value="-1"
79 label="Maximum number of mismatches" 86 label="Maximum number of mismatches"
80 help="Maximum number of mismatches to consider alignments. Negative numbers deactivate filter (default: -1)." /> 87 help="Maximum number of mismatches to consider alignments. Negative numbers deactivate filter (default: -1)."/>
81 <param name="minCov" type="integer" min="0" value="10" 88 <param name="minCov" argument="--min-coverage" type="integer" min="0" value="10"
82 label="Minimum coverage to call variant" 89 label="Minimum coverage to call variant"
83 help="Minimum coverage to call variant (default: 10)." /> 90 help="Minimum coverage to call variant (default: 10)."/>
84 <param name="minVar" type="float" min="0" value="0.8" 91 <param name="minVar" argument="--var-fraction" type="float" min="0" value="0.8"
85 label="Minimum variant fraction to call variant" 92 label="Minimum variant fraction to call variant"
86 help="Minimum variant fraction to call variant (default: 0.8)." /> 93 help="Minimum variant fraction to call variant (default: 0.8)."/>
87 <param name="minBaseQual" type="integer" min="0" value="27" 94 <param name="minBaseQual" argument="--min-base-qual" type="integer" min="0" value="27"
88 label="Minimum base quality" 95 label="Minimum base quality"
89 help="Minimum base quality for T>C conversions (default: 27)." /> 96 help="Minimum base quality for T>C conversions (default: 27)."/>
97 <param argument="--vcf" type="data" format="vcf" optional="true" label="Skip SNP step and provide custom variant file."/>
90 </section> 98 </section>
91 <param name="covThresh" type="integer" min="1" value="1" 99 <param name="covThresh" argument="--conversion-threshold" type="integer" min="1" value="1"
92 label="T>C conversion threshold" 100 label="T>C conversion threshold"
93 help="Number of T>C conversions required to count a read as a T>C read (default: 1)." /> 101 help="Number of T>C conversions required to count a read as a T>C read (default: 1)."/>
94 <param name="readLength" type="integer" min="50" value="50" 102 <param name="readLength" argument="--max-read-length" type="integer" min="50" value="50"
95 label="Read length" 103 label="Read length"
96 help="Maximum read length (before trimming)." /> 104 help="Maximum read length (before trimming)."/>
97 </inputs> 105 </inputs>
98 <outputs> 106 <outputs>
99 <collection name="outputBam" type="list" label="${tool.name} on ${on_string}: BAM"> 107 <data name="outputBam" format="bam" label="${tool.name} on ${on_string}: BAM"/>
100 <discover_datasets pattern="(?P&lt;name&gt;.+)\.bam$" format="bam" directory="./out/filter" visible="false" /> 108 <data name="outputTsv" format="tabular" label="${tool.name} on ${on_string}: Count TSV"/>
101 </collection> 109 <data name="outputVcf" format="vcf" label="${tool.name} on ${on_string}: VCF">
102 <collection name="outputTsv" type="list" label="${tool.name} on ${on_string}: Count TSV"> 110 <filter>advanced['vcf'] == None</filter>
103 <discover_datasets pattern="(?P&lt;name&gt;.+)_tcount.tsv$" format="tabular" directory="./out/count" visible="false" /> 111 </data>
104 </collection>
105 <collection name="outputVcf" type="list" label="${tool.name} on ${on_string}: VCF">
106 <discover_datasets pattern="(?P&lt;name&gt;.+)_snp.vcf$" format="vcf" directory="./out/snp" visible="false" />
107 </collection>
108 </outputs> 112 </outputs>
109 <tests> 113 <tests>
110 <test> 114 <test expect_num_outputs="3">
111 <!--Ensure default outputs work --> 115 <!--Ensure default outputs work -->
112 <param name="reference_source_selector" value="history" /> 116 <param name="reference_source_selector" value="history"/>
113 <param name="ref_file" value="ref.fa" /> 117 <param name="ref_file" value="ref.fa"/>
114 <param name="Reference" value="actb.bed" /> 118 <param name="reference" value="actb.bed"/>
115 <param name="reads" value="reads.fq" /> 119 <param name="reads" value="reads.fq"/>
116 <param name="readLength" value="100" /> 120 <param name="readLength" value="100"/>
117 <section name="quantseq"> 121 <section name="quantseq">
118 <param name="trim5" value="0" /> 122 <param name="trim5" value="0"/>
119 </section> 123 </section>
120 <section name="advanced"> 124 <section name="advanced">
121 <param name="minBaseQual" value="27" /> 125 <param name="minBaseQual" value="27"/>
122 </section> 126 </section>
123 <output_collection name="outputBam"> 127 <output name="outputBam" ftype="bam" value="reads1.bam" compare="sim_size"/>
124 <element name="reads_slamdunk_mapped_filtered" ftype="bam" file="reads1.bam" compare="sim_size" /> 128 <output name="outputTsv" ftype="tabular" value="reads_slamdunk_mapped_filtered_tcount.tsv" compare="re_match"/>
125 </output_collection> 129 <output name="outputVcf" ftype="vcf" file="reads1_snp.vcf" compare="sim_size"/>
126 <output_collection name="outputTsv">
127 <element name="reads_slamdunk_mapped_filtered" ftype="tabular" file="reads_slamdunk_mapped_filtered_tcount.tsv"
128 compare="re_match" />
129 </output_collection>
130 <output_collection name="outputVcf">
131 <element name="reads_slamdunk_mapped_filtered" ftype="vcf" file="reads1_snp.vcf" compare="sim_size" />
132 </output_collection>
133 </test> 130 </test>
134 <test> 131 <test expect_num_outputs="3">
135 <!--Ensure built-in fasta works --> 132 <!--Ensure built-in fasta works -->
136 <param name="reference_source_selector" value="cached" /> 133 <param name="reference_source_selector" value="cached"/>
137 <param name="ref_file" value="hg38full" /> 134 <param name="ref_file" value="hg38full"/>
138 <param name="Reference" value="actb.bed" /> 135 <param name="reference" value="actb.bed"/>
139 <param name="reads" ftype="fastqsanger" dbkey="hg38" value="reads.fq" /> 136 <param name="reads" ftype="fastqsanger" dbkey="hg38" value="reads.fq"/>
140 <param name="readLength" value="100" /> 137 <param name="readLength" value="100"/>
141 <section name="quantseq"> 138 <section name="quantseq">
142 <param name="trim5" value="0" /> 139 <param name="trim5" value="0"/>
143 </section> 140 </section>
144 <section name="advanced"> 141 <section name="advanced">
145 <param name="minBaseQual" value="27" /> 142 <param name="minBaseQual" value="27"/>
146 </section> 143 </section>
147 <output_collection name="outputBam"> 144 <output name="outputBam" ftype="bam" value="reads1.bam" compare="sim_size"/>
148 <element name="reads_slamdunk_mapped_filtered" ftype="bam" file="reads1.bam" compare="sim_size" /> 145 <output name="outputTsv" ftype="tabular" value="reads_slamdunk_mapped_filtered_tcount.tsv" compare="re_match"/>
149 </output_collection> 146 <output name="outputVcf" ftype="vcf" file="reads1_snp.vcf" compare="sim_size"/>
150 <output_collection name="outputTsv"> 147 </test>
151 <element name="reads_slamdunk_mapped_filtered" ftype="tabular" file="reads_slamdunk_mapped_filtered_tcount.tsv" 148 <test expect_num_outputs="2">
152 compare="re_match" /> 149 <!-- test with vcf -->
153 </output_collection> 150 <param name="reference_source_selector" value="history"/>
154 <output_collection name="outputVcf"> 151 <param name="ref_file" value="ref.fa"/>
155 <element name="reads_slamdunk_mapped_filtered" ftype="vcf" file="reads1_snp.vcf" compare="sim_size" /> 152 <param name="reference" value="actb.bed"/>
156 </output_collection> 153 <param name="reads" value="reads.fq"/>
154 <param name="readLength" value="100"/>
155 <section name="quantseq">
156 <param name="trim5" value="0"/>
157 </section>
158 <section name="advanced">
159 <param name="vcf" value="reads_slamdunk_mapped_filtered_snp.vcf" ftype="vcf"/>
160 <param name="minBaseQual" value="27"/>
161 </section>
162 <output name="outputBam" ftype="bam" value="reads1.bam" compare="sim_size"/>
163 <output name="outputTsv" ftype="tabular" value="reads_slamdunk_mapped_filtered_tcount.tsv" compare="re_match"/>
164 <assert_stderr>
165 <not_has_text text="Running slamDunk SNP"/>
166 </assert_stderr>
167 <assert_command>
168 <has_text text="--vcf"/>
169 </assert_command>
157 </test> 170 </test>
158 </tests> 171 </tests>
159 <help><![CDATA[ 172 <help><![CDATA[
160 SLAM-seq 173 SLAM-seq
161 ======== 174 ========
219 232
220 .. _`Slamdunk documentation`: http://t-neumann.github.io/slamdunk/docs.html 233 .. _`Slamdunk documentation`: http://t-neumann.github.io/slamdunk/docs.html
221 234
222 ]]></help> 235 ]]></help>
223 <citations> 236 <citations>
224 <expand macro="citations" /> 237 <expand macro="citations"/>
225 </citations> 238 </citations>
226 </tool> 239 </tool>