Mercurial > repos > mvdbeek > add_input_name_as_column
annotate add_input_name_as_column.xml @ 1:07d2cbf43b51 draft
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
author | mvdbeek |
---|---|
date | Wed, 06 Mar 2019 09:15:49 -0500 |
parents | bfebefdd5ba4 |
children | ea4ad41e01fc |
rev | line source |
---|---|
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
1 <tool id="addName" name="Add input name as column" version="0.1.2" profile="17.09"> |
0 | 2 <description>to an existing tabular file</description> |
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
3 <requirements> |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
4 <requirement type="package" version="3.7">python</requirement> |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
5 </requirements> |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
6 <command><![CDATA[ |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
7 python '$__tool_directory__/'add_input_name_as_column.py |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
8 --input '$input' |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
9 --label '$input.element_identifier' |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
10 --output '$output' |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
11 #if $header.contains_header=="yes": |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
12 --header "$header.colname" |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
13 #end if |
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
14 ]]></command> |
0 | 15 <inputs> |
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
16 <param format="txt" name="input" type="data" label="to Dataset" help="Dataset missing? See TIP below" /> |
0 | 17 <conditional name="header"> |
18 <param name="contains_header" type="select" label="input contains a header line?" > | |
19 <option value="yes" selected="true">Yes</option> | |
20 <option value="no">No</option> | |
21 </param> | |
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
22 <when value="yes"> |
0 | 23 <param name="colname" type="text" value="sample" help="select a column header to be added in the first line"> |
24 <validator type="empty_field" message="please add a column header"/> | |
25 </param> | |
26 </when> | |
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
27 <when value="no"> |
0 | 28 </when> |
29 </conditional> | |
30 </inputs> | |
31 <outputs> | |
32 <data name="output" format="tabular" /> | |
33 </outputs> | |
34 <tests> | |
35 <test> | |
36 <param name="input" value="signature.tab" ftype="tabular" /> | |
37 <param name="contains_header" value="yes" /> | |
38 <param name="colname" value="sample" /> | |
39 <output name="output" file="signature_with_header.tab" ftype="tabular"/> | |
40 </test> | |
41 <test> | |
42 <param name="input" value="signature.tab" ftype="tabular" /> | |
43 <param name="contains_header" value="no" /> | |
44 <output name="output" file="signature_without_header.tab" ftype="tabular"/> | |
45 </test> | |
46 </tests> | |
47 <help> | |
48 | |
49 .. class:: infomark | |
50 | |
51 **TIP:** If your data is not TAB delimited, use *Text Manipulation->Convert* | |
52 | |
53 ----- | |
54 | |
55 **What it does** | |
56 | |
57 Adds a new column with the name of the input file as it appears in the history. | |
1
07d2cbf43b51
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/add_input_name_as_column commit db90fc6943b99322a6d7459f644a6624c69a0be5-dirty
mvdbeek
parents:
0
diff
changeset
|
58 Written by Marius van den Beek, m.vandenbeek at gmail dot com |
0 | 59 </help> |
60 </tool> | |
61 |