comparison bcftools_annotate.xml @ 1:c511cd4b54e5 draft

Uploaded
author wrtz
date Thu, 14 Jan 2016 17:46:57 -0500
parents
children
comparison
equal deleted inserted replaced
0:4f0ad5b55c62 1:c511cd4b54e5
1 <tool id="bcftools_annotate" name="BCFtools annotate" version="1.0.0">
2 <description>Add or remove annotations</description>
3 <command>
4 #if str( $input_file_index ) != "None":
5 ln -s -f $input input_file.${input.ext} &amp;&amp;
6 ln -s -f $input_file_index input_file.${input.ext}.tbi &amp;&amp;
7 #end if
8 #if str( $annotations_cond.set_annotations ) == "True":
9 ln -s -f $annotations_cond.annotations annot_file.${annotations_cond.annotations.ext} &amp;&amp;
10 ln -s -f $annotations_cond.annotations_index annot_file.${annotations_cond.annotations.ext}.tbi &amp;&amp;
11 #end if
12 /Volumes/drive2/galaxy/dist/tools/bcftools/bcftools annotate
13 --output "${output_file}"
14 --output-type "${output_type}"
15 #if str( $regions_file ) != "None":
16 --regions-file "${regions_file}"
17 #end if
18 #if str( $annotations_cond.set_annotations ) == "True":
19 --annotations annot_file.${annotations_cond.annotations.ext}
20 #if str( $annotations_cond.columns ) != "":
21 --columns "${annotations_cond.columns}"
22 #end if
23 #if str( $annotations_cond.mark_sites_cond.set_mark_sites ) == "True":
24 --mark-sites
25 #if str( $annotations_cond.mark_sites_cond.present_or_absent ) == "present":
26 "+${annotations_cond.mark_sites_cond.new_tag}"
27 #else
28 "-${annotations_cond.mark_sites_cond.new_tag}"
29 #end if
30 #end if
31 #end if
32 #if str( $regions ) != "":
33 --regions "${regions}"
34 #end if
35 #if str( $samples_file ) != "None":
36 --samples-file "${samples_file}"
37 #end if
38 #if str( $samples ) != "":
39 --samples "${samples}"
40 #end if
41 #if str( $header_lines ) != "None":
42 --header-lines "${header_lines}"
43 #end if
44 #if str( $expr_cond.set_expr ) == "True":
45 #if str( $expr_cond.include_or_exclude ) == "include":
46 --include "${expr_cond.expr}"
47 #else
48 --exclude "${expr_cond.expr}"
49 #end if
50 #end if
51 #if str( $rename_chrs ) != "None":
52 --rename-chrs "${rename_chrs}"
53 #end if
54 #if str( $remove ) != "":
55 --remove "${remove}"
56 #end if
57
58 #if str( $input_file_index ) != "None":
59 input_file.${input.ext}
60 #else
61 $input
62 #end if
63 </command>
64 <inputs>
65 <param name="input" type="data" format="vcf,bcf,bgzip" label="VCF or BCF input file" help="Input file can optionally be compressed and indexed using Bgzip and Tabix Galaxy tools. In this case, select bgzipped file here and index below."/>
66 <param name="input_file_index" type="data" optional="true" label="Input file index" help="Tabix-generated index for input file. Run Tabix Galaxy tool on bgzipped input file to create index."/>
67 <param name="output_type" type="select" label="Output data type" help="-O">
68 <option value="v" selected="true">VCF</option>
69 <option value="b">BCF</option>
70 </param>
71 <conditional name="annotations_cond">
72 <param name="set_annotations" type="boolean" checked="False" label="Set annotation file" help="-a, -c, -m"/>
73 <when value="true">
74 <param name="annotations" type="data" label="Compressed annotation file" help="-a. Bgzip-compressed VCF/ BED/ tab-delimited file with annotations. Run Bgzip Galaxy tool to compress annotation file."/>
75 <param name="annotations_index" type="data" label="Compressed annotation file index" help="Tabix-generated index for annotation file. Run Tabix Galaxy tool on bgzipped annotation file to create index."/>
76 <param name="columns" type="text" label="Annotation file columns" help="-c. Comma-separated list of columns or tags to carry over from the annotation file." />
77
78 <conditional name="mark_sites_cond">
79 <param name="set_mark_sites" type="boolean" checked="False" label="Mark present/absent sites" help="-m. Annotate sites which are present or absent in the annotation file with a new INFO/TAG flag. Note: BCFtools has not implemented this yet for VCF files."/>
80 <when value="true">
81 <param name="present_or_absent" type="select" label="Mark present or absent sites">
82 <option value="present">Present</option>
83 <option value="absent">Absent</option>
84 </param>
85 <param name="new_tag" type="text" label="New INFO/TAG flag" />
86 </when>
87 </conditional>
88
89 </when>
90 </conditional>
91
92 <param name="regions_file" type="data" optional="true" label="Regions file" help="-R. Regions specified in a VCF, BED, or tab-delimited file with columns CHROM, POS, and, optionally, POS_TO."/>
93 <param name="regions" type="text" optional="True" label="Regions list" help="-r. Comma-separated list of regions. Format: chr|chr:pos|chr:from-to|chr:from-[,...]">
94 <sanitizer invalid_char="">
95 <valid initial="string.digits"><add value="CHRchr-:,"/> </valid>
96 </sanitizer>
97 </param>
98 <param name="samples_file" type="data" optional="true" label="Samples file" help="-S. File of sample names to include. One sample per line."/>
99 <param name="samples" type="text" optional="True" label="Samples list" help="-s. Comma-separated list of samples to include or exclude. (Excludes if prefixed with ^)" />
100 <param name="header_lines" type="data" optional="true" label="Header lines" help="-h. File containing lines to append to VCF header."/>
101 <conditional name="expr_cond">
102 <param name="set_expr" type="boolean" checked="False" label="Filter by expression" help="-i, -e. Include/ exclude sites for which expression is true. Must use valid expression."/>
103 <when value="true">
104 <param name="include_or_exclude" type="select" label="Include or exclude by expression">
105 <option value="include">Include</option>
106 <option value="exclude">Exclude</option>
107 </param>
108 <param name="expr" type="text" label="Expression">
109 <sanitizer invalid_char="">
110 <valid initial="string.letters,string.digits"><add value="~`!@#$%^&amp;*()-_=+[{]}\|;:'&quot;,&lt;.&gt;?/ " /> </valid>
111 </sanitizer>
112 </param>
113 </when>
114 </conditional>
115 <param name="rename_chrs" type="data" optional="true" label="Rename chromosomes" help="--rename-chrs. File containing chromosome renaming map, with &quot;old_name new_name\n&quot; pairs separated by whitespaces, each on a separate line."/>
116 <param name="remove" type="text" label="List of annotations to remove" help="-x. Comma-separated list of annotations to remove." />
117 </inputs>
118 <outputs>
119 <data name="output_file" format="vcf" label="${tool.name} on ${on_string}">
120 <change_format>
121 <when input="output_type" value="b" format="bcf" />
122 </change_format>
123 </data>
124 </outputs>
125 <help>
126 **About this tool**
127
128 **BCFtools annotate**: Add or remove annotations.
129
130 Please see https://samtools.github.io/bcftools/bcftools.html for more info on options.
131 </help>
132 </tool>