Mercurial > repos > iuc > bedtools
annotate bamToBed.xml @ 64:f6c88d2e9ae5 draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 73ebd55430874a3c1483b6dd6cce0482175482f9
| author | iuc |
|---|---|
| date | Fri, 21 Feb 2025 21:38:34 +0000 |
| parents | 539958feb49c |
| children |
| rev | line source |
|---|---|
|
64
f6c88d2e9ae5
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 73ebd55430874a3c1483b6dd6cce0482175482f9
iuc
parents:
59
diff
changeset
|
1 <tool id="bedtools_bamtobed" name="bedtools BAM to BED" version="@TOOL_VERSION@+galaxy0" profile="@PROFILE@"> |
|
17
a2d4c30ba2f9
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 0887009a23d176b21536c9fd8a18c4fecc417d4f
iuc
parents:
8
diff
changeset
|
2 <description>converter</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" /> |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
7 <expand macro="requirements"> |
|
64
f6c88d2e9ae5
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 73ebd55430874a3c1483b6dd6cce0482175482f9
iuc
parents:
59
diff
changeset
|
8 <requirement type="package" version="1.18">samtools</requirement> |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
9 </expand> |
| 8 | 10 <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
|
11 <command><![CDATA[ |
|
55
678ea22d643d
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b822ff8f05f2396fc15bd95a71bc6878503081eb"
iuc
parents:
51
diff
changeset
|
12 #if $input.extension in ['bam', 'unsorted.bam', 'qname_input_sorted.bam'] and $option == "-bedpe": |
|
59
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
13 samtools sort -n -@ "\${GALAXY_SLOTS:-4}" -T "\${TMPDIR:-.}" '${input}' > ./input.bam && |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
14 #else |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
15 ln -s '${input}' ./input.bam && |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
16 #end if |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
17 |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
18 bedtools bamtobed |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
19 $option |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
20 $ed_score |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
21 $split |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
22 #if $tag and str($tag).strip(): |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
23 -tag '${tag}' |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
24 #end if |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
25 -i ./input.bam |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
26 > '${output}' |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
27 ]]></command> |
| 8 | 28 <inputs> |
|
55
678ea22d643d
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b822ff8f05f2396fc15bd95a71bc6878503081eb"
iuc
parents:
51
diff
changeset
|
29 <param name="input" type="data" format="unsorted.bam" label="Convert the following BAM file to BED"/> |
| 8 | 30 <param name="option" type="select" label="What type of BED output would you like"> |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
31 <option value="">Create a 6-column BED file</option> |
|
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
32 <option value="-bed12">Create a full, 12-column "blocked" BED file</option> |
|
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
33 <option value="-bedpe">Create a paired-end, BEDPE format</option> |
| 8 | 34 </param> |
| 35 <expand macro="split" /> | |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
36 <param name="ed_score" argument="-ed" type="boolean" truevalue="-ed" falsevalue="" checked="false" |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
37 label="Use alignment's edit-distance for BED score" /> |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
38 <param argument="-tag" type="text" optional="true" |
|
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
39 label="Use other NUMERIC BAM alignment tag as the BED score" /> |
| 8 | 40 </inputs> |
| 41 <outputs> | |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
42 <data name="output" format="bed" metadata_source="input" label="${input.name} (as BED)"/> |
| 8 | 43 </outputs> |
| 44 <tests> | |
| 45 <test> | |
| 46 <param name="input" value="srma_in3.bam" ftype="bam" /> | |
| 47 <param name="option" value="" /> | |
| 48 <param name="tag" value="" /> | |
| 49 <output name="output" file="bamToBed_result1.bed" ftype="bed" /> | |
| 50 </test> | |
| 51 <test> | |
| 52 <param name="input" value="srma_in3.bam" ftype="bam" /> | |
| 53 <param name="option" value="" /> | |
| 54 <param name="tag" value="NM" /> | |
| 55 <output name="output" file="bamToBed_result2.bed" ftype="bed" /> | |
| 56 </test> | |
|
59
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
57 <test> |
|
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
58 <param name="input" value="bedpeToBam_result1.bam" ftype="bam" /> |
|
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
59 <param name="option" value="-bedpe" /> |
|
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
60 <param name="tag" value="" /> |
|
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
61 <output name="output" file="bamToBed_result3.bed" ftype="bed" /> |
|
539958feb49c
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
iuc
parents:
57
diff
changeset
|
62 </test> |
| 8 | 63 </tests> |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
64 <help><![CDATA[ |
| 8 | 65 **What it does** |
| 66 | |
| 67 bedtools bamtobed is a conversion utility that converts sequence alignments in BAM format into BED, BED12, and/or BEDPE records. | |
| 68 | |
| 69 .. class:: infomark | |
| 70 | |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
71 The "Report spliced BAM alignment..." option breaks BAM alignments with the "N" (splice) operator into distinct BED entries. |
|
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
72 For example, using this option on a CIGAR such as 50M1000N50M would, by default, produce a single BED record that spans 1100bp. |
|
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
73 However, using this option, it would create two separate BED records that are each 50bp in size and are separated by 1000bp (the size of the N operation). |
|
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
74 This is important for RNA-seq and structural variation experiments. |
| 8 | 75 |
| 76 | |
| 77 .. class:: warningmark | |
| 78 | |
|
18
5efc48568d8d
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit e5a5ad091c621348dc6ce2df861475ebc54a380e
iuc
parents:
17
diff
changeset
|
79 If using a custom BAM alignment TAG as the BED score, note that this must be a numeric tag (e.g., type "i" as in NM:i:0). |
| 8 | 80 |
| 81 | |
| 82 @REFERENCES@ | |
|
50
df28283b3778
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit b68002321ade5e160c556517a98ffb70f068be95
iuc
parents:
48
diff
changeset
|
83 ]]></help> |
| 8 | 84 <expand macro="citations" /> |
| 85 </tool> |
