Mercurial > repos > artbio > bamparse
comparison bamparse.xml @ 2:8ea06787c08a draft
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/bamparse commit 968c9ab925ed768027ff8012d0ff6410fc24f079
author | artbio |
---|---|
date | Tue, 09 Oct 2018 17:14:57 -0400 |
parents | ae9ea0488850 |
children | 120eb76aa500 |
comparison
equal
deleted
inserted
replaced
1:ae9ea0488850 | 2:8ea06787c08a |
---|---|
1 <tool id="bamparse" name="Count alignments" version="2.0.1"> | 1 <tool id="bamparse" name="Count alignments" version="3.0.0"> |
2 <description>in a BAM file</description> | 2 <description>in a BAM file</description> |
3 <requirements> | 3 <requirements> |
4 <requirement type="package" version="1.1.2">bowtie</requirement> | |
5 <requirement type="package" version="1.11.2">numpy</requirement> | |
6 <requirement type="package" version="0.11.2.1">pysam</requirement> | 4 <requirement type="package" version="0.11.2.1">pysam</requirement> |
5 <requirement type="package" version="0.6.6">sambamba</requirement> | |
7 </requirements> | 6 </requirements> |
8 <stdio> | 7 <stdio> |
9 <exit_code range="1:" level="fatal" description="Tool exception" /> | 8 <exit_code range="1:" level="fatal" description="Tool exception" /> |
10 </stdio> | 9 </stdio> |
11 <command detect_errors="exit_code"><![CDATA[ | 10 <command detect_errors="exit_code"><![CDATA[ |
12 mkdir outputdir && | 11 mkdir outputdir && |
12 #if $polarity == 'sense': | |
13 #set pol=' and not reverse_strand' | |
14 #else if $polarity == 'antisense': | |
15 #set pol=' and reverse_strand' | |
16 #else: | |
17 #set pol='' | |
18 #end if | |
13 #for $file in $input_list | 19 #for $file in $input_list |
14 samtools index '$file' && | 20 sambamba view -t \$GALAXY_SLOTS -F "not unmapped$pol" -f bam '$file' -o '$file.element_identifier' && |
21 samtools index '$file.element_identifier' && | |
15 #end for | 22 #end for |
16 python $__tool_directory__/bamparse.py | 23 python $__tool_directory__/bamparse.py |
17 --alignments | 24 --alignments |
18 #for $file in $input_list | 25 #for $file in $input_list |
19 '$file' | 26 '$file.element_identifier' |
20 #end for | 27 #end for |
21 --labels | 28 --labels |
22 #for $file in $input_list | 29 #for $file in $input_list |
23 '$file.element_identifier' | 30 '$file.element_identifier' |
24 #end for | 31 #end for |
25 --polarity '$polarity' | |
26 --number '$output_option' | 32 --number '$output_option' |
27 ]]></command> | 33 ]]></command> |
28 <inputs> | 34 <inputs> |
29 <param name="input_list" type="data" format="bam" label="Select multiple alignments to parse" multiple="true"/> | 35 <param name="input_list" type="data" format="bam" label="Select multiple alignments to parse" multiple="true"/> |
30 <param name="polarity" type="select" label="how to count sense and antisense reads"> | 36 <param name="polarity" type="select" label="how to count sense and antisense reads"> |
42 <outputs> | 48 <outputs> |
43 <data name="output" format="tabular" label="Counts"> | 49 <data name="output" format="tabular" label="Counts"> |
44 <discover_datasets pattern="(?P<designation>.*)\.tabular" ext="tabular" visible="true" assign_primary_output="true" directory="outputdir"/> | 50 <discover_datasets pattern="(?P<designation>.*)\.tabular" ext="tabular" visible="true" assign_primary_output="true" directory="outputdir"/> |
45 </data> | 51 </data> |
46 </outputs> | 52 </outputs> |
53 <tests> | |
54 <test> | |
55 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="bam" /> | |
56 <param name="polarity" value="both" /> | |
57 <param name="output_option" value="unique" /> | |
58 <output name="output" ftype="tabular" file="table.tabular" /> | |
59 </test> | |
60 <test> | |
61 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="bam" /> | |
62 <param name="polarity" value="both" /> | |
63 <param name="output_option" value="multiple" /> | |
64 <output name="output" ftype="tabular" file="table0.tabular"> | |
65 <discovered_dataset designation="table1" ftype="tabular" file="table1.tabular" /> | |
66 </output> | |
67 </test> | |
68 <test> | |
69 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="bam" /> | |
70 <param name="polarity" value="sense" /> | |
71 <param name="output_option" value="unique" /> | |
72 <output name="output" ftype="tabular" file="table.tabular" /> | |
73 </test> | |
74 <test> | |
75 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="bam" /> | |
76 <param name="polarity" value="antisense" /> | |
77 <param name="output_option" value="unique" /> | |
78 <output name="output" ftype="tabular" file="table_antisense.tabular" /> | |
79 </test> | |
80 | |
81 <test> | |
82 <param name="input_list" value="input1.bam,input2.bam,input_new2.bam" ftype="bam" /> | |
83 <param name="polarity" value="both" /> | |
84 <param name="output_option" value="multiple" /> | |
85 <output name="output" ftype="tabular" file="more_table0.tabular"> | |
86 <discovered_dataset designation="table1" ftype="tabular" file="more_table1.tabular" /> | |
87 <discovered_dataset designation="table2" ftype="tabular" file="more_table2.tabular" /> | |
88 </output> | |
89 </test> | |
90 <test> | |
91 <param name="input_list" value="input1.bam,input2.bam,input_new2.bam" ftype="bam" /> | |
92 <param name="polarity" value="sense" /> | |
93 <param name="output_option" value="unique" /> | |
94 <output name="output" ftype="tabular" file="more_sense_table.tabular" /> | |
95 </test> | |
96 <test> | |
97 <param name="input_list" value="input1.bam,input2.bam,input_new2.bam" ftype="bam" /> | |
98 <param name="polarity" value="antisense" /> | |
99 <param name="output_option" value="unique" /> | |
100 <output name="output" ftype="tabular" file="more_antisense_table.tabular" /> | |
101 </test> | |
102 | |
103 | |
104 </tests> | |
47 <help> | 105 <help> |
48 | 106 |
49 **What it does** | 107 **What it does** |
50 | 108 |
51 Counts the number of reads aligned to each reference (@SN, reference NAME) in one or | 109 Counts the number of reads aligned to each reference (@SN, reference NAME) in one or |
54 Sense, antisense or both sense and antisense alignments can be counted | 112 Sense, antisense or both sense and antisense alignments can be counted |
55 | 113 |
56 The library labels in the returned count table are taken from the input bam datasets | 114 The library labels in the returned count table are taken from the input bam datasets |
57 names in the Galaxy history. | 115 names in the Galaxy history. |
58 </help> | 116 </help> |
59 <tests> | |
60 <test> | |
61 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="tabular" /> | |
62 <param name="polarity" value="both" /> | |
63 <param name="output_option" value="unique" /> | |
64 <output name="output" ftype="tabular" file="table.tabular" /> | |
65 </test> | |
66 <test> | |
67 <param name="input_list" value="alignment1.bam,alignment2.bam" ftype="tabular" /> | |
68 <param name="polarity" value="both" /> | |
69 <param name="output_option" value="multiple" /> | |
70 <output name="output" ftype="tabular" file="table0.tabular"> | |
71 <discovered_dataset designation="table1" ftype="tabular" file="table1.tabular" /> | |
72 </output> | |
73 </test> | |
74 </tests> | |
75 </tool> | 117 </tool> |