Mercurial > repos > iuc > purge_dups
diff purge_dups.xml @ 2:17b378303f2d draft
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/purge_dups commit 3199d3f9c401663ffe45a679c3918489d4f6d149"
author | iuc |
---|---|
date | Tue, 27 Apr 2021 20:48:51 +0000 |
parents | 29151e779524 |
children | 76d4cbefff85 |
line wrap: on
line diff
--- a/purge_dups.xml Tue Mar 09 18:25:07 2021 +0000 +++ b/purge_dups.xml Tue Apr 27 20:48:51 2021 +0000 @@ -2,16 +2,20 @@ <description>and haplotigs in an assembly based on read depth (purge_dups)</description> <macros> <token name="@TOOL_VERSION@">1.2.5</token> - <token name="@VERSION_SUFFIX@">1</token> + <token name="@VERSION_SUFFIX@">2</token> </macros> <requirements> <requirement type="package" version="@TOOL_VERSION@">purge_dups</requirement> </requirements> <command detect_errors="exit_code"><![CDATA[ #if $function_select.functions == "purge_dups": - #if $function_select.input.is_of_type("paf"): - gzip -c '$function_select.input' > ./input.paf.gz && - #end if + #for $i, $file in enumerate($function_select.input): + #if $file.is_of_type("paf"): + gzip -c '${file}' > '${i}.gz' && + #else + ln -s '${file}' '${i}.gz' && + #end if + #end for purge_dups #if $function_select.coverage: -c '$function_select.coverage' @@ -46,11 +50,10 @@ #if $function_select.max_extend: -E $function_select.max_extend #end if - #if $function_select.input.is_of_type("paf"): - 'input.paf.gz' > dups.bed 2> purge_dups.log - #else: - '${function_select.input}' > dups.bed 2> purge_dups.log - #end if + #for $i, $file in enumerate($function_select.input): + '${i}.gz' + #end for + > dups.bed 2> purge_dups.log #else if $function_select.functions == "split_fa": split_fa #if $function_select.split: @@ -58,9 +61,13 @@ #end if '$function_select.input' > split.fasta #else if $function_select.functions == "pbcstat": - #if $function_select.input.is_of_type("paf"): - gzip -c '$function_select.input' > ./input.paf.gz && - #end if + #for $i, $file in enumerate($function_select.input): + #if $file.is_of_type("paf"): + gzip -c '${file}' > '${i}.gz' && + #else + ln -s '${file}' '${i}.gz' && + #end if + #end for pbcstat #if $function_select.max_cov: -M $function_select.max_cov @@ -75,11 +82,9 @@ -l $function_select.flank #end if $function_select.primary_alignments - #if $function_select.input.is_of_type("paf"): - 'input.paf.gz' - #else: - '${function_select.input}' - #end if + #for $i, $file in enumerate($function_select.input): + '${i}.gz' + #end for #else if $function_select.functions == "ngscstat": ngscstat #if $function_select.min_align_qual: @@ -137,7 +142,7 @@ <option value="get_seqs">obtain seqeuences after purging</option> </param> <when value="purge_dups"> - <param name="input" type="data" format="paf,paf.gz" label="PAF input file"/> + <param name="input" type="data" format="paf,paf.gz" multiple="true" label="PAF input file"/> <param name="coverage" type="data" format="tabular" optional="true" argument="-c" label="Base-level coverage file" /> <param name="cutoffs" type="data" format="tabular" label ="Cutoffs file" optional="true" argument="-T"/> <param name="min_bad" type="float" min="0" max="1" argument="-f" optional="true" label="Minimum fraction of haploid/diploid/bad/repetitive bases in a sequence" help="Default = 0.8"/> @@ -163,7 +168,7 @@ <param name="split" type="boolean" truevalue="-n" falsevalue="" checked="false" label="Base-level coverage file" /> </when> <when value="pbcstat"> - <param name="input" type="data" format="paf,paf.gz" label="PAF input file"/> + <param name="input" type="data" format="paf,paf.gz" multiple="true" label="PAF input file"/> <param name="max_cov" type="integer" label="Maximum coverage" argument="-M" optional="true"/> <param name="min_map_ratio" argument="-f" type="float" min="0" max="1" value="0" label="Minimum mapping length ratio"/> <param name="min_map_qual" type="integer" argument="-q" optional="true" label="Minimum mapping quality"/> @@ -288,6 +293,14 @@ </conditional> <output name="purge_dups_bed" value="purge_dups_out.bed"/> </test> + <!-- Purge dups multiple input --> + <test expect_num_outputs="2"> + <conditional name="function_select"> + <param name="functions" value="purge_dups"/> + <param name="input" value="test.paf,test2.paf.gz"/> + </conditional> + <output name="purge_dups_bed" value="purge_dups_out_2.bed"/> + </test> <!-- Split fa --> <test expect_num_outputs="1"> <conditional name="function_select"> @@ -325,6 +338,15 @@ <output name="pbcstat_cov" value="out.cov"/> <output name="pbcstat_wig" value="out.wig"/> </test> + <!-- Pbcstat multiple input --> + <test expect_num_outputs="3"> + <conditional name="function_select"> + <param name="functions" value="pbcstat"/> + <param name="input" value="test.paf,test2.paf.gz"/> + </conditional> + <output name="pbcstat_cov" value="out2.cov"/> + <output name="pbcstat_wig" value="out2.wig"/> + </test> <!-- ngscstat --> <test expect_num_outputs="2"> <conditional name="function_select">