comparison kallisto_quant.xml @ 0:59a4c97b85d6 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/kallisto/ commit 3b54163c4f7daff76fcc589c4a9057bb03904380
author iuc
date Sat, 05 Aug 2017 04:02:28 -0400
parents
children 7a9158bb6f98
comparison
equal deleted inserted replaced
-1:000000000000 0:59a4c97b85d6
1 <?xml version="1.0"?>
2 <tool id="kallisto_quant" name="Kallisto quant" version="@VERSION@.0">
3 <description>- quantify abundances of RNA-Seq transcripts</description>
4 <macros>
5 <import>macros.xml</import>
6 </macros>
7 <expand macro="requirements" />
8 <command detect_errors="exit_code">
9 <![CDATA[
10 #if $reference_genome.reference_genome_source == "history":
11 ln -s '$reference_genome.reference' reference.fa &&
12 kallisto index reference.fa -i reference.kallisto &&
13 #set index_path = 'reference.kallisto'
14 #else:
15 #set index_path = $reference_genome.index.fields.path
16 #end if
17 kallisto quant -i '$index_path'
18 $bias --bootstrap-samples $bootstrap_samples --seed $seed $fusion $pseudobam
19 #if $pseudobam:
20 -o .
21 #else:
22 --threads \${GALAXY_SLOTS:-1}
23 -o .
24 #end if
25 #if str($single_paired.single_paired_selector) == 'single':
26 --single
27 #set $single_reads = "' '".join(str($single_paired.reads).split(','))
28 --fragment-length $single_paired.fragment_length
29 --sd $single_paired.sd
30 '$single_reads'
31 #else:
32 #if str($single_paired.collection.collection_selector) == 'datasets':
33 #set $forward_reads = str($single_paired.collection.forward).split(',')
34 #set $reverse_reads = str($single_paired.collection.reverse).split(',')
35 #else:
36 #set $forward_reads = [str($read.forward) for $read in $single_paired.collection.reads]
37 #set $reverse_reads = [str($read.reverse) for $read in $single_paired.collection.reads]
38 #end if
39 #set $tuplexed_reads = zip($forward_reads, $reverse_reads)
40 #set $multiplexed_reads = []
41 #for read_pair in $tuplexed_reads:
42 ${multiplexed_reads.extend([read for read in read_pair])}
43 #end for
44 #set $reads = "' '".join($multiplexed_reads)
45 '$reads'
46 #end if
47 #if $pseudobam:
48 | samtools sort -O bam -@ \${GALAXY_SLOTS:-1} -o '$pseudobam_output' -
49 #end if
50 && cat run_info.json
51 ]]>
52 </command>
53 <inputs>
54 <conditional name="reference_genome">
55 <param name="reference_genome_source" type="select" label="Reference genome for quantification">
56 <option value="indexed" selected="true">Use a built-in genome</option>
57 <option value="history">Use a genome from history</option>
58 </param>
59 <when value="indexed">
60 <param name="index" type="select" label="Select a reference genome" help="If your genome of interest is not listed, contact your Galaxy administrator">
61 <options from_data_table="kallisto_indexes">
62 <filter type="sort_by" column="2" />
63 <validator type="no_options" message="No genomes are available for the selected input dataset" />
64 </options>
65 </param>
66 </when>
67 <when value="history">
68 <param name="reference" type="data" format="fasta" label="FASTA reference genome" />
69 </when>
70 </conditional>
71 <conditional name="single_paired">
72 <param name="single_paired_selector" type="select" label="Single-end or paired reads">
73 <option value="single" selected="true">Single-end</option>
74 <option value="paired">Paired</option>
75 </param>
76 <when value="single">
77 <param name="reads" type="data" format="fastq" multiple="True" label="Reads in FASTQ format" />
78 <param name="fragment_length" argument="--fragment-length" type="integer" value="200" label="Average fragment length" help="Illumina typically produces reads of 180-200bp" />
79 <param argument="--sd" type="integer" value="20" label="Estimated standard deviation of fragment length" />
80 </when>
81 <when value="paired">
82 <conditional name="collection">
83 <param name="collection_selector" type="select" label="Collection or individual datasets">
84 <option value="datasets" selected="true">Individual files</option>
85 <option value="collection">Pair or list of pairs</option>
86 </param>
87 <when value="datasets">
88 <param name="forward" type="data" format="fastq" multiple="True" label="Forward reads" />
89 <param name="reverse" type="data" format="fastq" multiple="True" label="Reverse reads" />
90 </when>
91 <when value="collection">
92 <param name="reads" type="data_collection" format="fastq" collection_type="list:paired" label="Collection of reads" />
93 </when>
94 </conditional>
95 </when>
96 </conditional>
97 <param argument="--bias" type="boolean" truevalue="--bias" falsevalue="" label="Perform sequence based bias correction" />
98 <param name="bootstrap_samples" argument="--bootstrap-samples" type="integer" value="0" label="Number of bootstrap samples" help="default: 0" />
99 <param argument="--seed" type="integer" value="42" label="Seed for the bootstrap sampling" help="default: 42" />
100 <param argument="--fusion" type="boolean" truevalue="--fusion" falsevalue="" label="Search for fusions" help="for Pizzly" />
101 <param argument="--pseudobam" type="boolean" truevalue="--pseudobam" falsevalue="" label="Output pseudoalignments in BAM format" />
102 </inputs>
103 <outputs>
104 <data format="h5" name="abundance_h5" from_work_dir="abundance.h5" label="${tool.name} on ${on_string}: Abundances (HDF5)" />
105 <data format="tabular" name="abundance_tab" from_work_dir="abundance.tsv" label="${tool.name} on ${on_string}: Abundances (tabular)" />
106 <data format="bam" name="pseudobam_output" label="${tool.name} on ${on_string}: Pseudoalignments">
107 <filter>pseudobam</filter>
108 </data>
109 </outputs>
110 <tests>
111 <test>
112 <param name="reference_genome_source" value="history" />
113 <param name="reference" ftype="fasta" value="mm10_chrM.fa" />
114 <param name="single_paired_selector" value="paired" />
115 <param name="collection_selector" value="datasets" />
116 <param name="forward" ftype="fastq" value="mm10_chrM-1.f.fq,mm10_chrM-2.f.fq,mm10_chrM-3.f.fq,mm10_chrM-4.f.fq,mm10_chrM-5.f.fq" />
117 <param name="reverse" ftype="fastq" value="mm10_chrM-1.r.fq,mm10_chrM-2.r.fq,mm10_chrM-3.r.fq,mm10_chrM-4.r.fq,mm10_chrM-5.r.fq" />
118 <output name="abundance_tab" file="kallisto_quant_out1.tab" ftype="tabular" />
119 </test>
120 <test>
121 <param name="reference_genome_source" value="history" />
122 <param name="reference" ftype="fasta" value="mm10_chrM.fa" />
123 <param name="single_paired_selector" value="paired" />
124 <param name="collection_selector" value="collection" />
125 <param name="reads">
126 <collection type="list:paired">
127 <element name="p1">
128 <collection type="paired">
129 <element name="forward" value="mm10_chrM-1.f.fq" />
130 <element name="reverse" value="mm10_chrM-1.r.fq" />
131 </collection>
132 </element>
133 <element name="p2">
134 <collection type="paired">
135 <element name="forward" value="mm10_chrM-2.f.fq" />
136 <element name="reverse" value="mm10_chrM-2.r.fq" />
137 </collection>
138 </element>
139 <element name="p3">
140 <collection type="paired">
141 <element name="forward" value="mm10_chrM-3.f.fq" />
142 <element name="reverse" value="mm10_chrM-3.r.fq" />
143 </collection>
144 </element>
145 <element name="p4">
146 <collection type="paired">
147 <element name="forward" value="mm10_chrM-4.f.fq" />
148 <element name="reverse" value="mm10_chrM-4.r.fq" />
149 </collection>
150 </element>
151 <element name="p5">
152 <collection type="paired">
153 <element name="forward" value="mm10_chrM-5.f.fq" />
154 <element name="reverse" value="mm10_chrM-5.r.fq" />
155 </collection>
156 </element>
157 </collection>
158 </param>
159 <output name="abundance_tab" file="kallisto_quant_out2.tab" ftype="tabular" />
160 </test>
161 <test>
162 <param name="reference_genome_source" value="history" />
163 <param name="reference" ftype="fasta" value="mm10_chrM.fa" />
164 <param name="single_paired_selector" value="single" />
165 <param name="collection_selector" value="collection" />
166 <param name="reads" ftype="fastq" value="mm10_chrM-1.f.fq,mm10_chrM-2.f.fq,mm10_chrM-3.f.fq,mm10_chrM-4.f.fq,mm10_chrM-5.f.fq" />
167 <output name="abundance_tab" file="kallisto_quant_out3.tab" ftype="tabular" />
168 </test>
169 <test>
170 <param name="reference_genome_source" value="history" />
171 <param name="reference" ftype="fasta" value="felCat8_chrM.fa" />
172 <param name="single_paired_selector" value="paired" />
173 <param name="collection_selector" value="datasets" />
174 <param name="pseudobam" value="true" />
175 <param name="forward" ftype="fastq" value="felCat8_chrM_F.fq" />
176 <param name="reverse" ftype="fastq" value="felCat8_chrM_R.fq" />
177 <output name="abundance_tab" file="kallisto_quant_out4.tab" ftype="tabular" />
178 <output name="pseudobam_output" file="kallisto_quant_out4.bam" ftype="bam" />
179 </test>
180 <test>
181 <param name="reference_genome_source" value="cached" />
182 <param name="single_paired_selector" value="paired" />
183 <param name="collection_selector" value="datasets" />
184 <param name="pseudobam" value="true" />
185 <param name="forward" ftype="fastq" dbkey="sacCer2" value="sacCer2_chrM_F.fq" />
186 <param name="reverse" ftype="fastq" dbkey="sacCer2" value="sacCer2_chrM_R.fq" />
187 <output name="abundance_tab" file="kallisto_quant_out5.tab" ftype="tabular" />
188 <output name="pseudobam_output" file="kallisto_quant_out5.bam" ftype="bam" />
189 </test>
190 </tests>
191 <help>
192 <![CDATA[
193 kallisto is a program for quantifying abundances of transcripts from RNA-Seq data, or more generally of target sequences using high-throughput sequencing reads. It is based on the novel idea of pseudoalignment for rapidly determining the compatibility of reads with targets, without the need for alignment. On benchmarks with standard RNA-Seq data, kallisto can quantify 30 million human reads in less than 3 minutes on a Mac desktop computer using only the read sequences and a transcriptome index that itself takes less than 10 minutes to build. Pseudoalignment of reads preserves the key information needed for quantification, and kallisto is therefore not only fast, but also as accurate as existing quantification tools. In fact, because the pseudoalignment procedure is robust to errors in the reads, in many benchmarks kallisto significantly outperforms existing tools.
194 ]]>
195 </help>
196 <expand macro="citations" />
197 </tool>