Mercurial > repos > iuc > samtools_view
diff macros.xml @ 3:097c44aaf6d4 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_view commit 640b53919bfc0ae4b895451218e919a52ac14b9d
| author | iuc |
|---|---|
| date | Tue, 20 Nov 2018 06:19:49 -0500 |
| parents | 80d8ca44f8da |
| children | 25ca025bc1c1 |
line wrap: on
line diff
--- a/macros.xml Thu Sep 27 08:49:45 2018 -0400 +++ b/macros.xml Tue Nov 20 06:19:49 2018 -0500 @@ -53,11 +53,11 @@ #if $addref_cond.addref_select == "history": ln -s '${addref_cond.ref}' reference.fa && samtools faidx reference.fa && - #set reffa=str($addref_cond.ref) + #set reffa="reference.fa" #set reffai="reference.fa.fai" #elif $addref_cond.addref_select == "cached": #set reffa=str($addref_cond.ref.fields.path) - #set reffai=str($addref_cond.ref.fields.path) + #set reffai=str($addref_cond.ref.fields.path)+".fai" #else #set reffa=None #set reffai=None @@ -67,7 +67,6 @@ ##compute the number of ADDITIONAL threads to be used by samtools (-@) addthreads=\${GALAXY_SLOTS:-1} && (( addthreads-- )) && ]]></token> - <token name="@ADDMEMORY@"><![CDATA[ ##compute the number of memory available to samtools sort (-m) ##use only 75% of available: https://github.com/samtools/samtools/issues/831 @@ -91,6 +90,42 @@ <option value="1024">read is a PCR or optical duplicate</option> <option value="2048">supplementary alignment</option> </xml> + + <!-- region specification macros and tokens for tools that allow the specification + of region by bed file / space separated list of regions --> + <token name="@REGIONS_FILE@"><![CDATA[ + #if $cond_region.select_region == 'tab': + -t '$cond_region.targetregions' + #end if + ]]></token> + <token name="@REGIONS_MANUAL@"><![CDATA[ + #if $cond_region.select_region == 'text': + #for $i, $x in enumerate($cond_region.regions_repeat): + '${x.region}' + #end for + #end if + ]]></token> + <xml name="regions_macro"> + <conditional name="cond_region"> + <param name="select_region" type="select" label="Filter by regions" help="restricts output to only those alignments which overlap the specified region(s)"> + <option value="no" selected="True">No</option> + <option value="text">Manualy specify regions</option> + <option value="tab">Regions from tabular file</option> + </param> + <when value="no"/> + <when value="text"> + <repeat name="regions_repeat" min="1" default="1" title="Regions"> + <param name="region" type="text" label="region" help="format chr:from-to"> + <validator type="regex" message="Required format: CHR[:FROM[-TO]]; where CHR: string containing any character except quotes, whitespace and colon; FROM and TO: any integer">^[^\s'\":]+(:\d+(-\d+){0,1}){0,1}$</validator> + </param> + </repeat> + </when> + <when value="tab"> + <param name="targetregions" argument="-t/--target-regions" type="data" format="tabular" label="Target regions file" help="Do stats in these regions only. Tab-delimited file chr,from,to (1-based, inclusive)" /> + </when> + </conditional> + </xml> + <xml name="citations"> <citations> <citation type="bibtex">
