diff cd_hit_protein.xml @ 3:626cd6334dbc draft

planemo upload for repository https://github.com/ASaiM/galaxytools/tree/master/tools/cdhit/ commit ea0424ae045ac797c080aeabab9a8536f7eb2f84-dirty
author bebatut
date Mon, 25 Apr 2016 12:13:50 -0400
parents aa923171e225
children
line wrap: on
line diff
--- a/cd_hit_protein.xml	Thu Apr 14 09:24:49 2016 -0400
+++ b/cd_hit_protein.xml	Mon Apr 25 12:13:50 2016 -0400
@@ -1,89 +1,51 @@
 <tool id="cd_hit_protein" name="CD-HIT PROTEIN" version="1.3">
   <description>Cluster a protein dataset into representative sequences</description>
-
-  <macros>
-    <import>cdhit_macros.xml</import>
-  </macros>
-
-  <expand macro="requirements"/>
+    <macros>
+      <import>cdhit_macros.xml</import>
+    </macros>
 
-  <command><![CDATA[
-    cd-hit 
-      -i "$fasta_in" 
-      -o rep_seq 
-      -c $similarity 
-      -n $wordsize 
-      #include source=$common_cdhit_options#
-      #include source=$runtime_tuning#
-  ]]></command>
+    <expand macro="requirements"/>
 
-  <inputs>
-    <param name="fasta_in" type="data" format="fasta" label="Protein Sequences to cluster"/>
-    <param name="similarity" type="float" value="0.9"  label="similarity threshold: .4 - 1.0 (default .9)">
-      <validator type="in_range" message="sequence similarity threshold should be .4 - 1.0" min=".4" max="1.0"/>
-    </param>
-    <param name="wordsize" type="integer" value="5"  label="word size (default 5)">
-      <help> Suggested word size:
-           5    for thresholds 0.7 ~ 1.0; 
-           4    for thresholds 0.6 ~ 0.7; 
-           3    for thresholds 0.5 ~ 0.6; 
-           2    for thresholds 0.4 ~ 0.5; 
-      </help>
-      <validator type="in_range" message="word size should be between 2 and 5" min="2" max="5"/>
-    </param>
-    <expand macro="common_cdhit_options" />
-    <expand macro="runtime_tuning" />
-  </inputs>
+    <command><![CDATA[
+      cd-hit 
+        -i "$fasta_in" 
+        -o rep_seq 
+        -c $similarity 
+        -n $wordsize 
 
-  <outputs>
-    <data format="txt" name="clusters_out" label="${tool.name} on ${on_string}: clusters" from_work_dir="rep_seq.clstr"/>
-    <data format="fasta" name="fasta_out" label="${tool.name} on ${on_string}: representatives.fasta" from_work_dir="rep_seq"/>
-  </outputs>
+        #include source=$common_cdhit_options#
+    ]]></command>
+
+    <inputs>
+      <param name="fasta_in" type="data" format="fasta" label="Protein Sequences to cluster" help="(-i)"/>
+
+      <param name="similarity" type="float" value="0.9"  label="Similarity threshold" min=".4" max="1.0" help="Similarity threshold must be in [0.4;1.0] interval (-c)"/>
+
+      <param name="wordsize" type="integer" value="5"  label="Word size" min="2" max="5" help="It is suggested to adjust word size in function of similarity threshold. 5 for threshold in [0.7;1.0] interval, 4 for [0.6;0.7], 3 for [0.5;0.6], 2 for [0.4;0.5] (-n)"/>
 
-  <tests>
-    <test>
-       <param name="fasta_in" value="cd_hit_protein_in.fasta" />
-       <param name="similarity" value="0.9"/>
-       <param name="wordsize" value="5"/>
-       <!-- conditionals in macros -->
-       <param name="settings" value="no"/>
-       <param name="tuning" value="default"/>
-       <output name="clusters_out">
-           <assert_contents>
-               <has_text text="Cluster 0" />
-               <!--
-               <has_text_matching expression=">sp.P00338-2.LDHA_HU" />
-               -->
-           </assert_contents>
-       </output>
-       <output name="fasta_out">
-           <assert_contents>
-               <has_text_matching expression=">sp.P19858.LDHA_BOVIN" />
-           </assert_contents>
-       </output>
-    </test>
-    <test>
-      <param name="fasta_in" value="cd_hit_protein_in.fasta" />
-      <param name="similarity" value="0.8" />
-      <param name="wordsize" value="5" />
-     <!-- conditionals in macros -->
-      <param name="settings" value="no"/>
-      <param name="tuning" value="default"/>
-      <output name="clusters_out">
-        <assert_contents>
-      <has_text text="Cluster 0" />
-      <not_has_text text="Cluster 4" />
-        </assert_contents>
-      </output>
-      <output name="fasta_out">
-        <assert_contents>
-        <has_text_matching expression=">sp.P00340.LDHA_CHICK" />
-        </assert_contents>
-      </output>
-    </test>
-  </tests>
+      <expand macro="common_cdhit_options" />
+    </inputs>
+
+    <outputs>
+      <data format="txt" name="clusters_out" label="${tool.name} on ${on_string}: Clusters" from_work_dir="rep_seq.clstr"/>
+      <data format="fasta" name="fasta_out" label="${tool.name} on ${on_string}: Representatives sequences" from_work_dir="rep_seq"/>
+    </outputs>
 
