annotate optitype.xml @ 5:044f0a2e2a36 draft default tip

Uploaded
author jjohnson
date Tue, 08 Aug 2017 11:59:10 -0400
parents 111d2508ab15
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
1 <tool id="optitype" name="OptiType" version="1.2.1">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
2 <description>HLA genotyping predictions from NGS data</description>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
3 <requirements>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
4 <requirement type="package" version="1.2.1">optitype</requirement>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
5 </requirements>
5
044f0a2e2a36 Uploaded
jjohnson
parents: 4
diff changeset
6 <command detect_errors="aggressive">
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
7 <![CDATA[
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
8 #set $fastqs = []
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
9 #if str( $fastq_input.fastq_input_selector ) == "paired":
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
10 ln -s "${fastq_input.fastq_input1}" reads_1.fastq
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
11 && ln -s "${fastq_input.fastq_input2}" reads_2.fastq
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
12 #set $fastqs = ['reads_1.fastq','reads_2.fastq']
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
13 #elif str( $fastq_input.fastq_input_selector ) == "paired_collection":
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
14 ln -s "${fastq_input.fastq_input1.forward}" reads_1.fastq
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
15 && ln -s "${fastq_input.fastq_input1.reverse}" reads_2.fastq
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
16 #set $fastqs = ['reads_1.fastq','reads_2.fastq']
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
17 #elif str( $fastq_input.fastq_input_selector ) == "single":
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
18 ln -s "${fastq_input.fastq_input1}" reads.fastq
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
19 #set $fastqs = ['reads.fastq']
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
20 #end if
5
044f0a2e2a36 Uploaded
jjohnson
parents: 4
diff changeset
21 && RAZERS3=`which razers3`
044f0a2e2a36 Uploaded
jjohnson
parents: 4
diff changeset
22 && sed "s#path_to_razers3#\$RAZERS3#" '$optitype_config' | sed "s/threads=16/threads=\$GALAXY_SLOTS/" > config.ini
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
23 #set $input_fq = ' '.join($fastqs)
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
24 && OptiTypePipeline.py
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
25 $read_type --input ${' '.join($fastqs)}
2
61fc10014a9e Uploaded
jjohnson
parents: 1
diff changeset
26 #if str($beta) != '':
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
27 --beta $beta
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
28 #end if
2
61fc10014a9e Uploaded
jjohnson
parents: 1
diff changeset
29 #if str($enumerations) != '':
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
30 --enumerate $enumerations
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
31 #end if
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
32 --config "`pwd`/config.ini"
1
bd817c1fdd63 Uploaded
jjohnson
parents: 0
diff changeset
33 --outdir $outdir
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
34 && cp $outdir/*/*_coverage_plot.pdf $coverage_plot
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
35 && cp $outdir/*/*_result.tsv $result
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
36 ]]>
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
37 </command>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
38 <configfiles>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
39 <configfile name="optitype_config"><![CDATA[
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
40 [mapping]
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
41
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
42 # Absolute path to RazerS3 binary, and number of threads to use for mapping
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
43
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
44 razers3=path_to_razers3
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
45 threads=16
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
46
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
47 [ilp]
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
48
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
49 # A Pyomo-supported ILP solver. The solver must be globally accessible in the
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
50 # environment OptiType is run, so make sure to include it in PATH.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
51 # Note: this is NOT a path to the solver binary, but a keyword argument for
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
52 # Pyomo. Examples: glpk, cplex, cbc.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
53
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
54 solver=$solver
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
55 threads=1
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
56
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
57 [behavior]
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
58
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
59 # tempdir=/path/to/tempdir # we may enable this setting later. Not used now.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
60
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
61 # Delete intermediate bam files produced by RazerS3 after OptiType finished
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
62 # loading them. If you plan to re-analyze your samples with different settings
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
63 # disabling this option can be a time-saver, as you'll be able to pass the bam
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
64 # files to OptiType directly as input and spare the expensive read mapping
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
65 # step.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
66
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
67 deletebam=true
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
68
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
69 # In paired-end mode one might want to use reads with just one mapped end (e.g.,
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
70 # the other end falls outside the reference region). This setting allows the
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
71 # user to keep them with an optionally reduced weight. A value of 0 means they
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
72 # are discarded for typing, 0.2 means single reads are "worth" 20% of paired
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
73 # reads, and a value of 1 means they are treated as valuable as properly mapped
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
74 # read pairs. Note: unpaired reads will be reported on the result coverage plots
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
75 # for completeness, regardless of this setting.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
76
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
77 unpaired_weight=$unpaired_weight
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
78
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
79 # We call a read pair discordant if its two ends best-map to two disjoint sets
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
80 # of alleles. Such reads can be either omitted or either of their ends treated
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
81 # as unpaired hits. Note: discordant read pairs are reported on the coverage
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
82 # plots as unpaired reads, regardless of this setting.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
83
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
84 use_discordant=$use_discordant
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
85 ]]></configfile>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
86 </configfiles>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
87 <inputs>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
88 <conditional name="fastq_input">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
89 <param name="fastq_input_selector" type="select" label="Single or Paired-end reads" help="Select between paired and single end data">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
90 <option value="paired">Paired</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
91 <option value="single">Single</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
92 <option value="paired_collection">Paired Collection</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
93 </param>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
94 <when value="paired">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
95 <param name="fastq_input1" type="data" format="fastqsanger" label="Select first set of reads" help="Specify dataset with forward reads"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
96 <param name="fastq_input2" type="data" format="fastqsanger" label="Select second set of reads" help="Specify dataset with reverse reads"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
97 </when>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
98 <when value="single">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
99 <param name="fastq_input1" type="data" format="fastqsanger" label="Select fastq dataset" help="Specify dataset with single reads"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
100 </when>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
101 <when value="paired_collection">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
102 <param name="fastq_input1" format="fastqsanger" type="data_collection" collection_type="paired" label="Select a paired collection" help="See help section for an explanation of dataset collections"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
103 </when>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
104 </conditional>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
105 <param name="read_type" type="select" label="Nucleotide Type" help="">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
106 <option value="--rna">RNA</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
107 <option value="--dna">DNA</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
108 </param>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
109 <param name="beta" type="float" value="" min="0.0" max="0.1" optional="true" label="homozygosity beta" help="The beta value for for homozygosity detection (Leave blank for default: 0.009)"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
110 <param name="enumerations" type="integer" value="" min="1" max="5" optional="true" label="Enumerations" help="The number of enumerations (Leave blank for default: 1)"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
111 <param name="solver" type="select" label="ILP solver" help="">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
112 <option value="glpk">glpk</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
113 <!--
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
114 <option value="cbc">cbc</option>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
115 -->
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
116 </param>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
117 <param name="unpaired_weight" type="float" value="0" min="0.0" max="1.0" label="unpaired_weight">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
118 <help><![CDATA[
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
119 In paired-end mode one might want to use reads with just one mapped end (e.g.,
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
120 the other end falls outside the reference region). This setting allows the
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
121 user to keep them with an optionally reduced weight. A value of 0 means they
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
122 are discarded for typing, 0.2 means single reads are "worth" 20% of paired
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
123 reads, and a value of 1 means they are treated as valuable as properly mapped
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
124 read pairs. Note: unpaired reads will be reported on the result coverage plots
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
125 for completeness, regardless of this setting. ]]>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
126 </help>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
127 </param>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
128 <param name="use_discordant" type="boolean" truevalue="true" falsevalue="false" checked="false" label="use_discordant">
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
129 <help><![CDATA[
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
130 We call a read pair discordant if its two ends best-map to two disjoint sets
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
131 of alleles. Such reads can be either omitted or either of their ends treated
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
132 as unpaired hits. Note: discordant read pairs are reported on the coverage
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
133 plots as unpaired reads, regardless of this setting. ]]>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
134 </help>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
135 </param>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
136 <param name="outdir" type="hidden" value="output_dir"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
137 </inputs>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
138 <outputs>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
139 <data format="pdf" name="coverage_plot" label="${tool.name} on ${on_string} coverage_plot.pdf"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
140 <data format="tabular" name="result" label="${tool.name} on ${on_string} result.tsv"/>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
141 </outputs>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
142 <tests>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
143 <test>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
144 </test>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
145 </tests>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
146 <help>
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
147 <![CDATA[
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
148 **OptiType**
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
149 ============
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
150
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
151 OptiType_ is a novel HLA genotyping algorithm based on integer linear programming, capable of producing accurate 4-digit HLA genotyping predictions from NGS data by simultaneously selecting all major and minor HLA Class I alleles.
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
152
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
153 **INPUTS**
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
154
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
155 RNA or DNA sequences in fastq format.
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
156
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
157 **OPTIONS**
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
158
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
159 --beta <BETA_VALUE> The beta value for for homozygosity detection (see cited paper).
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
160 Default: 0.009. Handle with care.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
161 --enumerate <ENUMERATIONS> Number of enumerations.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
162 OptiType will output the optimal solution and the top N-1 suboptimal solutions in the results.
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
163 Default: 1
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
164
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
165
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
166 **OUTPUTS**
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
167
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
168 result.tsv A TAB-separated file of HLA genotyping predictions:
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
169
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
170 ::
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
171
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
172 A1 A2 B1 B2 C1 C2 Reads Objective
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
173 0 A*31:01 A*68:01 B*40:01 B*51:01 C*15:02 C*03:04 132 128.43599999999998
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
174
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
175
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
176 coverage_plot.pdf Plots of coverage of HLA genotyping predictions
3
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
177
4f78281c42ff Uploaded
jjohnson
parents: 2
diff changeset
178 .. _OptiType: https://github.com/FRED-2/OptiType
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
179 ]]>
4
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
180 </help>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
181 <citations>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
182 <citation type="doi">10.1093/bioinformatics/btu548</citation>
111d2508ab15 Uploaded
jjohnson
parents: 3
diff changeset
183 </citations>
0
887bc9c92c05 Uploaded
jjohnson
parents:
diff changeset
184 </tool>