Mercurial > repos > iuc > bedtools
annotate mergeBed.xml @ 59:539958feb49c draft
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
author | iuc |
---|---|
date | Thu, 04 Nov 2021 11:35:06 +0000 |
parents | 1d0a0d6a78b1 |
children | 071c1c5d4bad |
rev | line source |
---|---|
57
1d0a0d6a78b1
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 1e25e8d0bd1ebeb2b94c4bbdff222e56defc1fc2"
iuc
parents:
56
diff
changeset
|
1 <tool id="bedtools_mergebed" name="bedtools MergeBED" version="@TOOL_VERSION@" profile="@PROFILE@"> |
17
a2d4c30ba2f9
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 0887009a23d176b21536c9fd8a18c4fecc417d4f
iuc
parents:
16
diff
changeset
|
2 <description>combine overlapping/nearby intervals into a single interval</description> |
8 | 3 <macros> |
4 <import>macros.xml</import> | |
5 </macros> | |
59
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
6 <expand macro="bio_tools" /> |
8 | 7 <expand macro="requirements" /> |
8 <expand macro="stdio" /> | |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
9 <command><![CDATA[ |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
10 mergeBed |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
11 -i '${input}' |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
12 $strand |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
13 -d $distance |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
14 $header |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
15 @C_AND_O_ARGUMENT@ |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
16 > '${output}' |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
17 ]]></command> |
8 | 18 <inputs> |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
19 <param name="input" argument="-i" type="data" format="bam,@STD_BEDTOOLS_INPUTS@" label="Sort the following BAM/@STD_BEDTOOLS_INPUT_LABEL@ file"/> |
8 | 20 <param name="strand" type="select" label="Calculation based on strandedness?"> |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
21 <option value="" selected="true">Overlaps on either strand</option> |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
22 <option value="-s">Force strandedness. That is, only merge features that are the same strand (-s)</option> |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
23 <option value="-S +">Force merge for forward strand only (-S +)</option> |
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
24 <option value="-S -">Force merge for reverse strand only (-S -)</option> |
8 | 25 </param> |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
26 <param name="distance" argument="-d" type="integer" value="0" |
8 | 27 label="Maximum distance between features allowed for features to be merged" |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
28 help="That is, overlapping and/or book-ended features are merged"/> |
8 | 29 <expand macro="print_header" /> |
16
e30113df8cf6
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 7b8a4ffc823f4dab194f1c629b7e83277dbe4337
iuc
parents:
15
diff
changeset
|
30 <expand macro="c_and_o_argument"> |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
31 <param name="col" argument="-c" type="data_column" data_ref="input" label="Specify the column(s) that should be summarized" /> |
16
e30113df8cf6
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 7b8a4ffc823f4dab194f1c629b7e83277dbe4337
iuc
parents:
15
diff
changeset
|
32 </expand> |
8 | 33 </inputs> |
34 <outputs> | |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
35 <data name="output" format="bed" metadata_source="input" label="Merged ${input.name}"/> |
8 | 36 </outputs> |
37 <tests> | |
38 <test> | |
39 <param name="input" value="mergedBed1.bed" ftype="bed" /> | |
40 <output name="output" file="mergedBed_result1.bed" ftype="bed" /> | |
41 </test> | |
42 <test> | |
43 <param name="input" value="mergedBed2.bed" ftype="bed" /> | |
44 <param name="strandedness" value="-s" /> | |
45 <output name="output" file="mergedBed_result2.bed" ftype="bed" /> | |
46 </test> | |
47 <test> | |
48 <param name="input" value="mergedBed3.bed" ftype="bed" /> | |
49 <param name="report_number" value="-n" /> | |
50 <output name="output" file="mergedBed_result3.bed" ftype="bed" /> | |
51 </test> | |
52 <test> | |
53 <param name="input" value="mergedBed4.bed" ftype="bed" /> | |
54 <param name="distance" value="1000" /> | |
55 <output name="output" file="mergedBed_result4.bed" ftype="bed" /> | |
56 </test> | |
57 <test> | |
58 <param name="input" value="mergedBed4.bed" ftype="bed" /> | |
59 <param name="distance" value="1000" /> | |
60 <repeat name="c_and_o_argument_repeat"> | |
61 <param name="col" value="1"/> | |
62 <param name="operation" value="count"/> | |
63 </repeat> | |
64 <output name="output" file="mergedBed_result5.bed" ftype="bed" /> | |
65 </test> | |
66 </tests> | |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
67 <help><![CDATA[ |
8 | 68 **What it does** |
69 | |
70 bedtools merge combines overlapping or "book-ended" features in an interval file into a single feature which spans all of the combined features. | |
71 | |
72 | |
73 .. image:: $PATH_TO_IMAGES/merge-glyph.png | |
74 | |
75 | |
76 .. class:: warningmark | |
77 | |
78 bedtools merge requires that you presort your data by chromosome and then by start position. | |
79 | |
80 | |
81 ========================================================================== | |
82 Default behavior | |
83 ========================================================================== | |
84 By default, ``bedtools merge`` combines overlapping (by at least 1 bp) and/or | |
85 bookended intervals into a single, "flattened" or "merged" interval. | |
86 | |
87 :: | |
88 | |
89 $ cat A.bed | |
90 chr1 100 200 | |
91 chr1 180 250 | |
92 chr1 250 500 | |
93 chr1 501 1000 | |
94 | |
95 $ bedtools merge -i A.bed | |
96 chr1 100 500 | |
97 chr1 501 1000 | |
98 | |
99 | |
100 ========================================================================== | |
101 *-s* Enforcing "strandedness" | |
102 ========================================================================== | |
103 The ``-s`` option will only merge intervals that are overlapping/bookended | |
104 *and* are on the same strand. | |
105 | |
106 :: | |
107 | |
108 $ cat A.bed | |
109 chr1 100 200 a1 1 + | |
110 chr1 180 250 a2 2 + | |
111 chr1 250 500 a3 3 - | |
112 chr1 501 1000 a4 4 + | |
113 | |
114 $ bedtools merge -i A.bed -s | |
115 chr1 100 250 + | |
116 chr1 501 1000 + | |
117 chr1 250 500 - | |
118 | |
119 | |
120 ========================================================================== | |
26
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
121 *-d* Controlling how close two features must be in order to merge |
8 | 122 ========================================================================== |
26
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
123 By default, only overlapping or book-ended features are combined into a new |
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
124 feature. However, one can force ``merge`` to combine more distant features |
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
125 with the ``-d`` option. For example, were one to set ``-d`` to 1000, any |
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
126 features that overlap or are within 1000 base pairs of one another will be |
8 | 127 combined. |
128 | |
129 :: | |
130 | |
131 $ cat A.bed | |
132 chr1 100 200 | |
133 chr1 501 1000 | |
26
c0fbce5dc84a
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 19967671ddd4e750f53d71274e5c12325a402811
iuc
parents:
17
diff
changeset
|
134 |
8 | 135 $ bedtools merge -i A.bed |
136 chr1 100 200 | |
137 chr1 501 1000 | |
138 | |
139 $ bedtools merge -i A.bed -d 1000 | |
140 chr1 100 200 1000 | |
141 | |
142 | |
143 @REFERENCES@ | |
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
144 ]]></help> |
8 | 145 <expand macro="citations" /> |
146 </tool> |