|
0
|
1 <tool id="bowtieForSmallRNA" name="sRbowtie" version="1.1.0">
|
|
|
2 <description>for FASTA small reads</description>
|
|
|
3 <requirements>
|
|
|
4 <requirement type="package" version="0.12.7">bowtie</requirement>
|
|
|
5 <requirement type="package" version="0.1.18">samtools</requirement>
|
|
|
6 </requirements>
|
|
|
7 <parallelism method="basic"></parallelism>
|
|
|
8 <command interpreter="python"> sRbowtie.py --input $input
|
|
|
9 --method $method
|
|
|
10 --v-mismatches $v_mismatches
|
|
|
11 --output-format $output_format
|
|
|
12 --output $output
|
|
|
13 --index-from $refGenomeSource.genomeSource
|
|
|
14 ## the very source of the index (indexed or fasta file)
|
|
|
15 --index-source
|
|
|
16 #if $refGenomeSource.genomeSource == "history":
|
|
|
17 $refGenomeSource.ownFile
|
|
|
18 #else:
|
|
|
19 $refGenomeSource.index.fields.path
|
|
|
20 #end if
|
|
|
21 --aligned $aligned
|
|
|
22 --unaligned $unaligned
|
|
|
23 --num-threads \${GALAXY_SLOTS:-4} ## number of processors to be handled by bowtie
|
|
|
24 </command>
|
|
|
25 <inputs>
|
|
|
26 <param name="input" type="data" format="fasta" label="Input fasta file: reads clipped from their adapter" help="Only with clipped, raw fasta files"/>
|
|
|
27 <!-- which method will be used -->
|
|
|
28 <param name="method" type="select" label="What kind of matching do you want to do?" help="bowtie parameters adjusted to the type of matching. RNA option match to only one strand">
|
|
|
29 <option value="RNA">Match on sense strand RNA reference index, multiple mappers randomly matched at a single position</option>
|
|
|
30 <option value="unique">Match unique mappers on DNA reference index</option>
|
|
|
31 <option value="multiple" selected="true">Match on DNA, multiple mappers randomly matched at a single position</option>
|
|
|
32 <option value="k_option">Match on DNA as fast as possible, without taking care of mapping issues (for raw annotation of reads)</option>
|
|
|
33 <option value="n_option">Match on DNA - RNAseq mode (-n bowtie option)</option>
|
|
|
34 <option value="a_option">Match and report all valid alignments</option>
|
|
|
35 </param>
|
|
|
36 <!-- END of which method will be used -->
|
|
|
37 <param name="v_mismatches" type="select" label="Number of mismatches allowed" help="specify the -v bowtie option">
|
|
|
38 <option value="0">0</option>
|
|
|
39 <option value="1" selected="true">1</option>
|
|
|
40 <option value="2">2</option>
|
|
|
41 <option value="3">3</option>
|
|
|
42 </param>
|
|
|
43 <!-- bowtie index selection -->
|
|
|
44 <conditional name="refGenomeSource">
|
|
|
45 <param name="genomeSource" type="select" label="Will you select a reference genome from your history or use a built-in index?" help="Built-ins were indexed using default options">
|
|
|
46 <option value="indexed">Use a built-in index</option>
|
|
|
47 <option value="history">Use one from the history</option>
|
|
|
48 </param>
|
|
|
49 <when value="indexed">
|
|
|
50 <param name="index" type="select" label="Select a DNA reference index" help="if your genome of interest is not listed - contact GED team">
|
|
|
51 <options from_data_table="bowtie_indexes">
|
|
|
52 <!-- <filter type="sort_by" column="2" />
|
|
|
53 <validator type="no_options" message="No indexes are available" /> -->
|
|
|
54 </options>
|
|
|
55 </param>
|
|
|
56 </when>
|
|
|
57 <when value="history">
|
|
|
58 <param name="ownFile" type="data" format="fasta" label="Select a fasta file, to serve as index reference" />
|
|
|
59 </when>
|
|
|
60 </conditional>
|
|
|
61 <!-- END bowtie index selection -->
|
|
|
62 <param name="output_format" type="select" label="Select output format" help="Note that the BAM will be viewable in trackster only if you choose a full genome referenced for Trackster usage. see the doc below">
|
|
|
63 <option value="tabular" select="true">tabular</option>
|
|
|
64 <option value="sam">sam</option>
|
|
|
65 <option value="bam">bam</option>
|
|
|
66 </param>
|
|
|
67 <param name="additional_fasta" type="select" label="additional fasta output" help="to get aligned and unaligned reads in fasta format">
|
|
|
68 <option value="No" select="true">No</option>
|
|
|
69 <option value="al">aligned</option>
|
|
|
70 <option value="unal">unaligned</option>
|
|
|
71 <option value="al_and_unal">both aligned and unaligned</option>
|
|
|
72 </param>
|
|
|
73 </inputs>
|
|
|
74 <outputs>
|
|
|
75 <data format="tabular" name="output" label="Bowtie Output">
|
|
|
76 <change_format>
|
|
|
77 <when input="output_format" value="sam" format="sam" />
|
|
|
78 <when input="output_format" value="bam" format="bam" />
|
|
|
79 </change_format>
|
|
|
80 <!-- Set metadata based on reference genome -->
|
|
|
81 <actions>
|
|
|
82 <conditional name="refGenomeSource.genomeSource">
|
|
|
83 <when value="indexed">
|
|
|
84 <action type="metadata" name="dbkey">
|
|
|
85 <option type="from_data_table" name="bowtie_indexes" column="1" offset="0">
|
|
|
86 <filter type="param_value" column="0" value="#" compare="startswith" keep="False"/>
|
|
|
87 <filter type="param_value" ref="refGenomeSource.index" column="0"/>
|
|
|
88 </option>
|
|
|
89 </action>
|
|
|
90 </when>
|
|
|
91 <when value="history">
|
|
|
92 <action type="metadata" name="dbkey">
|
|
|
93 <option type="from_param" name="refGenomeSource.ownFile" param_attribute="dbkey" />
|
|
|
94 </action>
|
|
|
95 </when>
|
|
|
96 </conditional>
|
|
|
97 </actions>
|
|
|
98 </data>
|
|
|
99 <data format="fasta" name="aligned" label="Matched reads">
|
|
|
100 <filter>additional_fasta == "al" or additional_fasta == "al_and_unal"</filter>
|
|
|
101 </data>
|
|
|
102 <data format="fasta" name="unaligned" label ="Unmatched reads">
|
|
|
103 <filter>additional_fasta == "unal" or additional_fasta == "al_and_unal"</filter>
|
|
|
104 </data>
|
|
|
105 </outputs>
|
|
|
106
|
|
|
107 <test>
|
|
|
108 <param name="genomeSource" value="indexed" />
|
|
|
109 <param name="index" value="/home/galaxy/galaxy-dist/bowtie/Dmel/dmel-all-chromosome-r5.49" />
|
|
|
110 <param name="method" value="multiple" />
|
|
|
111 <param name="input" ftype="fasta" value="sRbowtie.fa" />
|
|
|
112 <param name="v_mismatches" value="1" />
|
|
|
113 <param name="output_format" value="tabular" />
|
|
|
114 <output name="output" ftype="tabular" value="sRbowtie.out" />
|
|
|
115 <output name="aligned" value="None" />
|
|
|
116 <output name="unaligned" value="None" />
|
|
|
117 </test>
|
|
|
118
|
|
|
119 <help>
|
|
|
120
|
|
|
121 **What it does**
|
|
|
122
|
|
|
123 Bowtie_ is a short read aligner designed to be ultrafast and memory-efficient. It is developed by Ben Langmead and Cole Trapnell. Please cite: Langmead B, Trapnell C, Pop M, Salzberg SL. Ultrafast and memory-efficient alignment of short DNA sequences to the human genome. Genome Biology 10:R25.
|
|
|
124
|
|
|
125 .. _Bowtie: http://bowtie-bio.sourceforge.net/index.shtml
|
|
|
126
|
|
|
127 A generic "Map with Bowtie for Illumina" Galaxy tool is available in the main Galaxy distribution.
|
|
|
128
|
|
|
129 However, this Bowtie wrapper tool only takes FASTQ files as inputs.
|
|
|
130
|
|
|
131 The sRbowtie wrapper specifically works with short reads FASTA inputs (-v bowtie mode)
|
|
|
132
|
|
|
133 ------
|
|
|
134
|
|
|
135 **OPTIONS**
|
|
|
136
|
|
|
137 .. class:: infomark
|
|
|
138
|
|
|
139 This script uses Bowtie to match reads on a reference index.
|
|
|
140
|
|
|
141 Depending on the type of matching, different bowtie options are used:
|
|
|
142
|
|
|
143 **Match on sense strand RNA reference index, multiple mappers randomly matched at a single position**
|
|
|
144
|
|
|
145 Match on RNA reference, SENSE strand, randomly attributing multiple mapper to target with least mismatches, the polarity column is suppressed in the bowtie tabular report:
|
|
|
146
|
|
|
147 *-v [0,1,2,3] -M 1 --best --strata -p 12 --norc --suppress 2,6,7,8*
|
|
|
148
|
|
|
149 **Match unique mappers on DNA reference index**
|
|
|
150
|
|
|
151 Match ONLY unique mappers on DNA reference index
|
|
|
152
|
|
|
153 *-v [0,1,2,3] -m 1 -p 12 --suppress 6,7,8*
|
|
|
154
|
|
|
155 Note that using this option with -v values other than 0 is questionnable...
|
|
|
156
|
|
|
157 **Match on DNA, multiple mappers randomly matched at a single position**
|
|
|
158
|
|
|
159 Match multiple mappers, randomly attributing multiple mapper to target with least mismatches, number of mismatch allowed specified by -v option:
|
|
|
160
|
|
|
161 *-v [0,1,2,3] -M 1 --best --strata -p 12 --suppress 6,7,8*
|
|
|
162
|
|
|
163 **Match on DNA as fast as possible, without taking care of mapping issues (for raw annotation of reads)**
|
|
|
164
|
|
|
165 Match with highest speed, not guaranteeing best hit for speed gain:
|
|
|
166
|
|
|
167 *-v [0,1,2,3] -k 1 --best -p 12 --suppress 6,7,8*
|
|
|
168
|
|
|
169
|
|
|
170 -----
|
|
|
171
|
|
|
172 **Input formats**
|
|
|
173
|
|
|
174 .. class:: warningmark
|
|
|
175
|
|
|
176 *The only accepted format for the script is a raw fasta list of reads, clipped from their adapter*
|
|
|
177
|
|
|
178 -----
|
|
|
179
|
|
|
180 **OUTPUTS**
|
|
|
181
|
|
|
182 If you choose tabular as the output format, you will obtain the matched reads in standard bowtie output format, having the following columns::
|
|
|
183
|
|
|
184 Column Description
|
|
|
185 -------- --------------------------------------------------------
|
|
|
186 1 FastaID fasta identifier
|
|
|
187 2 polarity + or - depending whether the match was reported on the forward or reverse strand
|
|
|
188 3 target name of the matched target
|
|
|
189 4 Offset O-based coordinate of the miR on the miRBase pre-miR sequence
|
|
|
190 5 Seq sequence of the matched Read
|
|
|
191
|
|
|
192 If you choose SAM, you will get the output in unordered SAM format.
|
|
|
193
|
|
|
194 .. class:: warningmark
|
|
|
195
|
|
|
196 if you choose BAM, the output will be in sorted BAM format.
|
|
|
197 To be viewable in Trackster, several condition must be fulfilled:
|
|
|
198
|
|
|
199 .. class:: infomark
|
|
|
200
|
|
|
201 Reads must have been matched to a genome whose chromosome names are compatible with Trackster genome indexes
|
|
|
202
|
|
|
203 .. class:: infomark
|
|
|
204
|
|
|
205 the database/Build (dbkey) which is indicated for the dataset (Pencil - Database/Build field) must match a Trackster genome index.
|
|
|
206
|
|
|
207 Please contact the Galaxy instance administrator if your genome is not referenced
|
|
|
208
|
|
|
209 **Matched and unmatched fasta reads can be retrieved, for further analyses**
|
|
|
210
|
|
|
211 </help>
|
|
|
212 </tool>
|