Mercurial > repos > iuc > mothur_remove_seqs
comparison remove.seqs.xml @ 2:0b8ca0026f28 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/mothur commit 3418f23b9768f5aafb86488f5ec1cb97530d4fb3
author | iuc |
---|---|
date | Tue, 20 Mar 2018 22:12:08 -0400 |
parents | e59ddb750b65 |
children | d38f2ac5db71 |
comparison
equal
deleted
inserted
replaced
1:008f62670efc | 2:0b8ca0026f28 |
---|---|
5 </macros> | 5 </macros> |
6 <expand macro="requirements"/> | 6 <expand macro="requirements"/> |
7 <expand macro="stdio"/> | 7 <expand macro="stdio"/> |
8 <expand macro="version_command"/> | 8 <expand macro="version_command"/> |
9 <command><![CDATA[ | 9 <command><![CDATA[ |
10 @SHELL_OPTIONS@ | 10 @SHELL_OPTIONS@ |
11 | 11 |
12 ## if accnos file is empty, just output files as-is, mothur errors if accnos empty (e.g. chimera filtering in pipeline but sample had no chimeras) | 12 ## if accnos file is empty, just output files as-is, mothur errors if accnos empty (e.g. chimera filtering in pipeline but sample had no chimeras) |
13 #import os | 13 #import os |
14 #if $os.lstat(str($accnos)).st_size == 0: | 14 #if $os.lstat(str($accnos)).st_size == 0: |
15 echo "accnos file empty, nothing to remove, skipping step" | 15 echo "accnos file empty, nothing to remove, skipping step" |
16 #if $fasta_in: | 16 #if $fasta_in: |
17 && cp $fasta_in $fasta_out | 17 && cp $fasta_in $fasta_out |
18 #end if | 18 #end if |
19 #if $fastq_in: | 19 #if $fastq_in: |
20 && cp $fastq_in $fastq_out | 20 && cp $fastq_in $fastq_out |
21 #end if | 21 #end if |
22 #if $count_in: | 22 #if $count_in: |
23 && cp $count_in $count_out | 23 && cp $count_in $count_out |
24 #end if | 24 #end if |
25 #if $qfile_in: | 25 #if $qfile_in: |
26 && cp $qfile_in $qfile_out | 26 && cp $qfile_in $qfile_out |
27 #end if | 27 #end if |
28 #if $name_in: | 28 #if $name_in: |
29 && cp $name_in $name_out | 29 && cp $name_in $name_out |
30 #end if | 30 #end if |
31 #if $group_in: | 31 #if $group_in: |
32 && cp $group_in $group_out | 32 && cp $group_in $group_out |
33 #end if | 33 #end if |
34 #if $alignreport_in: | 34 #if $alignreport_in: |
35 && cp $alignreport_in $alignreport_out | 35 && cp $alignreport_in $alignreport_out |
36 #end if | 36 #end if |
37 #if $list_in: | 37 #if $list_in: |
38 && cp $list_in $list_out | 38 && cp $list_in $list_out |
39 #end if | 39 #end if |
40 #if $taxonomy_in: | 40 #if $taxonomy_in: |
41 && cp $taxonomy_in $taxonomy_out | 41 && cp $taxonomy_in $taxonomy_out |
42 #end if | 42 #end if |
43 #else: | 43 #else: |
44 ## create symlinks to input datasets | 44 ## create symlinks to input datasets |
45 ln -s "$accnos" accnos.dat && | 45 ln -s '$accnos' accnos.dat && |
46 ln -s "$fasta_in" fasta_in.dat && | 46 ln -s '$fasta_in' fasta_in.dat && |
47 ln -s "$fastq_in" fastq_in.dat && | 47 ln -s '$fastq_in' fastq_in.dat && |
48 ln -s "$count_in" count_in.dat && | 48 ln -s '$count_in' count_in.dat && |
49 ln -s "$qfile_in" qfile_in.dat && | 49 ln -s '$qfile_in' qfile_in.dat && |
50 ln -s "$name_in" name_in.dat && | 50 ln -s '$name_in' name_in.dat && |
51 ln -s "$group_in" group_in.dat && | 51 ln -s '$group_in' group_in.dat && |
52 ln -s "$alignreport_in" alignreport_in.dat && | 52 ln -s '$alignreport_in' alignreport_in.dat && |
53 ln -s "$list_in" list_in.dat && | 53 ln -s '$list_in' list_in.dat && |
54 ln -s "$taxonomy_in" taxonomy_in.dat && | 54 ln -s '$taxonomy_in' taxonomy_in.dat && |
55 | 55 |
56 echo 'remove.seqs( | 56 echo 'remove.seqs( |
57 accnos=accnos.dat | 57 accnos=accnos.dat |
58 #if $fasta_in: | 58 #if $fasta_in: |
59 ,fasta=fasta_in.dat | 59 ,fasta=fasta_in.dat |
60 #end if | 60 #end if |
61 #if $fastq_in: | 61 #if $fastq_in: |
62 ,fastq=fastq_in.dat | 62 ,fastq=fastq_in.dat |
63 #end if | 63 #end if |
64 #if $count_in: | 64 #if $count_in: |
65 ,count=count_in.dat | 65 ,count=count_in.dat |
66 #end if | 66 #end if |
67 #if $qfile_in: | 67 #if $qfile_in: |
68 ,qfile=qfile_in.dat | 68 ,qfile=qfile_in.dat |
69 #end if | 69 #end if |
70 #if $name_in: | 70 #if $name_in: |
71 ,name=name_in.dat | 71 ,name=name_in.dat |
72 #end if | 72 #end if |
73 #if $group_in: | 73 #if $group_in: |
74 ,group=group_in.dat | 74 ,group=group_in.dat |
75 #end if | 75 #end if |
76 #if $alignreport_in: | 76 #if $alignreport_in: |
77 ,alignreport=alignreport_in.dat | 77 ,alignreport=alignreport_in.dat |
78 #end if | 78 #end if |
79 #if $list_in: | 79 #if $list_in: |
80 ,list=list_in.dat | 80 ,list=list_in.dat |
81 #end if | 81 #end if |
82 #if $taxonomy_in: | 82 #if $taxonomy_in: |
83 ,taxonomy=taxonomy_in.dat | 83 ,taxonomy=taxonomy_in.dat |
84 #end if | 84 #end if |
85 $dups | 85 $dups |
86 )' | 86 )' |
87 | sed 's/ //g' ## mothur trips over whitespace | 87 | sed 's/ //g' ## mothur trips over whitespace |
88 | mothur | 88 | mothur |
89 | tee mothur.out.log | 89 | tee mothur.out.log |
90 #end if | 90 #end if |
91 ]]></command> | 91 ]]></command> |
92 <inputs> | 92 <inputs> |
93 <param name="accnos" type="data" format="mothur.accnos" label="accnos - Accession Names of sequences to be removed"/> | 93 <param name="accnos" type="data" format="mothur.accnos" label="accnos - Accession Names of sequences to be removed"/> |
94 <param name="fasta_in" type="data" format="fasta" optional="true" label="fasta - Fasta Sequences"/> | 94 <param name="fasta_in" type="data" format="fasta" optional="true" label="fasta - Fasta Sequences"/> |
95 <param name="qfile_in" type="data" format="qual" optional="true" label="qfile - Fasta Quality"/> | 95 <param name="qfile_in" type="data" format="qual" optional="true" label="qfile - Fasta Quality"/> |
99 <param name="alignreport_in" type="data" format="mothur.align.report" optional="true" label="alignreport - Align Report"/> | 99 <param name="alignreport_in" type="data" format="mothur.align.report" optional="true" label="alignreport - Align Report"/> |
100 <param name="list_in" type="data" format="mothur.list" optional="true" label="list - OTU List"/> | 100 <param name="list_in" type="data" format="mothur.list" optional="true" label="list - OTU List"/> |
101 <param name="taxonomy_in" type="data" format="mothur.seq.taxonomy" optional="true" label="taxonomy - Taxonomy"/> | 101 <param name="taxonomy_in" type="data" format="mothur.seq.taxonomy" optional="true" label="taxonomy - Taxonomy"/> |
102 <param name="count_in" type="data" format="mothur.count_table" optional="true" label="count - a count_table" help="generated by count.seqs"/> | 102 <param name="count_in" type="data" format="mothur.count_table" optional="true" label="count - a count_table" help="generated by count.seqs"/> |
103 <param name="dups" type="boolean" truevalue="" falsevalue=",dups=false" checked="true" label="dups - Apply to duplicates"/> | 103 <param name="dups" type="boolean" truevalue="" falsevalue=",dups=false" checked="true" label="dups - Apply to duplicates"/> |
104 <expand macro="param-savelog"/> | |
104 </inputs> | 105 </inputs> |
105 <outputs> | 106 <outputs> |
106 <expand macro="logfile-output"/> | 107 <expand macro="logfile-output"/> |
107 <data name="fasta_out" format_source="fasta_in" from_work_dir="fasta_in.pick.dat" label="${tool.name} on ${on_string}: pick.fasta"> | 108 <data name="fasta_out" format_source="fasta_in" from_work_dir="fasta_in.pick.dat" label="${tool.name} on ${on_string}: pick.fasta"> |
108 <filter>fasta_in</filter> | 109 <filter>fasta_in</filter> |
135 <tests> | 136 <tests> |
136 <test> | 137 <test> |
137 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> | 138 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> |
138 <param name="fasta_in" value="Mock_S280_L001_R1_001_small.trim.contigs.fasta"/> | 139 <param name="fasta_in" value="Mock_S280_L001_R1_001_small.trim.contigs.fasta"/> |
139 <param name="dups" value=""/> | 140 <param name="dups" value=""/> |
140 <expand macro="logfile-test"/> | 141 <param name="savelog" value="true"/> |
141 <output name="fasta_out" md5="2357e1429647afbe21521a60935919bf"/> | 142 <expand macro="logfile-test"/> |
143 <output name="fasta_out"> | |
144 <assert_contents> | |
145 <expand macro="test-fasta-format"/> | |
146 <has_text text="M00967_43_000000000-A3JHG_1_1101_19936_3208"/> | |
147 </assert_contents> | |
148 </output> | |
142 </test> | 149 </test> |
143 <test> | 150 <test> |
144 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> | 151 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> |
145 <param name="fastq_in" value="Mock_S280_L001_R1_001_small.fastq"/> | 152 <param name="fastq_in" value="Mock_S280_L001_R1_001_small.fastq"/> |
146 <expand macro="logfile-test"/> | 153 <param name="savelog" value="true"/> |
147 <output name="fastq_out" md5="1e10d0793f1c5f12388156d5922c0eb8"/> | 154 <expand macro="logfile-test"/> |
155 <output name="fastq_out"> | |
156 <assert_contents> | |
157 <expand macro="test-fastq-format"/> | |
158 <has_text text="M00967_43_000000000-A3JHG_1_1101_19936_3208"/> | |
159 </assert_contents> | |
160 </output> | |
148 </test> | 161 </test> |
149 <test><!-- test two input files --> | 162 <test><!-- test two input files --> |
150 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> | 163 <param name="accnos" value="Mock_S280_L001_R1_001_small.trim.contigs.bad.accnos"/> |
151 <param name="fasta_in" value="Mock_S280_L001_R1_001_small.trim.contigs.fasta"/> | 164 <param name="fasta_in" value="Mock_S280_L001_R1_001_small.trim.contigs.fasta"/> |
152 <param name="fastq_in" value="Mock_S280_L001_R1_001_small.fastq"/> | 165 <param name="fastq_in" value="Mock_S280_L001_R1_001_small.fastq"/> |
153 <param name="dups" value=",dups=false"/> | 166 <param name="dups" value=",dups=false"/> |
154 <expand macro="logfile-test"/> | 167 <param name="savelog" value="true"/> |
155 <output name="fasta_out" md5="2357e1429647afbe21521a60935919bf"/> | 168 <expand macro="logfile-test"/> |
156 <output name="fastq_out" md5="1e10d0793f1c5f12388156d5922c0eb8"/> | 169 <output name="fasta_out"> |
170 <assert_contents> | |
171 <expand macro="test-fasta-format"/> | |
172 <has_text text="M00967_43_000000000-A3JHG_1_1101_19936_3208"/> | |
173 </assert_contents> | |
174 </output> | |
175 <output name="fastq_out"> | |
176 <assert_contents> | |
177 <expand macro="test-fastq-format"/> | |
178 <has_text text="M00967_43_000000000-A3JHG_1_1101_19936_3208"/> | |
179 </assert_contents> | |
180 </output> | |
157 </test> | 181 </test> |
158 <test> | 182 <test> |
159 <param name="accnos" value="amazon.bad.accnos"/> | 183 <param name="accnos" value="amazon.bad.accnos"/> |
160 <param name="count_in" value="amazon.count_table"/> | 184 <param name="count_in" value="amazon.count_table"/> |
161 <expand macro="logfile-test"/> | 185 <param name="savelog" value="true"/> |
162 <output name="count_out" md5="bd1cb7af6f277210c5c11ff7d7c54592"/> | 186 <expand macro="logfile-test"/> |
187 <output name="count_out"> | |
188 <assert_contents> | |
189 <expand macro="test-count-format"/> | |
190 <has_text text="U68595"/> | |
191 </assert_contents> | |
192 </output> | |
163 </test> | 193 </test> |
164 <!-- TODO: make test for empty accnos file --> | 194 <!-- TODO: make test for empty accnos file --> |
165 </tests> | 195 </tests> |
166 <help> | 196 <help><![CDATA[ |
167 <![CDATA[ | |
168 | 197 |
169 @MOTHUR_OVERVIEW@ | 198 @MOTHUR_OVERVIEW@ |
170 | 199 |
171 **Command Documentation** | 200 **Command Documentation** |
172 | 201 |
177 .. _list: https://www.mothur.org/wiki/List_file | 206 .. _list: https://www.mothur.org/wiki/List_file |
178 .. _align.report: https://www.mothur.org/wiki/Align.seqs | 207 .. _align.report: https://www.mothur.org/wiki/Align.seqs |
179 .. _taxonomy: https://www.mothur.org/wiki/Taxonomy_outline | 208 .. _taxonomy: https://www.mothur.org/wiki/Taxonomy_outline |
180 .. _list.seqs: https://www.mothur.org/wiki/list.seqs | 209 .. _list.seqs: https://www.mothur.org/wiki/list.seqs |
181 .. _remove.seqs: https://www.mothur.org/wiki/Remove.seqs | 210 .. _remove.seqs: https://www.mothur.org/wiki/Remove.seqs |
182 ]]> | 211 |
183 </help> | 212 ]]></help> |
184 <expand macro="citations"/> | 213 <expand macro="citations"/> |
185 </tool> | 214 </tool> |