Mercurial > repos > iuc > mothur_get_lineage
comparison get.lineage.xml @ 0:f217eb7fad54 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/mothur commit a9d1e0debcd357d8080a1c6c5f1d206dd45a7a4d
author | iuc |
---|---|
date | Fri, 19 May 2017 05:04:46 -0400 |
parents | |
children | c5034189eb03 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:f217eb7fad54 |
---|---|
1 <tool profile="16.07" id="mothur_get_lineage" name="Get.lineage" version="@WRAPPER_VERSION@.0"> | |
2 <description>Picks by taxon</description> | |
3 <macros> | |
4 <import>macros.xml</import> | |
5 </macros> | |
6 <expand macro="requirements"/> | |
7 <expand macro="stdio"/> | |
8 <expand macro="version_command"/> | |
9 <command><![CDATA[ | |
10 @SHELL_OPTIONS@ | |
11 | |
12 #import re | |
13 ## create symlinks to input datasets | |
14 ln -s "$file.taxonomy" file.taxonomy.dat && | |
15 #if $file.filetype == "useconstaxonomy": | |
16 ln -s "$file.shared" file.shared.dat && | |
17 ln -s "$file.list" file.list.dat && | |
18 #end if | |
19 ln -s "$fasta_in" fasta_in.dat && | |
20 ln -s "$group_in" group_in.dat && | |
21 ln -s "$alignreport_in" alignreport_in.dat && | |
22 ln -s "$list_in" list_in.dat && | |
23 ln -s "$name_in" name_in.dat && | |
24 ln -s "$count" count.dat && | |
25 | |
26 echo 'get.lineage( | |
27 #if $file.filetype == "usetaxonomy": | |
28 taxonomy=file.taxonomy.dat | |
29 #else | |
30 constaxonomy=file.taxonomy.dat | |
31 #if $file.shared: | |
32 ,shared=file.shared.dat | |
33 #end if | |
34 #if $file.list: | |
35 ,list=file.list.dat | |
36 #end if | |
37 #end if | |
38 #if $file.taxons: | |
39 #set taxonstring=str($file.taxons).replace(",","-") | |
40 ,taxon='"'$re.sub("(\s|,)+",",",$re.sub("\(\d+\)","", $taxonstring ))'"' | |
41 #elif $taxon: | |
42 ,taxon='"'$re.sub("(\s|,)+",",",$re.sub("\(\d+\)","", $taxon.value )).replace(",","-")'"' | |
43 #end if | |
44 #if $fasta_in: | |
45 ,fasta=fasta_in.dat | |
46 #end if | |
47 #if $group_in: | |
48 ,group=group_in.dat | |
49 #end if | |
50 #if $alignreport_in: | |
51 ,alignreport=alignreport_in.dat | |
52 #end if | |
53 #if $list_in: | |
54 ,list=list_in.dat | |
55 #end if | |
56 #if $name_in: | |
57 ,name=name_in.dat | |
58 ,dups=$dups | |
59 #end if | |
60 #if $count: | |
61 ,count=count.dat | |
62 #end if | |
63 )' | |
64 | sed 's/ //g' ## mothur trips over whitespace | |
65 | mothur | |
66 | tee mothur.out.log | |
67 ]]></command> | |
68 <inputs> | |
69 <conditional name="file"> | |
70 <param name="filetype" type="select" label="choose which file is used"> | |
71 <option value="usetaxonomy" selected="true">taxonomy</option> | |
72 <option value="useconstaxonomy">constaxonomy</option> | |
73 </param> | |
74 <when value="usetaxonomy"> | |
75 <param name="taxonomy" type="data" format="mothur.seq.taxonomy" label="taxonomy - Taxonomy" help="please make sure your file has no quotation marks in it"/> | |
76 <param name="taxons" type="select" size="120" optional="true" multiple="true" label="Browse Taxons from Taxonomy"> | |
77 <options from_dataset="taxonomy"> | |
78 <column name="name" index="1"/> | |
79 <column name="value" index="1"/> | |
80 <filter type="unique_value" name="unique_taxon" column="1"/> | |
81 <filter type="sort_by" name="sorted_taxon" column="1"/> | |
82 </options> | |
83 <sanitizer> | |
84 <valid initial="default"> | |
85 <add preset="string.printable"/> | |
86 <add value=";"/> | |
87 <remove value="""/> | |
88 <remove value="'"/> | |
89 </valid> | |
90 </sanitizer> | |
91 </param> | |
92 </when> | |
93 <when value="useconstaxonomy"> | |
94 <param name="taxonomy" type="data" format="mothur.cons.taxonomy" label="constaxonomy - Constaxonomy file. Provide either a constaxonomy file or a taxonomy file" help="please make sure your file has no quotation marks in it"/> | |
95 <param name="taxons" type="select" size="120" optional="true" multiple="true" label="Browse Taxons from Taxonomy"> | |
96 <options from_dataset="taxonomy"> | |
97 <column name="name" index="2"/> | |
98 <column name="value" index="2"/> | |
99 <filter type="unique_value" name="unique_taxon" column="2"/> | |
100 <filter type="sort_by" name="sorted_taxon" column="2"/> | |
101 </options> | |
102 <sanitizer> | |
103 <valid initial="default"> | |
104 <add preset="string.printable"/> | |
105 <add value=";"/> | |
106 <remove value="""/> | |
107 <remove value="'"/> | |
108 </valid> | |
109 </sanitizer> | |
110 </param> | |
111 <param name="shared" type="data" format="mothur.shared" optional="true" label="shared - shared file"/> | |
112 <param name="list" type="data" format="mothur.list" optional="true" label="list - list file"/> | |
113 </when> | |
114 </conditional> | |
115 <param name="taxon" type="text" area="True" size="5x120" label="taxon - Manually select Taxons for filtering" help="If no taxons selected from file, Enter 1 or more taxons separated by dashes here, e.g. Bacteria;Firmicutes;-Bacteria;Actinobacteria; "/> | |
116 <param name="fasta_in" type="data" format="fasta" optional="true" label="fasta - Fasta Sequences"/> | |
117 <param name="group_in" type="data" format="mothur.groups" optional="true" label="group - Groups"/> | |
118 <param name="alignreport_in" type="data" format="mothur.align.report" optional="true" label="alignreport - Align Report"/> | |
119 <param name="list_in" type="data" format="mothur.list" optional="true" label="list - OTU List"/> | |
120 <param name="name_in" type="data" format="mothur.names" optional="true" label="name - Sequences Name reference"/> | |
121 <param name="dups" type="boolean" truevalue="true" falsevalue="false" checked="true" label="dups - Apply to duplicate names"/> | |
122 <param name="count" type="data" format="mothur.count_table" optional="true" help="The count file is similar to the name file in that it is used to represent the number of duplicate sequences for a given representative sequence. It can also contain group information"/> | |
123 </inputs> | |
124 <outputs> | |
125 <expand macro="logfile-output"/> | |
126 <data name="taxonomy_out" format="mothur.seq.taxonomy" from_work_dir="file.taxonomy*.pick.*" label="${tool.name} on ${on_string}: pick.taxonomy"/> | |
127 <data name="fasta_out" format_source="fasta_in" from_work_dir="fasta_in*.pick.*" label="${tool.name} on ${on_string}: pick.fasta"> | |
128 <filter>fasta_in</filter> | |
129 </data> | |
130 <data name="group_out" format="mothur.groups" from_work_dir="group_in*.pick.*" label="${tool.name} on ${on_string}: pick.group"> | |
131 <filter>group_in</filter> | |
132 </data> | |
133 <collection name="list_out" type="list" label="${tool.name} on ${on_string}: pick.list"> | |
134 <filter>list_in</filter> | |
135 <discover_datasets pattern="list_in*?\.(?P<designation>.*)\.pick.*" format="mothur.list"/> | |
136 </collection> | |
137 <data name="name_out" format="mothur.names" from_work_dir="name_in*.pick.*" label="${tool.name} on ${on_string}: pick.name"> | |
138 <filter>name_in</filter> | |
139 </data> | |
140 <data name="alignreport_out" format="mothur.align.report" from_work_dir="alignreport_in*.pick.*" label="${tool.name} on ${on_string}: pick.align.report"> | |
141 <filter>alignreport_in</filter> | |
142 </data> | |
143 </outputs> | |
144 <tests> | |
145 <test><!-- test with defaults and single taxon --> | |
146 <param name="filetype" value="usetaxonomy"/> | |
147 <param name="taxonomy" value="abrecovery.pds.wang.taxonomy" ftype="mothur.seq.taxonomy"/> | |
148 <param name="taxon" value="Bacteria;Firmicutes;"/> | |
149 <output name="taxonomy_out" md5="aca21af84b6bbb6ab6cd7ab8643943d2"/> | |
150 </test> | |
151 <test><!-- test with multiple taxons and all additional files --> | |
152 <param name="filetype" value="usetaxonomy"/> | |
153 <param name="taxonomy" value="abrecovery.pds.wang.taxonomy" ftype="mothur.seq.taxonomy"/> | |
154 <param name="taxon" value="Bacteria;Firmicutes;,Bacteria;Actinobacteria;"/> | |
155 <param name="group_in" value="abrecovery.groups" ftype="mothur.groups"/> | |
156 <param name="fasta_in" value="abrecovery.fasta" ftype="fasta"/> | |
157 <param name="name_in" value="abrecovery.names" ftype="mothur.names"/> | |
158 <param name="alignreport_in" value="Mock_S280_L001_R1_001_small.contigs.report" ftype="mothur.align.report"/> | |
159 <param name="list_in" value="amazon.an.list" ftype="mothur.list"/> | |
160 <output name="taxonomy_out" md5="682af62c68e02244c1eb1c39fa295c63"/> | |
161 <output name="group_out" md5="71eff499c4f32ff53937288c7ffe0f70" ftype="mothur.groups"/> | |
162 <output name="fasta_out" md5="c7e5182680e48595999fbc3561c76cef" ftype="fasta"/> | |
163 <output name="name_out" md5="424256fee5f9074465eed432c1a8fb10" ftype="mothur.names"/> | |
164 <output name="alignreport_out" md5="2a579d34a3794f8ce1934147e9ea78ef" ftype="mothur.align.report"/> | |
165 <output_collection name="list_out" count="36"> | |
166 <element name="0.05" md5="d41d8cd98f00b204e9800998ecf8427e" ftype="mothur.list"/> | |
167 </output_collection> | |
168 </test> | |
169 <test><!-- test with taxons from file --> | |
170 <param name="filetype" value="usetaxonomy"/> | |
171 <param name="taxonomy" value="abrecovery.pds.wang.taxonomy" ftype="mothur.seq.taxonomy"/> | |
172 <param name="taxons" value="Bacteria(100);Firmicutes(100);Clostridia(100);Clostridiales(100);Lachnospiraceae(100);Dorea(99);,Bacteria(100);Firmicutes(100);Clostridia(100);Clostridiales(100);Lachnospiraceae(100);Roseburia(47);"/> | |
173 <output name="taxonomy_out" md5="f4067366d8ebdf56b75b1ac7a638bcb6"/> | |
174 </test> | |
175 <test><!-- test with constaxonomy file --> | |
176 <param name="filetype" value="useconstaxonomy"/> | |
177 <param name="taxonomy" value="example.constaxonomy" ftype="mothur.cons.taxonomy"/> | |
178 <param name="taxon" value="Bacteria;Bacteroidetes;"/> | |
179 <output name="taxonomy_out" md5="3a70d3cc47df38f9493a8c9cf02b75b7"/> | |
180 </test> | |
181 <test><!-- test with constaxonomy file and taxons from file --> | |
182 <param name="filetype" value="useconstaxonomy"/> | |
183 <param name="taxonomy" value="example.constaxonomy" ftype="mothur.cons.taxonomy"/> | |
184 <param name="taxons" value="Bacteria(100);Firmicutes(100);Clostridia(70);Clostridiales(70);Lachnospiraceae(51);unclassified;,Bacteria(100);Proteobacteria(100);Gammaproteobacteria(100);unclassified;unclassified;unclassified;"/> | |
185 <output name="taxonomy_out" md5="0ea2511f40073a95c0812268da0cf727"/> | |
186 </test> | |
187 </tests> | |
188 <help> | |
189 <![CDATA[ | |
190 | |
191 @MOTHUR_OVERVIEW@ | |
192 | |
193 **Command Documentation** | |
194 | |
195 The get.lineage_ command reads a taxonomy_ file and a taxon and generates a new file that contains only the sequences in the that are from that taxon. You may also include either a fasta, name_, group_, list_, or align.report_ file to this command and mothur will generate new files for each of those containing only the selected sequences. | |
196 | |
197 .. _taxonomy: https://www.mothur.org/wiki/Taxonomy_outline | |
198 .. _name: https://www.mothur.org/wiki/Name_file | |
199 .. _group: https://www.mothur.org/wiki/Group_file | |
200 .. _list: https://www.mothur.org/wiki/List_file | |
201 .. _align.report: https://www.mothur.org/wiki/Align.seqs | |
202 .. _get.lineage: https://www.mothur.org/wiki/Get.lineage | |
203 | |
204 ]]> | |
205 </help> | |
206 <expand macro="citations"/> | |
207 </tool> |