comparison kraken.xml @ 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
comparison
equal deleted inserted replaced
5:b2392a9dfb01 6:2fdac3e78553
1 <?xml version="1.0"?> 1 <?xml version="1.0"?>
2 <tool id="kraken" name="Kraken" version="1.2.1"> 2 <tool id="kraken" name="Kraken" version="@WRAPPER_VERSION@">
3 <description> 3 <description>
4 assign taxonomic labels to sequencing reads 4 assign taxonomic labels to sequencing reads
5 </description> 5 </description>
6 <macros> 6 <macros>
7 <import>macros.xml</import> 7 <import>macros.xml</import>
8 </macros> 8 </macros>
9 <expand macro="requirements" /> 9 <expand macro="requirements" />
10 <expand macro="stdio" />
11 <expand macro="version_command" /> 10 <expand macro="version_command" />
12 <command> 11 <command detect_errors="exit_code">
13 <![CDATA[ 12 <![CDATA[
14 @SET_DATABASE_PATH@ && 13 @SET_DATABASE_PATH@ &&
15 kraken --threads \${GALAXY_SLOTS:-1} @INPUT_DATABASE@
16
17 ${only_classified_output}
18 14
19 #if str( $quick_operation.quick ) == "yes": 15 kraken
20 --quick 16 --threads \${GALAXY_SLOTS:-1}
21 --min-hits ${quick_operation.min_hits} 17 @INPUT_DATABASE@
18 ${only_classified_output}
22 19
23 #end if 20 #if str( $quick_operation.quick ) == "yes":
21 --quick
22 --min-hits ${quick_operation.min_hits}
24 23
25 #if $single_paired.single_paired_selector == "yes": 24 #end if
26 #if $forward_input.is_of_type( 'fastq' ): 25
27 --fastq-input 26 #if $single_paired.single_paired_selector == 'yes'
27 #if $forward_input.is_of_type( 'fastq' ):
28 --fastq-input
29 #else:
30 --fasta-input
31 #end if
32 '${single_paired.forward_input}' '${single_paired.reverse_input}'
33 ${single_paired.check_names}
34 #elif $single_paired.single_paired_selector == "collection":
35 #if $single_paired.input_pair.forward.is_of_type( 'fastq' ):
36 --fastq-input
37 #else:
38 --fasta-input
39 #end if
40 "${single_paired.input_pair.forward}" "${single_paired.input_pair.reverse}"
41 ${single_paired.check_names}
28 #else: 42 #else:
29 --fasta-input 43 #if $single_paired.input_sequences.is_of_type('fastq')
44 --fastq-input
45 #else:
46 --fasta-input
47 #end if
48 '${single_paired.input_sequences}'
30 #end if 49 #end if
31 "$forward_input" "$reverse_input" 50
32 ${single_paired.check_names} 51 #if $split_reads:
33 #elif $single_paired.single_paired_selector == "collection": 52 --classified-out "${classified_out}" --unclassified-out "${unclassified_out}"
34 #if $single_paired.input_pair.forward.is_of_type( 'fastq' ):
35 --fastq-input
36 #else:
37 --fasta-input
38 #end if 53 #end if
39 "${single_paired.input_pair.forward}" "${single_paired.input_pair.reverse}"
40 ${single_paired.check_names}
41 #else:
42 #if $input_sequences.is_of_type( 'fastq' ):
43 --fastq-input
44 #else:
45 --fasta-input
46 #end if
47 "$input_sequences"
48 #end if
49 54
50 #if $split_reads: 55 ## 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
51 --classified-out "${classified_out}" --unclassified-out "${unclassified_out}"
52 #end if
53 56
54 ## 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 57 > "${output}"
55 58 ##kraken-translate --db ${kraken_database.fields.name} "${output}" > "${translated}"
56 > "${output}" 59 ]]></command>
57 ##kraken-translate --db ${kraken_database.fields.name} "${output}" > "${translated}"
58 ]]>
59 </command>
60 <inputs> 60 <inputs>
61 <conditional name="single_paired"> 61 <conditional name="single_paired">
62 <param name="single_paired_selector" type="select" label="Single or paired reads" help="--paired"> 62 <param name="single_paired_selector" type="select" label="Single or paired reads" help="--paired">
63 <option value="collection">Collection</option> 63 <option value="collection">Collection</option>
64 <option value="yes">Paired</option> 64 <option value="yes">Paired</option>
65 <option selected="True" value="no">Single</option> 65 <option selected="True" value="no">Single</option>
66 </param> 66 </param>
67 <when value="collection"> 67 <when value="collection">
68 <param format="fasta,fastq" label="Collection of paired reads" name="input_pair" type="data_collection" collection_type="paired" help="FASTA or FASTQ datasets" /> 68 <param format="fasta,fastq" name="input_pair" type="data_collection" collection_type="paired" label="Collection of paired reads" help="FASTA or FASTQ datasets" />
69 <param name="check_names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match" help="--check-names" /> 69 <param name="check_names" argument="--check-names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match"/>
70 </when> 70 </when>
71 <when value="yes"> 71 <when value="yes">
72 <param format="fasta,fastq" label="Forward strand" name="forward_input" type="data" help="FASTA or FASTQ dataset"/> 72 <param format="fasta,fastq" name="forward_input" type="data" label="Forward strand" help="FASTA or FASTQ dataset"/>
73 <param format="fasta,fastq" label="Reverse strand" name="reverse_input" type="data" help="FASTA or FASTQ dataset"/> 73 <param format="fasta,fastq" name="reverse_input" type="data" label="Reverse strand" help="FASTA or FASTQ dataset"/>
74 <param name="check_names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match" help="--check-names" /> 74 <param name="check_names" type="boolean" checked="False" truevalue="--paired --check-names" falsevalue="--paired" label="Verify read names match" help="--check-names" />
75 </when> 75 </when>
76 <when value="no"> 76 <when value="no">
77 <param format="fasta,fastq" label="Input sequences" name="input_sequences" type="data" help="FASTA or FASTQ datasets"/> 77 <param format="fasta,fastq" label="Input sequences" name="input_sequences" type="data" help="FASTA or FASTQ datasets"/>
78 </when> 78 </when>
79 79
80 </conditional> 80 </conditional>
81 <param label="Output classified and unclassified reads?" name="split_reads" type="boolean" help="Sets --unclassified-out and --classified-out"/> 81 <param name="split_reads" type="boolean" label="Output classified and unclassified reads?" help="Sets --unclassified-out and --classified-out"/>
82 82
83 <conditional name="quick_operation"> 83 <conditional name="quick_operation">
84 <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"> 84 <param argument="--quick" type="select" label="Enable quick operation"
85 help="Quick mode: rather than searching all k-mers in a sequence, stop classification after a specified number of database hit">
85 <option value="yes">Yes</option> 86 <option value="yes">Yes</option>
86 <option selected="True" value="no">No</option> 87 <option selected="True" value="no">No</option>
87 </param> 88 </param>
88 <when value="yes"> 89 <when value="yes">
89 <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"/> 90 <param name="min_hits" argument="--min-hits" type="integer" value="1" label="Number of hits required for classification"
91 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"/>
90 </when> 92 </when>
91 <when value="no"> 93 <when value="no"/><!-- Do absolutely nothing -->
92 <!-- Do absolutely nothing -->
93 </when>
94 </conditional> 94 </conditional>
95 95
96 <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"/> 96 <param name="only_classified_output" argument="--only-classified-output" type="boolean" checked="False" truevalue="--only-classified-output" falsevalue=""
97 label="Print no Kraken output for unclassified sequences"/>
97 98
98 <expand macro="input_database" /> 99 <expand macro="input_database" />
99 </inputs> 100 </inputs>
100 <outputs> 101 <outputs>
101 <data format_source="input_sequences" label="${tool.name} on ${on_string}: Classified reads" name="classified_out"> 102 <data name="classified_out" format_source="input_sequences" label="${tool.name} on ${on_string}: Classified reads">
102 <filter>(split_reads)</filter> 103 <filter>(split_reads)</filter>
103 </data> 104 </data>
104 <data format_source="input_sequences" label="${tool.name} on ${on_string}: Unclassified reads" name="unclassified_out"> 105 <data name="unclassified_out" format_source="input_sequences" label="${tool.name} on ${on_string}: Unclassified reads">
105 <filter>(split_reads)</filter> 106 <filter>(split_reads)</filter>
106 </data> 107 </data>
107 <data format="tabular" label="${tool.name} on ${on_string}: Classification" name="output" /> 108 <data name="output" format="tabular" label="${tool.name} on ${on_string}: Classification"/>
108 <!--<data format="tabular" label="${tool.name} on ${on_string}: Translated classification" name="translated" />--> 109 <!--<data format="tabular" label="${tool.name} on ${on_string}: Translated classification" name="translated" />-->
109 </outputs> 110 </outputs>
110 111
111 <tests> 112 <tests>
112 <test> 113 <test>
114 <param name="input_sequences" value="kraken_test1.fa" ftype="fasta"/> 115 <param name="input_sequences" value="kraken_test1.fa" ftype="fasta"/>
115 <param name="split_reads" value="false"/> 116 <param name="split_reads" value="false"/>
116 <param name="quick" value="no"/> 117 <param name="quick" value="no"/>
117 <param name="only-classified-output" value="false"/> 118 <param name="only-classified-output" value="false"/>
118 <param name="kraken_database" value="test_db"/> 119 <param name="kraken_database" value="test_db"/>
120
119 <output name="output" file="kraken_test1_output.tab" ftype="tabular"/> 121 <output name="output" file="kraken_test1_output.tab" ftype="tabular"/>
120 </test> 122 </test>
121 </tests> 123 </tests>
122 <help> 124 <help>
123 <![CDATA[ 125 <![CDATA[
124 **What it does** 126 **What it does**
125 127
126 Kraken is a taxonomic sequence classifier that assigns taxonomic labels to short DNA reads. It does this by examining the k-mers within a read and querying a database with those k-mers. This database contains a mapping of every k-mer in Kraken's genomic library to the lowest common ancestor (LCA) in a taxonomic tree of all genomes that contain that k-mer. The set of LCA taxa that correspond to the k-mers in a read are then analyzed to create a single taxonomic label for the read; this label can be any of the nodes in the taxonomic tree. Kraken is designed to be rapid, sensitive, and highly precise. 128 Kraken is a taxonomic sequence classifier that assigns taxonomic labels to short DNA reads. It does this by examining the k-mers within a read and querying a database with those k-mers. This database contains a mapping of every k-mer in Kraken's genomic library to the lowest common ancestor (LCA) in a taxonomic tree of all genomes that contain that k-mer. The set of LCA taxa that correspond to the k-mers in a read are then analyzed to create a single taxonomic label for the read; this label can be any of the nodes in the taxonomic tree. Kraken is designed to be rapid, sensitive, and highly precise.
127 129
128 ----- 130 -----
129
130 **Kraken options**
131
132 The Galaxy version of Kraken implements the following options::
133
134
135 --fasta-input Input is FASTA format
136 --fastq-input Input is FASTQ format
137 --quick Quick operation (use first hit or hits)
138 --min-hits NUM In quick op., number of hits req'd for classification
139 NOTE: this is ignored if --quick is not specified
140 --unclassified-out Print unclassified sequences to filename
141 --classified-out Print classified sequences to filename
142
143 --only-classified-output Print no Kraken output for unclassified sequences
144
145 ------
146 131
147 **Output Format** 132 **Output Format**
148 133
149 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:: 134 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::
150 135