-  <help><![CDATA[
+    <tests>
+      <test>
+        <param name="fasta_in" value="cd_hit_protein_in.fasta" />
+        <param name="similarity" value="0.9" />
+        <param name="wordsize" value="5" />
+        <param name="settings" value="no"/>
+        <param name="print_alignment" value="false"/>
+        <param name="cluster_type" value="false"/>
+        <param name="tuning" value="default"/>
+        <output name="clusters_out" file="protein_clusters_output.txt"/>
+        <output name="fasta_out" file="protein_fasta_output.fasta"/>
+      </test>
+    </tests>
+
+    <help><![CDATA[
 **What it does**
 
 CD-HIT_ stands for Cluster Database at High Identity with Tolerance. The program (cd-hit) takes a fasta format sequence database as input and produces a set of 'non-redundant' (nr) representative sequences as output. In addition cd-hit outputs a cluster file, documenting the sequence 'groupies' for each nr sequence representative. The idea is to reduce the overall size of the database without removing any sequence information by only removing 'redundant' (or highly similar) sequences. This is why the resulting database is called non-redundant (nr). Essentially, cd-hit produces a set of closely related protein families from a given fasta sequence database.
@@ -94,35 +56,33 @@
 
 **Inputs**
 
-cd-hit requires a protein fasta dataset as input.
- 
+cd-hit requires a protein fasta file as input.
+
 ------
 
 **Outputs**
 
-A fasta datasets containing representative sequences.
+The first output is a fasta file containing representative sequences.
 
-A text file listing the mapping of sequences to the representative sequences::
+The second output is a text file listing the mapping of sequences to the representative sequences::
 
-	>Cluster 0
-	0 2799aa, >PF04998.6|RPOC2_CHLRE/275-3073... *
-	>Cluster 1
-	0 2214aa, >PF06317.1|Q6Y625_9VIRU/1-2214... at 80%
-	1 2215aa, >PF06317.1|O09705_9VIRU/1-2215... at 84%
-	2 2217aa, >PF06317.1|Q6Y630_9VIRU/1-2217... *
-	3 2216aa, >PF06317.1|Q6GWS6_9VIRU/1-2216... at 84%
-	4 527aa, >PF06317.1|Q67E14_9VIRU/6-532... at 63%
-	>Cluster 2
-	0 2202aa, >PF06317.1|Q6UY61_9VIRU/8-2209... at 60%
-	1 2208aa, >PF06317.1|Q6IVU4_JUNIN/1-2208... *
-	2 2207aa, >PF06317.1|Q6IVU0_MACHU/1-2207... at 73%
-	3 2208aa, >PF06317.1|RRPO_TACV/1-2208... at 69%
+  >Cluster 0
+  0 2799aa, >PF04998.6|RPOC2_CHLRE/275-3073... *
+  >Cluster 1
+  0 2214aa, >PF06317.1|Q6Y625_9VIRU/1-2214... at 80%
+  1 2215aa, >PF06317.1|O09705_9VIRU/1-2215... at 84%
+  2 2217aa, >PF06317.1|Q6Y630_9VIRU/1-2217... *
+  3 2216aa, >PF06317.1|Q6GWS6_9VIRU/1-2216... at 84%
+  4 527aa, >PF06317.1|Q67E14_9VIRU/6-532... at 63%
+  >Cluster 2
+  0 2202aa, >PF06317.1|Q6UY61_9VIRU/8-2209... at 60%
+  1 2208aa, >PF06317.1|Q6IVU4_JUNIN/1-2208... *
+  2 2207aa, >PF06317.1|Q6IVU0_MACHU/1-2207... at 73%
+  3 2208aa, >PF06317.1|RRPO_TACV/1-2208... at 69%
+    ]]></help>
 
-
-  ]]></help>
-
-  <citations>
-    <citation type="doi">10.1093/bioinformatics/btl158</citation>
-    <citation type="doi">10.1093/bioinformatics/bts565</citation>
-  </citations>
+    <citations>
+        <citation type="doi">10.1093/bioinformatics/btl158</citation>
+        <citation type="doi">10.1093/bioinformatics/bts565</citation>
+    </citations>
 </tool>