Mercurial > repos > devteam > kraken
changeset 6:2fdac3e78553 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/blob/master/tool_collections/kraken/kraken/ commit e8fc7c9dad5f583ad6763ecb9bd8c924832abacd
author | iuc |
---|---|
date | Mon, 07 Aug 2017 17:29:06 -0400 |
parents | b2392a9dfb01 |
children | 658d47fd33e3 |
files | kraken.xml macros.xml tool_dependencies.xml |
diffstat | 3 files changed, 63 insertions(+), 87 deletions(-) [+] |
line wrap: on
line diff
--- a/kraken.xml Wed Mar 23 10:55:18 2016 -0400 +++ b/kraken.xml Mon Aug 07 17:29:06 2017 -0400 @@ -1,5 +1,5 @@ <?xml version="1.0"?> -<tool id="kraken" name="Kraken" version="1.2.1"> +<tool id="kraken" name="Kraken" version="@WRAPPER_VERSION@"> <description> assign taxonomic labels to sequencing reads </description> @@ -7,56 +7,56 @@ <import>macros.xml</import> </macros> <expand macro="requirements" /> - <expand macro="stdio" /> <expand macro="version_command" /> - <command> + <command detect_errors="exit_code"> <![CDATA[ @SET_DATABASE_PATH@ && - kraken --threads \${GALAXY_SLOTS:-1} @INPUT_DATABASE@ - - ${only_classified_output} + + kraken + --threads \${GALAXY_SLOTS:-1} + @INPUT_DATABASE@ + ${only_classified_output} - #if str( $quick_operation.quick ) == "yes": - --quick - --min-hits ${quick_operation.min_hits} + #if str( $quick_operation.quick ) == "yes": + --quick + --min-hits ${quick_operation.min_hits} - #end if + #end if - #if $single_paired.single_paired_selector == "yes": - #if $forward_input.is_of_type( 'fastq' ): - --fastq-input - #else: - --fasta-input - #end if - "$forward_input" "$reverse_input" - ${single_paired.check_names} - #elif $single_paired.single_paired_selector == "collection": - #if $single_paired.input_pair.forward.is_of_type( 'fastq' ): - --fastq-input + #if $single_paired.single_paired_selector == 'yes' + #if $forward_input.is_of_type( 'fastq' ): + --fastq-input + #else: + --fasta-input + #end if + '${single_paired.forward_input}' '${single_paired.reverse_input}' + ${single_paired.check_names} + #elif $single_paired.single_paired_selector == "collection": + #if $single_paired.input_pair.forward.is_of_type( 'fastq' ): + --fastq-input + #else: + --fasta-input + #end if + "${single_paired.input_pair.forward}" "${single_paired.input_pair.reverse}" + ${single_paired.check_names} #else: - --fasta-input - #end if - "${single_paired.input_pair.forward}" "${single_paired.input_pair.reverse}" - ${single_paired.check_names} - #else: - #if $input_sequences.is_of_type( 'fastq' ): - --fastq-input - #else: - --fasta-input + #if $single_paired.input_sequences.is_of_type('fastq') + --fastq-input + #else: + --fasta-input + #end if + '${single_paired.input_sequences}' #end if - "$input_sequences" - #end if - #if $split_reads: - --classified-out "${classified_out}" --unclassified-out "${unclassified_out}" - #end if + #if $split_reads: + --classified-out "${classified_out}" --unclassified-out "${unclassified_out}" + #end if - ## The --output option was changed to redirect as it does not work properly is some situations. For example, on test database the tool classifies 4 reads but does not write them into a file if --output is specified. It does however print correct output into STDOUT. This behavior can be re-created with test database provided in test-data/test_db/ folder. This is the reason for incrementing version number from 1.1.2 to 1.1.3 + ## The --output option was changed to redirect as it does not work properly is some situations. For example, on test database the tool classifies 4 reads but does not write them into a file if --output is specified. It does however print correct output into STDOUT. This behavior can be re-created with test database provided in test-data/test_db/ folder. This is the reason for incrementing version number from 1.1.2 to 1.1.3 - > "${output}" - ##kraken-translate --db ${kraken_database.fields.name} "${output}" > "${translated}" - ]]> - </command> + > "${output}" + ##kraken-translate --db ${kraken_database.fields.name} "${output}" > "${translated}" + ]]></command> <inputs> <conditional name="single_paired"> <param name="single_paired_selector" type="select" label="Single or paired reads" help="--paired"> @@ -65,12 +65,12 @@ <option selected="True" value="no">Single</option> </param> <when value="collection"> - <param format="fasta,fastq" label="Collection of paired reads" name="input_pair" type="data_collection" collection_type="paired" help="FASTA or FASTQ datasets" /> - <param name="check_names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match" help="--check-names" /> + <param format="fasta,fastq" name="input_pair" type="data_collection" collection_type="paired" label="Collection of paired reads" help="FASTA or FASTQ datasets" /> + <param name="check_names" argument="--check-names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match"/> </when> <when value="yes"> - <param format="fasta,fastq" label="Forward strand" name="forward_input" type="data" help="FASTA or FASTQ dataset"/> - <param format="fasta,fastq" label="Reverse strand" name="reverse_input" type="data" help="FASTA or FASTQ dataset"/> + <param format="fasta,fastq" name="forward_input" type="data" label="Forward strand" help="FASTA or FASTQ dataset"/> + <param format="fasta,fastq" name="reverse_input" type="data" label="Reverse strand" help="FASTA or FASTQ dataset"/> <param name="check_names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match" help="--check-names" /> </when> <when value="no"> @@ -78,33 +78,34 @@ </when> </conditional> - <param label="Output classified and unclassified reads?" name="split_reads" type="boolean" help="Sets --unclassified-out and --classified-out"/> - + <param name="split_reads" type="boolean" label="Output classified and unclassified reads?" help="Sets --unclassified-out and --classified-out"/> + <conditional name="quick_operation"> - <param name="quick" type="select" label="Enable quick operation?" help="--quick; Rather than searching all k-mers in a sequence, stop classification after a specified number of database hit"> + <param argument="--quick" type="select" label="Enable quick operation" + help="Quick mode: rather than searching all k-mers in a sequence, stop classification after a specified number of database hit"> <option value="yes">Yes</option> <option selected="True" value="no">No</option> </param> <when value="yes"> - <param name="min_hits" type="integer" value="1" label="Number of hits required for classification" help="--min-hits; min-hits will allow you to require multiple hits before declaring a sequence classified, which can be especially useful with custom databases when testing to see if sequences either do or do not belong to a particular genome; default=1"/> + <param name="min_hits" argument="--min-hits" type="integer" value="1" label="Number of hits required for classification" + help="min-hits will allow you to require multiple hits before declaring a sequence classified, which can be especially useful with custom databases when testing to see if sequences either do or do not belong to a particular genome; default=1"/> </when> - <when value="no"> - <!-- Do absolutely nothing --> - </when> + <when value="no"/><!-- Do absolutely nothing --> </conditional> - <param name="only_classified_output" type="boolean" checked="False" truevalue="--only-classified-output" falsevalue="" label="Print no Kraken output for unclassified sequences" help="--only-classified-output"/> + <param name="only_classified_output" argument="--only-classified-output" type="boolean" checked="False" truevalue="--only-classified-output" falsevalue="" + label="Print no Kraken output for unclassified sequences"/> <expand macro="input_database" /> </inputs> <outputs> - <data format_source="input_sequences" label="${tool.name} on ${on_string}: Classified reads" name="classified_out"> + <data name="classified_out" format_source="input_sequences" label="${tool.name} on ${on_string}: Classified reads"> <filter>(split_reads)</filter> </data> - <data format_source="input_sequences" label="${tool.name} on ${on_string}: Unclassified reads" name="unclassified_out"> + <data name="unclassified_out" format_source="input_sequences" label="${tool.name} on ${on_string}: Unclassified reads"> <filter>(split_reads)</filter> </data> - <data format="tabular" label="${tool.name} on ${on_string}: Classification" name="output" /> + <data name="output" format="tabular" label="${tool.name} on ${on_string}: Classification"/> <!--<data format="tabular" label="${tool.name} on ${on_string}: Translated classification" name="translated" />--> </outputs> @@ -116,6 +117,7 @@ <param name="quick" value="no"/> <param name="only-classified-output" value="false"/> <param name="kraken_database" value="test_db"/> + <output name="output" file="kraken_test1_output.tab" ftype="tabular"/> </test> </tests> @@ -127,23 +129,6 @@ ----- -**Kraken options** - -The Galaxy version of Kraken implements the following options:: - - - --fasta-input Input is FASTA format - --fastq-input Input is FASTQ format - --quick Quick operation (use first hit or hits) - --min-hits NUM In quick op., number of hits req'd for classification - NOTE: this is ignored if --quick is not specified - --unclassified-out Print unclassified sequences to filename - --classified-out Print classified sequences to filename - - --only-classified-output Print no Kraken output for unclassified sequences - ------- - **Output Format** Each sequence classified by Kraken results in a single line of output. Output lines contain five tab-delimited fields; from left to right, they are::
--- a/macros.xml Wed Mar 23 10:55:18 2016 -0400 +++ b/macros.xml Mon Aug 07 17:29:06 2017 -0400 @@ -1,23 +1,20 @@ <?xml version="1.0"?> <macros> + <token name="@WRAPPER_VERSION@">1.2.3</token> <xml name="requirements"> <requirements> <requirement type="package" version="0.10.6_eaf8fb68">kraken</requirement> - <requirement type="package" version="0.10.6-eaf8fb68">kraken</requirement> </requirements> </xml> - <xml name="stdio"> - <stdio> - <exit_code description="Tool exception" level="fatal" range="1:" /> - </stdio> - </xml> <xml name="version_command"> - <version_command>export LC_ALL=C && kraken --version</version_command> + <version_command><![CDATA[ + export LC_ALL=C && kraken --version + ]]></version_command> </xml> <xml name="input_database"> <param label="Select a Kraken database" name="kraken_database" type="select"> <options from_data_table="kraken_databases"> - <validator message="No databases are available built-in" type="no_options" /> + <validator message="No Kraken database is available" type="no_options" /> </options> </param> </xml> @@ -28,4 +25,4 @@ </xml> <token name="@INPUT_DATABASE@">--db ${kraken_database.fields.name}</token> <token name="@SET_DATABASE_PATH@">export KRAKEN_DB_PATH="${kraken_database.fields.path}"</token> -</macros> \ No newline at end of file +</macros>
--- a/tool_dependencies.xml Wed Mar 23 10:55:18 2016 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,6 +0,0 @@ -<?xml version="1.0"?> -<tool_dependency> - <package name="kraken" version="0.10.6-eaf8fb68"> - <repository changeset_revision="0743afe4dcb8" name="package_kraken_0_10_6_eaf8fb68" owner="iuc" toolshed="https://toolshed.g2.bx.psu.edu" /> - </package> -</tool_dependency>