comparison bbmerge.xml @ 2:16db2a5b73c5 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bbtools commit cd59ba2c349865259b92302a1d70e103b8a5e3cb
author iuc
date Tue, 27 Aug 2024 10:13:32 +0000
parents a669d974b9bc
children 1f6a6b1af62b
comparison
equal deleted inserted replaced
1:03646ca53c91 2:16db2a5b73c5
2 <description>Merge overlapping mates of a read pair</description> 2 <description>Merge overlapping mates of a read pair</description>
3 <macros> 3 <macros>
4 <import>macros.xml</import> 4 <import>macros.xml</import>
5 </macros> 5 </macros>
6 <expand macro="edam_ontology"/> 6 <expand macro="edam_ontology"/>
7 <expand macro="bio.tools"/>
7 <expand macro="requirements"/> 8 <expand macro="requirements"/>
8 <command detect_errors="exit_code"><![CDATA[ 9 <command detect_errors="exit_code"><![CDATA[
9 #import os
10 #import re
11
12 #if str($input_type_cond.input_type) in ['single', 'pair']: 10 #if str($input_type_cond.input_type) in ['single', 'pair']:
13 #set read1 = $input_type_cond.read1 11 #set read1 = $input_type_cond.read1
14 ## bbmerge uses the file extension to determine the input format. 12 ## bbmerge uses the file extension to determine the input format.
15 #set ext = '.fastq' 13 #set ext = '.fastq'
16 #if $read1.ext.endswith('.gz'): 14 #if $read1.ext.endswith('.gz'):
23 #set read2_file = 'reverse' + $ext 21 #set read2_file = 'reverse' + $ext
24 ln -s '${read2}' '${read2_file}' && 22 ln -s '${read2}' '${read2_file}' &&
25 #end if 23 #end if
26 #else: 24 #else:
27 #set read1 = $input_type_cond.reads_collection['forward'] 25 #set read1 = $input_type_cond.reads_collection['forward']
28 #set read1_identifier = re.sub('[^\s\w\-]', '_', str($read1.element_identifier))
29 ## bbmap uses the file extension to determine the input format. 26 ## bbmap uses the file extension to determine the input format.
30 #set ext = $read1_identifier + '.fastq' 27 #set ext = '.fastq'
31 #if $read1.ext.endswith('.gz'): 28 #if $read1.ext.endswith('.gz'):
32 #set ext = $ext + '.gz' 29 #set ext = $ext + '.gz'
33 #end if 30 #end if
34 #set read1_file = $read1_identifier + $ext 31 #set read1_file = 'forward' + $ext
35 ln -s '${read1}' '${read1_file}' && 32 ln -s '${read1}' '${read1_file}' &&
36 #set read2 = $input_type_cond.reads_collection['reverse'] 33 #set read2 = $input_type_cond.reads_collection['reverse']
37 #set read2_identifier = re.sub('[^\s\w\-]', '_', str($read2.element_identifier)) 34 #set read2_file = 'reverse' + $ext
38 #set read2_file = $read2_identifier + $ext
39 ln -s '${read2}' '${read2_file}' && 35 ln -s '${read2}' '${read2_file}' &&
40 #end if 36 #end if
41 37
42 bbmerge.sh 38 if [[ "\${_JAVA_OPTIONS}" != *-Xmx* && "\${JAVA_TOOL_OPTIONS}" != *-Xmx* ]]; then
39 export _JAVA_OPTIONS="\${_JAVA_OPTIONS} -Xmx\${GALAXY_MEMORY_MB:-4096}m -Xms256m";
40 fi &&
41
42 bbmerge.sh tmpdir="\$TMPDIR" t="\${GALAXY_SLOTS:-2}"
43
43 #### Input parameters 44 #### Input parameters
44 #if str($input_type_cond.input_type) == 'single': 45 #if str($input_type_cond.input_type) == 'single':
45 in='${read1_file}' 46 in='${read1_file}'
46 interleaved=t 47 interleaved=t
47 #else: 48 #else:
95 96
96 $merge_options.strictness=t 97 $merge_options.strictness=t
97 ]]></command> 98 ]]></command>
98 <inputs> 99 <inputs>
99 <expand macro="input_type_cond"/> 100 <expand macro="input_type_cond"/>
100
101 <section name="qt_options" title="Quality and trimming options"> 101 <section name="qt_options" title="Quality and trimming options">
102 <param name="qtrim" type="select" label="Select option for quality trimming ends before mapping"> 102 <param name="qtrim" type="select" label="Select option for quality trimming ends before mapping">
103 <option value="f" selected="true">No trimming</option> 103 <option value="f" selected="true">No trimming</option>
104 <option value="l">Trim left</option> 104 <option value="l">Trim left</option>
105 <option value="r">Trim right</option> 105 <option value="r">Trim right</option>
107 </param> 107 </param>
108 <param argument="trimq" type="integer" value="6" label="Trim regions with average quality below this value"/> 108 <param argument="trimq" type="integer" value="6" label="Trim regions with average quality below this value"/>
109 <param argument="minlength_after_trim" type="integer" value="60" label="Don't trim reads to be shorter than this value"/> 109 <param argument="minlength_after_trim" type="integer" value="60" label="Don't trim reads to be shorter than this value"/>
110 <param argument="usequality" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Use quality scores when determining which read kmers to use as seeds?"/> 110 <param argument="usequality" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Use quality scores when determining which read kmers to use as seeds?"/>
111 </section> 111 </section>
112
113 <section name="merge_options" title="Merging parameters"> 112 <section name="merge_options" title="Merging parameters">
114 <param name="strictness" type="select" label="Select option for quality trimming ends before mapping"> 113 <param name="strictness" type="select" label="Select option for quality trimming ends before mapping">
115 <option value="xstrict">max strict</option> 114 <option value="xstrict">max strict</option>
116 <option value="ustrict">ultra strict</option> 115 <option value="ustrict">ultra strict</option>
117 <option value="vstrict">very strict</option> 116 <option value="vstrict">very strict</option>
125 </param> 124 </param>
126 <param argument="ecco" type="boolean" truevalue="t" falsevalue="f" checked="false" label="Error-correct the overlapping part, but don't merge." help="If selected, the tool with find the overlaps as if merging reads, use this overlap information to correct sequencing errors on both strands. However, the strands from the mates will not be merged but provided as two separate reads after error correction."/> 125 <param argument="ecco" type="boolean" truevalue="t" falsevalue="f" checked="false" label="Error-correct the overlapping part, but don't merge." help="If selected, the tool with find the overlaps as if merging reads, use this overlap information to correct sequencing errors on both strands. However, the strands from the mates will not be merged but provided as two separate reads after error correction."/>
127 <param argument="trimnonoverlapping" type="boolean" truevalue="t" falsevalue="f" checked="false" label="Trim all non-overlapping portions, leaving only consensus sequence. By default, only sequence to the right of the overlap (adapter sequence) is trimmed."/> 126 <param argument="trimnonoverlapping" type="boolean" truevalue="t" falsevalue="f" checked="false" label="Trim all non-overlapping portions, leaving only consensus sequence. By default, only sequence to the right of the overlap (adapter sequence) is trimmed."/>
128 <param argument="mininsert" type="integer" value="35" label="Minimum insert size to merge reads"/> 127 <param argument="mininsert" type="integer" value="35" label="Minimum insert size to merge reads"/>
129 <param argument="minoverlap" type="integer" value="12" label="Minimum number of overlapping bases to allow merging"/> 128 <param argument="minoverlap" type="integer" value="12" label="Minimum number of overlapping bases to allow merging"/>
130
131 <param argument="minq" type="integer" value="9" label="Ignore bases with quality below this"/> 129 <param argument="minq" type="integer" value="9" label="Ignore bases with quality below this"/>
132 <param argument="maxq" type="integer" value="41" label="Cap output quality scores at this"/> 130 <param argument="maxq" type="integer" value="41" label="Cap output quality scores at this"/>
133
134 <param argument="entropy" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Increase the minimum overlap requirement for low-complexity reads"/> 131 <param argument="entropy" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Increase the minimum overlap requirement for low-complexity reads"/>
135 <param argument="efilter" type="integer" value="6" label="Ban overlaps with over this many times the expected number of errors." help="Lower is more strict, -1 disables."/> 132 <param argument="efilter" type="integer" value="6" label="Ban overlaps with over this many times the expected number of errors." help="Lower is more strict, -1 disables."/>
136 <param argument="pfilter" type="float" value="0.00004" label="Probability filter to disallow improbable overlaps." help="Higher is stricter. 0 will disable the filter; 1 will allow only perfect overlaps."/> 133 <param argument="pfilter" type="float" value="0.00004" label="Probability filter to disallow improbable overlaps." help="Higher is stricter. 0 will disable the filter; 1 will allow only perfect overlaps."/>
137 <param argument="kfilter" type="integer" value="41" label="Ban overlaps that create kmers with count below this value" help="Requires good coverage, 0 disables."/> 134 <param argument="kfilter" type="integer" value="41" label="Ban overlaps that create kmers with count below this value" help="Requires good coverage, 0 disables."/>
138 <param argument="usequality" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Take quality factors into account" help="If disabled, quality values are completely ignored, both for overlap detection and filtering. May be useful for data with inaccurate quality values."/> 135 <param argument="usequality" type="boolean" truevalue="t" falsevalue="f" checked="true" label="Take quality factors into account" help="If disabled, quality values are completely ignored, both for overlap detection and filtering. May be useful for data with inaccurate quality values."/>
139
140 <conditional name="adapters"> 136 <conditional name="adapters">
141 <param name="selector" type="select" label="Provide adapter sequences to improve accuracy?"> 137 <param name="selector" type="select" label="Provide adapter sequences to improve accuracy?">
142 <option value="wout_adapters" selected="true">No</option> 138 <option value="wout_adapters" selected="true">No</option>
143 <option value="with_adapters">Yes, use these adapter sequences</option> 139 <option value="with_adapters">Yes, use these adapter sequences</option>
144 </param> 140 </param>
146 <when value="with_adapters"> 142 <when value="with_adapters">
147 <param argument="adapter1" type="text" value="" label="Left adapter sequence"/> 143 <param argument="adapter1" type="text" value="" label="Left adapter sequence"/>
148 <param argument="adapter2" type="text" value="" label="Right adapter sequence"/> 144 <param argument="adapter2" type="text" value="" label="Right adapter sequence"/>
149 </when> 145 </when>
150 </conditional> 146 </conditional>
151
152 <conditional name="merge_mode"> 147 <conditional name="merge_mode">
153 <param name="selector" type="select" label="Evaluate overlaps via..." help="In the ratio mode, overlaps are decided based on the ratio of matching to mismatching bases. Flat mode scores overlaps based on the total number of mismatching bases only."> 148 <param name="selector" type="select" label="Evaluate overlaps via..." help="In the ratio mode, overlaps are decided based on the ratio of matching to mismatching bases. Flat mode scores overlaps based on the total number of mismatching bases only.">
154 <option value="Ratio mode" selected="true">Ratio mode</option> 149 <option value="Ratio mode" selected="true">Ratio mode</option>
155 <option value="Flat mode">Flat mode</option> 150 <option value="Flat mode">Flat mode</option>
156 </param> 151 </param>
250 + 245 +
251 FFFFFFFFFFFFFFFFFFFFFFFFFFF,FFFFFF 246 FFFFFFFFFFFFFFFFFFFFFFFFFFF,FFFFFF
252 </help> 247 </help>
253 <expand macro="citations"/> 248 <expand macro="citations"/>
254 </tool> 249 </tool>
255