Mercurial > repos > iuc > sina
changeset 4:482052b30b78 draft
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/sina commit f670d67c5943709ec6bd406becd60954621e4585"
author | iuc |
---|---|
date | Fri, 02 Oct 2020 08:18:09 +0000 |
parents | 8afa8799d50f |
children | 56d7dc39eec8 |
files | sina.xml |
diffstat | 1 files changed, 131 insertions(+), 145 deletions(-) [+] |
line wrap: on
line diff
--- a/sina.xml Fri Oct 02 08:01:21 2020 +0000 +++ b/sina.xml Fri Oct 02 08:18:09 2020 +0000 @@ -1,100 +1,97 @@ -<tool id="sina" name="SINA" version="@TOOL_VERSION@+@WRAPPER_VERSION@" profile="18.01"> +<tool id="sina" name="SINA" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="18.01"> <description>reference based multiple sequence alignment</description> <macros> - <token name="@TOOL_VERSION@">1.6.1</token> - <token name="@WRAPPER_VERSION@">galaxy0</token> - <xml name="minidty"> - <param name="minidty" type="float" value="0.7" min="0.0" max="1.0" label="Exclude sequences sharing less than this value fractional identity with any of the alignment reference sequences from the output?" help="(--min-idty)"/> - </xml> + <token name="@TOOL_VERSION@">1.7.1</token> + <token name="@VERSION_SUFFIX@">0</token> </macros> <requirements> <requirement type="package" version="@TOOL_VERSION@">sina</requirement> </requirements> <version_command>sina --version</version_command> <command detect_errors="exit_code"><![CDATA[ - ## initialize - ## parse custom reference from fasta to arb file format - #if $db.select == 'custom' - #if $db.custom.ext == 'fasta' - sina -i '$db.custom' --prealigned -o 'reference.arb' && - #else - ln -s '$db.custom' 'reference.arb' && - #end if - #elif $db.select == 'local' - ln -s '$db.arb_databases.fields.path' 'reference.arb' && - #end if +## initialize +#if $db.select == 'custom' + ## parse custom reference from fasta to arb file format + #if $db.custom.ext == 'fasta' + sina -i '$db.custom' --prealigned -o 'reference.arb' && + #else + ln -s '$db.custom' 'reference.arb' && + #end if +#elif $db.select == 'local' + ln -s '$db.arb_databases.fields.path' 'reference.arb' && +#end if - ## run - sina - --in='$in' - --db='reference.arb' - -p \${GALAXY_SLOTS:-4} - --num-pts=\${GALAXY_SLOTS:-4} - #if $os.type == 'arb' - --outtype='arb' - --out='output.arb' - #elif $os.type == 'fasta' - --outtype='fasta' - --out='output.fasta' - --min-idty=$os.minidty - #elif $os.type == 'fasta_meta' - --outtype='fasta' - --out='output.fasta' - --min-idty=$os.minidty - --meta-fmt='csv' - #end if - #if $log == 'yes' - --log-file='$logfile' - #elif $log == 'yes_meta' - --log-file='$logfile' - --show-diff - #end if - ## Advanced alignment parameters - --overhang=$ap.overhang - --insertion=$ap.insertion - #if $ap.turn == 'yes' - -t - #elif $ap.turn == 'all' - -t all - #end if - ## Expert Alignment Parameters - --fs-min=$eap.fsmin - --fs-max=$eap.fsmax - --fs-msc=$eap.fsmsc - --fs-weight=$eap.fsweight - --fs-req=$eap.fsreq - --fs-req-full=$eap.fsreqfull - --fs-full-len=$eap.fsfulllen - --gene-start=$eap.genestart - --gene-end=$eap.geneend - --fs-cover-gene=$eap.fscovergene - --match-score=$eap.matchscore - --mismatch-score=$eap.mismatchscore - --pen-gap=$eap.pengap - --pen-gapext=$eap.pengapext - --fs-kmer-len=$eap.fskmerlen - --fs-kmer-mm=$eap.fskmermm - $eap.fskmernofast - $eap.fskmernorel - ## Advanced search and classification parameters - #if $asacp.activate == 'yes' - --search - --search-kmer-candidates=$asacp.searchkmercandidates - --lca-quorum=$asacp.lcaquorum - --search-kmer-len=$asacp.searchkmerlen - --search-kmer-mm=$asacp.searchkmermm - --search-max-result=$asacp.searchmaxresult - $asacp.searchnofast - $asacp.searchkmernorel - #end if - ## convert meta file to tabular - #if $os.type == 'fasta_meta' - && cat output.csv | sed 's/,/\t/g' > output.tsv - #end if +## run +sina +--in='$in' +--db='reference.arb' +--threads=\${GALAXY_SLOTS:-4} +--num-pts=\${GALAXY_SLOTS:-4} +--show-conf +## Output options +#if 'arb' in $oo.out + --out='output.arb' +#end if +#if 'fasta' in $oo.out + --out='output.fasta' + --min-idty=$oo.minidty +#end if +#if 'tsv' in $oo.out + --out='output.csv' ## parsed into tabular in postprocessing step +#end if +#if 'log' in $oo.out + --log-file='$logfile' + --show-diff + --show-dist +#end if +## Advanced alignment parameters +--overhang=$ap.overhang +--insertion=$ap.insertion +#if $ap.turn == 'yes' + -t +#elif $ap.turn == 'all' + -t all +#end if +## Expert alignment parameters +--fs-min=$eap.fsmin +--fs-max=$eap.fsmax +--fs-msc=$eap.fsmsc +--fs-weight=$eap.fsweight +--fs-req=$eap.fsreq +--fs-req-full=$eap.fsreqfull +--fs-full-len=$eap.fsfulllen +--gene-start=$eap.genestart +--gene-end=$eap.geneend +--fs-cover-gene=$eap.fscovergene +--match-score=$eap.matchscore +--mismatch-score=$eap.mismatchscore +--pen-gap=$eap.pengap +--pen-gapext=$eap.pengapext +--fs-kmer-len=$eap.fskmerlen +--fs-kmer-mm=$eap.fskmermm +$eap.fskmernofast +$eap.fskmernorel +## Advanced search and classification parameters +#if $asacp.activate == 'yes' + --search + --search-kmer-candidates=$asacp.searchkmercandidates + --lca-quorum=$asacp.lcaquorum + --search-kmer-len=$asacp.searchkmerlen + --search-kmer-mm=$asacp.searchkmermm + --search-max-result=$asacp.searchmaxresult + $asacp.searchnofast + $asacp.searchkmernorel +#end if + +## postprocessing +## convert csv to tabular +#if 'tsv' in $oo.out + && test -f 'output.csv' && cat 'output.csv' | sed 's/,/\t/g' > 'output.tsv' || echo 'No additional meta data file.' +#end if ]]></command> - <!-- Sections and default parameters are based on https://www.arb-silva.de/aligner --> <inputs> - <param argument="--in" type="data" format="fasta" label="Select sequence file" help="FASTA file format"/> + <!-- Included paramaters, sections and default values are based on https://www.arb-silva.de/aligner --> + <param argument="--in" type="data" format="fasta" label="Select sequence file"/> <conditional name="db"> <param name="select" type="select" label="Select reference library type"> <option value="custom" selected="true">Custom</option> @@ -127,25 +124,6 @@ <param name="searchmaxresult" type="integer" value="10" min="0" label="Set maximum number of search results to return for each query sequence" help="(--search-max-result)"/> </when> </conditional> - <conditional name="os"> - <param name="type" type="select" label="Select output file type" help="(--outtype)"> - <option value="fasta">FASTA</option> - <option value="fasta_meta">FASTA with meta-file</option> - <option value="arb">ARB</option> - </param> - <when value="fasta"> - <expand macro="minidty"/> - </when> - <when value="fasta_meta"> - <expand macro="minidty"/> - </when> - <when value="arb"/> - </conditional> - <param name="log" type="select" label="Create log file?" help="(--log-file, --show-diff)"> - <option value="no">no</option> - <option value="yes">yes</option> - <option value="yes_meta">yes with differences between the inferred alignment and the original alignment</option> - </param> <section name="ap" title="Alignment parameters"> <param argument="--overhang" type="select" label="Bases remaining unaligned at the ends should be"> <option value="attach">attached to the last aligned base</option> @@ -180,44 +158,52 @@ <param name="pengap" type="integer" value="5" min="0" label="Set penalty subtracted from the score for opening a gap" help="(--pen-gap)"/> <param name="pengapext" type="integer" value="2" min="0" label="Set penalty subtracted from the score for extending a gap" help="(--pen-gapext)"/> <param name="fskmerlen" type="integer" value="10" min="0" label="Set size of k for the reference search" help="For SSU rRNA sequences, the default of 10 is a good value. For different sequence types, different values may perform better. For 5S, for example, 6 has shown to be more effective. (--fs-kmer-len)"/> - <param name="fskmermm" type="integer" value="0" min="0" label="Set k-mer matches in the reference database to contain this number of mismatches" help=" (--fs-kmer-mm)"/> + <param name="fskmermm" type="integer" value="0" min="0" label="Set k-mer matches in the reference database to contain this number of mismatches" help="(--fs-kmer-mm)"/> <param name="fskmernofast" type="boolean" truevalue="--fs-kmer-no-fast" falsevalue="" label="Use all k-mers occurring in the query sequence in the search?" help="By default, only k-mers starting with an A are used for extra performance. (--fs-kmer-no-fast)"/> <param name="fskmernorel" type="boolean" truevalue="--fs-kmer-norel" falsevalue="" label="Use absolute match scores in the kmer search?" help="Absolute (number of shared k-mers) rather than relative (number or shared k-mers divided by length of reference sequence) (--fs-kmer-norel)"/> </section> + <section name="oo" title="Output options"> + <param name="out" type="select" multiple="true" optional="false" label="Select output file(s)"> + <option value="arb" selected="true">Alignment (ARB)</option> + <option value="fasta" selected="true">Alignment (FASTA)</option> + <option value="tsv">Additional meta data (Tabular)</option> + <option value="log">Log</option> + </param> + <param name="minidty" type="float" value="0.7" min="0.0" max="1.0" label="Exclude sequences sharing less than this value fractional identity with any of the alignment reference sequences from the output?" help="Only relevant for FASTA output. (--min-idty)"/> + </section> </inputs> <outputs> - <data name="output_fasta" format="fasta" from_work_dir="output.fasta" label="${tool.name} on ${on_string}: alignment"> - <filter>os['type'] == 'fasta' or os['type'] == 'fasta_meta'</filter> + <data name="out_fasta" format="fasta" from_work_dir="output.fasta" label="${tool.name} on ${on_string}: Alignment (FASTA)"> + <filter>'fasta' in oo['out']</filter> </data> - <data name="output_arb" format="data" from_work_dir="output.arb" label="${tool.name} on ${on_string}: alignment"> - <filter>os['type'] == 'arb'</filter> + <data name="out_arb" format="data" from_work_dir="output.arb" label="${tool.name} on ${on_string}: Alignment (ARB)"> + <filter>'arb' in oo['out']</filter> </data> - <data name="output_meta" format="csv" from_work_dir="output.tsv" label="${tool.name} on ${on_string}: meta information"> - <filter>os['type'] == 'fasta_meta'</filter> + <data name="out_tsv" format="tabular" from_work_dir="output.tsv" label="${tool.name} on ${on_string}: Additional meta data (Tabular)"> + <filter>'tsv' in oo['out']</filter> </data> - <data name="logfile" format="txt" label="${tool.name} on ${on_string}: log"> - <filter>log == 'yes' or log == 'yes_meta'</filter> + <data name="out_log" format="txt" label="${tool.name} on ${on_string}: Log"> + <filter>'log' in oo['out']</filter> </data> </outputs> <tests> - <!-- name pattern of outputfile: output_<in_filetype>_<db_filetype>.<os.type>" --> - <!-- #1 in: *.fasta; db: *.fasta; out: *.fasta; standard parameters --> + <!-- #1 in: *.fasta; db: *.fasta; out: *.fasta; default parameters --> <test> <param name="in" value="sequence.fasta"/> <conditional name="db"> <param name="custom" value="reference.fasta"/> </conditional> - <section name="os"> - <param name="type" value="fasta_meta"/> + <section name="oo"> + <param name="out" value="fasta,tsv"/> <param name="minidty" value="0.0"/> </section> - <output name="output_meta"> + <output name="out_tsv"> <assert_contents> <has_text text="FJ203641.1"/> <has_n_lines n="18"/> </assert_contents> </output> - <output name="output_fasta"> + <output name="out_fasta"> <assert_contents> <has_line line=">FJ203641.1"/> <has_line line=">WH051F03"/> @@ -225,38 +211,38 @@ </assert_contents> </output> </test> - <!-- #2 in: *.fasta; db: *.fasta; out: *.arb; standard parameters --> + <!-- #2 in: *.fasta; db: *.fasta; out: *.arb; default parameters --> <test> <param name="in" value="sequence.fasta"/> <conditional name="db"> <param name="custom" value="reference.fasta"/> </conditional> - <section name="os"> - <param name="type" value="arb"/> + <section name="oo"> + <param name="out" value="arb"/> </section> - <output name="output_arb"> + <output name="out_arb"> <assert_contents> - <has_size value="21369"/> + <has_size value="21106"/> </assert_contents> </output> </test> - <!-- #3 in: *.fasta; db: *.arb; out: *.fasta; standard parameters --> + <!-- #3 in: *.fasta; db: *.arb; out: *.fasta; default parameters --> <test> <param name="in" value="sequence.fasta"/> <conditional name="db"> <param name="custom" value="reference.arb"/> </conditional> - <section name="os"> - <param name="type" value="fasta_meta"/> + <section name="oo"> + <param name="out" value="fasta,tsv"/> <param name="minidty" value="0.0"/> </section> - <output name="output_meta"> + <output name="out_tsv"> <assert_contents> <has_text text="FJ203641.1"/> <has_n_lines n="18"/> </assert_contents> </output> - <output name="output_fasta"> + <output name="out_fasta"> <assert_contents> <has_line line=">FJ203641.1"/> <has_line line=">WH051F03"/> @@ -264,18 +250,18 @@ </assert_contents> </output> </test> - <!-- #4 in: *.fasta; db: *.arb; out: *.arb; standard parameters --> + <!-- #4 in: *.fasta; db: *.arb; out: *.arb; default parameters --> <test> <param name="in" value="sequence.fasta"/> <conditional name="db"> <param name="custom" value="reference.arb"/> </conditional> - <section name="os"> - <param name="type" value="arb"/> + <section name="oo"> + <param name="out" value="arb"/> </section> - <output name="output_arb"> + <output name="out_arb"> <assert_contents> - <has_size value="19999"/> + <has_size value="19736"/> </assert_contents> </output> </test> @@ -285,8 +271,8 @@ <conditional name="db"> <param name="custom" value="reference.arb"/> </conditional> - <section name="os"> - <param name="type" value="fasta"/> + <section name="oo"> + <param name="out" value="fasta"/> <param name="minidty" value="0.0"/> </section> <section name="ap"> @@ -323,7 +309,7 @@ <param name="searchkmernorel" value="--search-kmer-norel"/> <param name="searchmaxresult" value="10"/> </section> - <output name="output_fasta"> + <output name="out_fasta"> <assert_contents> <has_line line=">FJ203641.1"/> <has_line line=">WH051F03"/> @@ -331,19 +317,19 @@ </assert_contents> </output> </test> - <!-- #6 in: *.fasta; db: <arb_databases>.arb; out: *.fasta; standard parameters --> + <!-- #6 in: *.fasta; db: <arb_databases>.arb; out: *.fasta; default parameters --> <test> <param name="in" value="sequence.fasta"/> <conditional name="db"> <param name="select" value="local"/> <param name="arb_databases" value="testarb"/> </conditional> - <section name="os"> - <param name="type" value="arb"/> + <section name="oo"> + <param name="out" value="arb"/> </section> - <output name="output_arb"> + <output name="out_arb"> <assert_contents> - <has_size value="19999"/> + <has_size value="19736"/> </assert_contents> </output> </test> @@ -365,13 +351,13 @@ **Output** -Results are provided in FASTA or ARB file format, whereas additional metadata is provided as CSV. +Results are provided in FASTA or ARB file format, whereas additional metadata is provided as tabular text file. .. class:: infomark **References** -More information can be found on the `project website <https://sina.readthedocs.io/en/latest>`_, and on `github <https://github.com/epruesse/SINA>`_. An `online version <https://www.arb-silva.de/aligner>`_ of SINA is provided by the SILVA project. +More information can be found on the `project website <https://sina.readthedocs.io/en/latest>`_ and on `GitHub <https://github.com/epruesse/SINA>`_. An `online version <https://www.arb-silva.de/aligner>`_ of SINA is provided by the SILVA project. ]]></help> <citations> <citation type="doi">10.1093/bioinformatics/bts252</citation>