Mercurial > repos > devteam > subtract_query
comparison subtract_query.xml @ 3:f58ba0382c26 draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tool_collections/gops/subtract_query commit cae3e05d02e60f595bb8b6d77a84f030e9bd1689
author | devteam |
---|---|
date | Thu, 22 Jun 2017 18:51:44 -0400 |
parents | 8a3448727cec |
children |
comparison
equal
deleted
inserted
replaced
2:659a1c095357 | 3:f58ba0382c26 |
---|---|
1 <tool id="subtract_query1" name="Subtract Whole Dataset" version="0.1"> | 1 <tool id="subtract_query1" name="Subtract Whole Dataset" version="0.1"> |
2 <description>from another dataset</description> | 2 <description>from another dataset</description> |
3 <requirements> | 3 <macros> |
4 <requirement type="package" version="0.7.1">bx-python</requirement> | 4 <import>macros.xml</import> |
5 <requirement type="package" version="1.0.0">galaxy-ops</requirement> | 5 </macros> |
6 </requirements> | 6 <expand macro="requirements" /> |
7 <command interpreter="python"> | 7 <command><![CDATA[ |
8 subtract_query.py $input1 $input2 $begin_col $end_col $output | 8 python '$__tool_directory__/subtract_query.py' |
9 #if str($ignore_empty_end_cols) == 'true': | 9 '$input1' |
10 --ignore-empty-end-cols | 10 '$input2' |
11 #end if | 11 $begin_col |
12 | 12 $end_col |
13 </command> | 13 '$output' |
14 <inputs> | 14 #if str($ignore_empty_end_cols) == 'true': |
15 <param format="txt" name="input2" type="data" label="Subtract" help="Second dataset" /> | 15 --ignore-empty-end-cols |
16 <param format="txt" name="input1" type="data" label="from" help="First dataset" /> | 16 #end if |
17 <param name="begin_col" type="data_column" data_ref="input1" force_select="False" label="Restrict subtraction between 'begin column'" /> | 17 ]]></command> |
18 <param name="end_col" type="data_column" data_ref="input1" force_select="False" label="and 'end column'" help="Specifying columns for restricting subtraction is available only for tabular formatted datasets" /> | 18 <inputs> |
19 <param name="ignore_empty_end_cols" type="boolean" label="Ignore empty columns and whitespace at end of line when subtracting"/> | 19 <param name="input2" type="data" format="txt" label="Subtract" help="Second dataset" /> |
20 </inputs> | 20 <param name="input1" type="data" format="txt" label="from" help="First dataset" /> |
21 <outputs> | 21 <param name="begin_col" type="data_column" data_ref="input1" force_select="False" label="Restrict subtraction between 'begin column'" /> |
22 <data format="input" name="output" metadata_source="input1" /> | 22 <param name="end_col" type="data_column" data_ref="input1" force_select="False" label="and 'end column'" help="Specifying columns for restricting subtraction is available only for tabular formatted datasets" /> |
23 </outputs> | 23 <param name="ignore_empty_end_cols" type="boolean" label="Ignore empty columns and whitespace at end of line when subtracting"/> |
24 <tests> | 24 </inputs> |
25 <!-- Subtract 2 non-tabular files with no column restrictions. --> | 25 <outputs> |
26 <!-- Cannot figure out why this test won't pass, it works in real time... --> | 26 <data name="output" format_source="input1" metadata_source="input1" /> |
27 <!-- | 27 </outputs> |
28 <test> | 28 <tests> |
29 <param name="input1" value="1.txt" /> | 29 <!-- Subtract 2 non-tabular files with no column restrictions. --> |
30 <param name="input2" value="2.txt" /> | 30 <!-- Cannot figure out why this test won't pass, it works in real time... --> |
31 <param name="begin_col" value="None" /> | 31 <!-- |
32 <param name="end_col" value="None" /> | 32 <test> |
33 <output name="output" file="subtract-query-1.dat" /> | 33 <param name="input1" value="1.txt" /> |
34 </test> | 34 <param name="input2" value="2.txt" /> |
35 --> | 35 <param name="begin_col" value="None" /> |
36 <!-- Subtract 2 tabular files with no column restrictions. --> | 36 <param name="end_col" value="None" /> |
37 <test> | 37 <output name="output" file="subtract-query-1.dat" /> |
38 <param name="input1" value="eq-showbeginning.dat" /> | 38 </test> |
39 <param name="input2" value="eq-showtail.dat" /> | 39 --> |
40 <param name="begin_col" value="None" /> | 40 <!-- Subtract 2 tabular files with no column restrictions. --> |
41 <param name="end_col" value="None" /> | 41 <test> |
42 <output name="output" file="subtract-query-2.dat" /> | 42 <param name="input1" value="eq-showbeginning.dat" /> |
43 </test> | 43 <param name="input2" value="eq-showtail.dat" /> |
44 <!-- Subtract 2 tabular files with column restrictions. --> | 44 <param name="begin_col" value="" /> |
45 <test> | 45 <param name="end_col" value="" /> |
46 <param name="input1" value="eq-showbeginning.dat" /> | 46 <output name="output" file="subtract-query-2.dat" /> |
47 <param name="input2" value="eq-removebeginning.dat" /> | 47 </test> |
48 <param name="begin_col" value="c1" /> | 48 <!-- Subtract 2 tabular files with column restrictions. --> |
49 <param name="end_col" value="c3" /> | 49 <test> |
50 <output name="output" file="subtract-query-3.dat" /> | 50 <param name="input1" value="eq-showbeginning.dat" /> |
51 </test> | 51 <param name="input2" value="eq-removebeginning.dat" /> |
52 <!-- Subtract a non-tabular file from a tabular file with no column restrictions. --> | 52 <param name="begin_col" value="c1" /> |
53 <test> | 53 <param name="end_col" value="c3" /> |
54 <param name="input1" value="eq-showbeginning.dat" /> | 54 <output name="output" file="subtract-query-3.dat" /> |
55 <param name="input2" value="2.txt" /> | 55 </test> |
56 <param name="begin_col" value="None" /> | 56 <!-- Subtract a non-tabular file from a tabular file with no column restrictions. --> |
57 <param name="end_col" value="None" /> | 57 <test> |
58 <output name="output" file="subtract-query-4.dat" /> | 58 <param name="input1" value="eq-showbeginning.dat" /> |
59 </test> | 59 <param name="input2" value="2.txt" /> |
60 <!-- Subtract 2 tabular files with no column restrictions, ignoring empty end columns. --> | 60 <param name="begin_col" value="" /> |
61 <test> | 61 <param name="end_col" value="" /> |
62 <param name="input1" value="eq-showbeginning_e.dat" /> | 62 <output name="output" file="subtract-query-4.dat" /> |
63 <param name="input2" value="eq-showtail.dat" /> | 63 </test> |
64 <param name="begin_col" value="None" /> | 64 <!-- Subtract 2 tabular files with no column restrictions, ignoring empty end columns. --> |
65 <param name="end_col" value="None" /> | 65 <test> |
66 <param name="ignore_empty_end_cols" value="true" /> | 66 <param name="input1" value="eq-showbeginning_e.dat" /> |
67 <output name="output" file="subtract-query-2.dat" /> | 67 <param name="input2" value="eq-showtail.dat" /> |
68 </test> | 68 <param name="begin_col" value="" /> |
69 </tests> | 69 <param name="end_col" value="" /> |
70 <help> | 70 <param name="ignore_empty_end_cols" value="true" /> |
71 | 71 <output name="output" file="subtract-query-2.dat" /> |
72 </test> | |
73 </tests> | |
74 <help><![CDATA[ | |
72 .. class:: infomark | 75 .. class:: infomark |
73 | 76 |
74 **TIP:** This tool complements the tool in the **Operate on Genomic Intervals** tool set which subtracts the intervals of two datasets. | 77 **TIP:** This tool complements the tool in the **Operate on Genomic Intervals** tool set which subtracts the intervals of two datasets. |
75 | |
76 | 78 |
77 ----- | 79 ----- |
78 | 80 |
79 **Syntax** | 81 **Syntax** |
80 | 82 |
81 This tool subtracts an entire dataset from another dataset. | 83 This tool subtracts an entire dataset from another dataset. |
82 | 84 |
83 - Any text format is valid. | 85 - Any text format is valid. |
84 - If both dataset formats are tabular, you may restrict the subtraction to specific columns **contained in both datasets** and the resulting dataset will include only the columns specified. | 86 - If both dataset formats are tabular, you may restrict the subtraction to specific columns **contained in both datasets** and the resulting dataset will include only the columns specified. |
85 - The begin column must be less than or equal to the end column. If it is not, begin column is switched with end column. | 87 - The begin column must be less than or equal to the end column. If it is not, begin column is switched with end column. |
86 - If begin column is specified but end column is not, end column will default to begin_column (and vice versa). | 88 - If begin column is specified but end column is not, end column will default to begin_column (and vice versa). |
87 - All blank and comment lines are skipped and not included in the resulting dataset (comment lines are lines beginning with a # character). | 89 - All blank and comment lines are skipped and not included in the resulting dataset (comment lines are lines beginning with a # character). |
88 - Duplicate lines are eliminated from both dataset prior to subtraction. If any duplicate lines were eliminated from the first dataset, the number is displayed in the resulting history item. | 90 - Duplicate lines are eliminated from both dataset prior to subtraction. If any duplicate lines were eliminated from the first dataset, the number is displayed in the resulting history item. |
89 | 91 |
100 chr2 1 5 | 102 chr2 1 5 |
101 chr10 2 10 | 103 chr10 2 10 |
102 chr1 30 55 | 104 chr1 30 55 |
103 chrY 1 20 | 105 chrY 1 20 |
104 chr1 1225979 42287290 | 106 chr1 1225979 42287290 |
105 chr10 7 8 | 107 chr10 7 8 |
106 | 108 |
107 and this is the **Second dataset**:: | 109 and this is the **Second dataset**:: |
108 | 110 |
109 chr1 4225 19670 | 111 chr1 4225 19670 |
110 chr10 6 8 | 112 chr10 6 8 |
115 chrY 1 20 | 117 chrY 1 20 |
116 chr1 1225979 42287290 | 118 chr1 1225979 42287290 |
117 | 119 |
118 Subtracting the **Second dataset** from the **First dataset** (including all columns) will yield:: | 120 Subtracting the **Second dataset** from the **First dataset** (including all columns) will yield:: |
119 | 121 |
120 chr10 7 8 | 122 chr10 7 8 |
121 chr10 2 10 | 123 chr10 2 10 |
122 | 124 |
123 Conversely, subtracting the **First dataset** from the **Second dataset** (including all columns) will result in an empty dataset. | 125 Conversely, subtracting the **First dataset** from the **Second dataset** (including all columns) will result in an empty dataset. |
124 | 126 |
125 Subtracting the **Second dataset** from the **First dataset** (restricting to columns c1 and c2) will yield:: | 127 Subtracting the **Second dataset** from the **First dataset** (restricting to columns c1 and c2) will yield:: |
126 | 128 |
127 chr10 7 | 129 chr10 7 |
128 chr10 2 | 130 chr10 2 |
129 | 131 ]]></help> |
130 </help> | |
131 </tool> | 132 </tool> |