Skip to content

Commit bec16bc

Browse files
authored
Add pVACbind tool (#809)
* Initial commit of pVACbind tool. * Try automated tests with smaller alleles_macros.xml file. * Lower profile version of pvacbind to 24.2. * Correct output collection name in test. Add debugging output. * Remove example test output files. Remove debugging output. * Revert "Try automated tests with smaller alleles_macros.xml file." This reverts commit 7de4764. * Add back alleles macro split into smaller mhci and mhcii files. * Add details to help section. * Capitalize label. * Keep only most relevant citation. * Correct remote_repository_url.
1 parent 3c55835 commit bec16bc

10 files changed

Lines changed: 19496 additions & 0 deletions

File tree

tools/pvactools/.shed.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
categories: [Sequence Analysis]
2+
description: A Cancer Immunotherapy Tools Suite
3+
homepage_url: https://pvactools.readthedocs.io/en/latest/index.html
4+
long_description: An end-to-end solution for neoantigen characterization that supports identification of altered peptides from different mechanisms, including point mutations, in-frame and frameshift insertions and deletions, and gene fusions.
5+
name: pvactools
6+
owner: galaxyp
7+
remote_repository_url: https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/pvactools

tools/pvactools/alleles_macros.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<macros>
2+
<xml name="allele_list">
3+
<param name="allele_select" type="select" multiple="true" optional="false" label="Alleles">
4+
<expand macro="mhci_allele_list"/>
5+
<expand macro="mhcii_allele_list"/>
6+
</param>
7+
</xml>
8+
</macros>

tools/pvactools/mhci_alleles_macros.xml

Lines changed: 12168 additions & 0 deletions
Large diffs are not rendered by default.

tools/pvactools/mhcii_alleles_macros.xml

Lines changed: 6930 additions & 0 deletions
Large diffs are not rendered by default.

tools/pvactools/pvacbind.xml

Lines changed: 277 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,277 @@
1+
<tool id="pvacbind" name="pVACbind" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="24.2">
2+
<description>
3+
The pVACbind tool of the pVACtools suite.
4+
</description>
5+
6+
<macros>
7+
<import>mhci_alleles_macros.xml</import>
8+
<import>mhcii_alleles_macros.xml</import>
9+
<import>alleles_macros.xml</import>
10+
<import>shared_macros.xml</import>
11+
</macros>
12+
13+
<requirements>
14+
<container type="docker">griffithlab/pvactools:6.0.2</container>
15+
</requirements>
16+
17+
<command><![CDATA[
18+
@PREPARE_ALLELES_INPUT@
19+
mkdir outputs &&
20+
pvacbind run
21+
'$input_file'
22+
'$sample_name'
23+
#if $alleles.allelesrc == 'entry'
24+
'$alleles_input'
25+
#else
26+
\$(tr '\n' ',' < '$alleles.allele_file')
27+
#end if
28+
#for $algorithm in $algorithms
29+
$algorithm
30+
#end for
31+
outputs
32+
--class-i-epitope-length $class_i_epitope_length
33+
--class-ii-epitope-length $class_ii_epitope_length
34+
#if $binding_threshold
35+
--binding-threshold $binding_threshold
36+
#end if
37+
#if $percentile_threshold_conditional.use_percentile_threshold == "true"
38+
--percentile-threshold $percentile_threshold_conditional.percentile_threshold
39+
--percentile-threshold-strategy $percentile_threshold_conditional.percentile_threshold_strategy
40+
#end if
41+
#if $allele_specific_binding_thresholds
42+
--allele-specific-binding-thresholds
43+
#end if
44+
#if $top_score_metric != 'default'
45+
--top-score-metric $top_score_metric
46+
#end if
47+
#if $top_score_metric2 != 'default'
48+
--top-score-metric2 $top_score_metric2
49+
#end if
50+
#if $net_chop_method != 'default'
51+
--net-chop-method $net_chop_method
52+
#end if
53+
#if $netmhc_stab
54+
--netmhc-stab
55+
#end if
56+
#if $net_chop_threshold
57+
--net-chop-threshold $net_chop_threshold
58+
#end if
59+
#if $problematic_amino_acids != ''
60+
--problematic-amino-acids '$problematic_amino_acids'
61+
#end if
62+
#if $run_reference_proteome_similarity
63+
--run-reference-proteome-similarity
64+
#end if
65+
#if $blastp_db != 'default'
66+
--blastp-db $blastp_db
67+
#end if
68+
#if $peptide_fasta
69+
--peptide-fasta '$peptide_fasta'
70+
#end if
71+
#if $add_sample_name_reports_column
72+
--additional-report-columns sample_name
73+
#end if
74+
#if $exclude_NAs
75+
--exclude-NAs
76+
#end if
77+
#if $aggregate_inclusion_binding_threshold
78+
--aggregate-inclusion-binding-threshold $aggregate_inclusion_binding_threshold
79+
#end if
80+
#if $aggregate_inclusion_count_limit
81+
--aggregate-inclusion-count-limit $aggregate_inclusion_count_limit
82+
#end if
83+
]]></command>
84+
85+
<inputs>
86+
<expand macro="allele_inputs"/>
87+
<param name="input_file" type="data" format="fasta" optional="false" label="Input File"/>
88+
<param name="sample_name" type="text" optional="false" label="Sample Name">
89+
<validator type="regex">^[a-zA-Z0-9_-]+$</validator>
90+
</param>
91+
<param name="algorithms" type="select" multiple="true" optional="false" label="Algorithm">
92+
<option value="BigMHC_EL">BigMHC_EL</option>
93+
<option value="BigMHC_IM">BigMHC_IM</option>
94+
<option value="DeepImmuno">DeepImmuno</option>
95+
<option value="MHCflurry">MHCflurry</option>
96+
<option value="MHCflurryEL">MHCflurryEL</option>
97+
<option value="MHCnuggetsI">MHCnuggetsI</option>
98+
<option value="MHCnuggetsII">MHCnuggetsII</option>
99+
<option value="NNalign">NNalign</option>
100+
<option value="NetMHC">NetMHC</option>
101+
<option value="NetMHCIIpan">NetMHCIIpan</option>
102+
<option value="NetMHCIIpanEL">NetMHCIIpanEL</option>
103+
<option value="NetMHCcons">NetMHCcons</option>
104+
<option value="NetMHCpan">NetMHCpan</option>
105+
<option value="NetMHCpanEL">NetMHCpanEL</option>
106+
<option value="PickPocket">PickPocket</option>
107+
<option value="SMM">SMM</option>
108+
<option value="SMMPMBEC">SMMPMBEC</option>
109+
<option value="SMMalign">SMMalign</option>
110+
<option value="all">all</option>
111+
<option value="all_class_i">all_class_i</option>
112+
<option value="all_class_ii">all_class_ii</option>
113+
</param>
114+
<param argument="--class-i-epitope-length" type="select" multiple="true" optional="false" label="Class I Epitope Length">
115+
<option value="8" selected="true">8</option>
116+
<option value="9" selected="true">9</option>
117+
<option value="10" selected="true">10</option>
118+
<option value="11" selected="true">11</option>
119+
<option value="12">12</option>
120+
<option value="13">13</option>
121+
<option value="14">14</option>
122+
<option value="15">15</option>
123+
</param>
124+
<param argument="--class-ii-epitope-length" type="select" multiple="true" optional="false" label="Class II Epitope Length">
125+
<option value="11">11</option>
126+
<option value="12" selected="true">12</option>
127+
<option value="13" selected="true">13</option>
128+
<option value="14" selected="true">14</option>
129+
<option value="15" selected="true">15</option>
130+
<option value="16" selected="true">16</option>
131+
<option value="17" selected="true">17</option>
132+
<option value="18" selected="true">18</option>
133+
<option value="19">19</option>
134+
<option value="20">20</option>
135+
<option value="21">21</option>
136+
<option value="22">22</option>
137+
<option value="23">23</option>
138+
<option value="24">24</option>
139+
<option value="25">25</option>
140+
<option value="26">26</option>
141+
<option value="27">27</option>
142+
<option value="28">28</option>
143+
<option value="29">29</option>
144+
<option value="30">30</option>
145+
</param>
146+
<param argument="--binding-threshold" type="integer" value="" optional="true" label="Binding Threshold"/>
147+
<conditional name="percentile_threshold_conditional">
148+
<param name="use_percentile_threshold" type="select" label="Use Percentile Threshold">
149+
<option value="false" selected="true">No</option>
150+
<option value="true">Yes</option>
151+
</param>
152+
<when value="true">
153+
<param argument="--percentile-threshold" type="integer" optional="false" label="Percentile Threshold"/>
154+
<param argument="--percentile-threshold-strategy" type="select" label="Percentile Threshold Strategy">
155+
<option value="conservative" selected="true">conservative</option>
156+
<option value="exploratory">exploratory</option>
157+
</param>
158+
</when>
159+
<when value="false">
160+
</when>
161+
</conditional>
162+
<param argument="--allele-specific-binding-thresholds" type="boolean" checked="false" label="Use allele-specific binding thresholds"/>
163+
<param argument="--top-score-metric" type="select" label="Top Score Metric">
164+
<option value="default" selected="true">Use default</option>
165+
<option value="lowest">lowest</option>
166+
<option value="median">median</option>
167+
</param>
168+
<param argument="--top-score-metric2" type="select" label="Top Score Metric 2">
169+
<option value="default" selected="true">Use default</option>
170+
<option value="ic50">ic50</option>
171+
<option value="percentile">percentile</option>
172+
</param>
173+
<param argument="--net-chop-method" type="select" label="NetChop Prediction Method">
174+
<option value="default" selected="true">Use default</option>
175+
<option value="None">None</option>
176+
<option value="cterm">C term 3.0</option>
177+
<option value="20s">20S 3.0</option>
178+
</param>
179+
<param argument="--netmhc-stab" type="boolean" checked="false" label="Run NetMHCStabPan after all filtering and add stability predictions to predicted epitopes"/>
180+
<param argument="--net-chop-threshold" type="float" value="" optional="true" label="NetChop Prediction Threshold"/>
181+
<param argument="--problematic-amino-acids" type="text" value="" optional="true" label="Problematic Amino Acids">
182+
<validator type="regex">^@PROBLEM_AA_ARG_RE@$</validator>
183+
</param>
184+
<param argument="--run-reference-proteome-similarity" type="boolean" checked="false" label="Run reference proteome similarity"/>
185+
<param argument="--blastp-db" type="select" label="BlastP Database">
186+
<option value="default" selected="true">Use default</option>
187+
<option value="refseq_select_prot">refseq_select_prot</option>
188+
<option value="refseq_protein">refseq_protein</option>
189+
</param>
190+
<param argument="--peptide-fasta" type="data" format="fasta" optional="true" label="Peptide Fasta" help="When running the reference proteome similarity step, use this reference peptide FASTA file to find matches instead of blastp"/>
191+
<param name="add_sample_name_reports_column" argument="--additional-report-columns" type="boolean" checked="false" label="Add sample name reports column"/>
192+
<param argument="--exclude-NAs" type="boolean" checked="false" label="Exclude NA values from the filtered output"/>
193+
<param argument="--aggregate-inclusion-binding-threshold" type="integer" value="" optional="true" label="Aggregate Inclusion Binding Threshold"/>
194+
<param argument="--aggregate-inclusion-count-limit" type="integer" value="" optional="true" label="Aggregate Inclusion Binding Threshold"/>
195+
</inputs>
196+
197+
<outputs>
198+
<collection name="mhc_class_i_outputs" type="list" label="MHC Class I Outputs" >
199+
<discover_datasets pattern="(?P&lt;designation&gt;.+\.tsv)" ext="tabular" directory="outputs/MHC_Class_I"/>
200+
</collection>
201+
<collection name="mhc_class_ii_outputs" type="list" label="MHC Class II Outputs" >
202+
<discover_datasets pattern="(?P&lt;designation&gt;.+\.tsv)" ext="tabular" directory="outputs/MHC_Class_II"/>
203+
</collection>
204+
<collection name="combined_outputs" type="list" label="Combined Outputs" >
205+
<discover_datasets pattern="(?P&lt;designation&gt;.+\.tsv)" ext="tabular" directory="outputs/combined"/>
206+
</collection>
207+
</outputs>
208+
209+
<tests>
210+
<test expect_num_outputs="3">
211+
<param name="input_file" value="mhci/inputs/test.fasta" ftype="fasta"/>
212+
<param name="alleles|allele_file" value="mhci/inputs/test_alleles.txt" ftype="fasta"/>
213+
<param name="sample_name" value="pVACbind_mhci_test"/>
214+
<param name="algorithms" value="all"/>
215+
<param name="class_i_epitope_length" value="9,10,11"/>
216+
<param name="class_ii_epitope_length" value="12"/>
217+
<output_collection name="mhc_class_i_outputs" type="list">
218+
<element name="pVACbind_mhci_test.MHC_I.all_epitopes.aggregated.tsv" ftype="tabular">
219+
<assert_contents>
220+
<has_text text="ID&#x9;A*02:01&#x9;B*15:11&#x9;C*01:02&#x9;C*03:03&#x9;C*03:04"/>
221+
</assert_contents>
222+
</element>
223+
<element name="pVACbind_mhci_test.MHC_I.all_epitopes.tsv" ftype="tabular">
224+
<assert_contents>
225+
<has_text text="Mutation&#x9;HLA Allele&#x9;Sub-peptide Position&#x9;Epitope Seq"/>
226+
</assert_contents>
227+
</element>
228+
<element name="pVACbind_mhci_test.MHC_I.filtered.tsv" ftype="tabular">
229+
<assert_contents>
230+
<has_text text="Mutation&#x9;HLA Allele&#x9;Sub-peptide Position&#x9;Epitope Seq"/>
231+
</assert_contents>
232+
</element>
233+
</output_collection>
234+
</test>
235+
<test expect_num_outputs="3">
236+
<param name="input_file" value="mhcii/inputs/test.fasta" ftype="fasta"/>
237+
<param name="alleles|allele_file" value="mhcii/inputs/test_alleles.txt" ftype="fasta"/>
238+
<param name="sample_name" value="pVACbind_mhcii_test"/>
239+
<param name="algorithms" value="all"/>
240+
<param name="class_i_epitope_length" value="9"/>
241+
<param name="class_ii_epitope_length" value="12,13,14,15,16,17,18"/>
242+
<output_collection name="mhc_class_ii_outputs" type="list">
243+
<element name="pVACbind_mhcii_test.MHC_II.all_epitopes.aggregated.tsv" ftype="tabular">
244+
<assert_contents>
245+
<has_text text="ID&#x9;DPA1*01:03-DPB1*02:02&#x9;DQA1*01:01-DQB1*02:02&#x9;DRB1*01:02&#x9;DRB1*01:09"/>
246+
</assert_contents>
247+
</element>
248+
<element name="pVACbind_mhcii_test.MHC_II.all_epitopes.tsv" ftype="tabular">
249+
<assert_contents>
250+
<has_text text="Mutation&#x9;HLA Allele&#x9;Sub-peptide Position&#x9;Epitope Seq"/>
251+
</assert_contents>
252+
</element>
253+
<element name="pVACbind_mhcii_test.MHC_II.filtered.tsv" ftype="tabular">
254+
<assert_contents>
255+
<has_text text="Mutation&#x9;HLA Allele&#x9;Sub-peptide Position&#x9;Epitope Seq"/>
256+
</assert_contents>
257+
</element>
258+
</output_collection>
259+
</test>
260+
</tests>
261+
262+
<help><![CDATA[
263+
**pVACbind**
264+
265+
pVACbind, one component of the pVACtools_ software suite, identifies and prioritizes neoantigens in a FASTA file.
266+
267+
Required inputs are an input FASTA file, a sample name to be used in generated outputs, a list of alleles,
268+
epitope lengths, and finally a selection of epitope prediction algorithms.
269+
270+
Further usage details may be found in the pVACbind documentation_.
271+
272+
.. _pVACtools: https://pvactools.readthedocs.io/en/latest/index.html
273+
.. _documentation: https://pvactools.readthedocs.io/en/latest/pvacbind/run.html
274+
]]></help>
275+
276+
<expand macro="citations"/>
277+
</tool>

tools/pvactools/shared_macros.xml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<macros>
2+
<token name="@TOOL_VERSION@">6.0.2</token>
3+
<token name="@VERSION_SUFFIX@">0</token>
4+
<token name="@AA_RE@">[ACDEFGHIKLMNPQRSTVWY]</token>
5+
<token name="@PROBLEM_AA_RE@">(@AA_RE@+|@AA_RE@:-?\d+)</token>
6+
<token name="@PROBLEM_AA_ARG_RE@">@PROBLEM_AA_RE@(,@PROBLEM_AA_RE@)*</token>
7+
<token name="@PREPARE_ALLELES_INPUT@"><![CDATA[
8+
#if $alleles.allelesrc == 'entry'
9+
#set $alleles_input = ''
10+
#if $alleles.allele_text != ''
11+
#set $alleles_input = ','.join(str($alleles.allele_text).strip().split())
12+
#end if
13+
14+
#if $alleles.allele_select != 'None'
15+
#set $select_alleles = ','.join(str($alleles.allele_select).strip().split())
16+
#if $alleles_input == ''
17+
#set $alleles_input = $select_alleles
18+
#else
19+
#set $alleles_input = ','.join([$alleles_input, $select_alleles])
20+
#end if
21+
#end if
22+
#end if
23+
]]></token>
24+
<xml name="allele_inputs">
25+
<conditional name="alleles">
26+
<param name="allelesrc" type="select" label="Alleles">
27+
<option value="history">From history</option>
28+
<option value="entry">Entered</option>
29+
</param>
30+
<when value="history">
31+
<param name="allele_file" type="data" format="txt,tabular,tsv" label="Alleles file">
32+
<help>The dataset should have one allele per line.</help>
33+
</param>
34+
</when>
35+
<when value="entry">
36+
<param name="allele_text" type="text" label="Alleles" optional="true">
37+
<help>Enter alleles separated by white space.</help>
38+
</param>
39+
<expand macro="allele_list" />
40+
</when>
41+
</conditional>
42+
</xml>
43+
<xml name="citations">
44+
<citations>
45+
<citation type="doi">10.1158/2326-6066.CIR-19-0401</citation>
46+
<yield />
47+
</citations>
48+
</xml>
49+
</macros>
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
>generic|STRG.16327.1_u_1_871|chromosome:hg38:chr7:128531313:128591856:+
2+
ALAEVFHQL
3+
>generic|STRG.6635.6_u_1191_1398|chromosome:hg38:chr16:31360701:31360908:+
4+
ALSALTALR
5+
>generic|STRG.8148.1_u_0_519|chromosome:hg38:chr18:3449582:3450352:+
6+
FLDPATPRV
7+
>generic|STRG.4465.1_u_2_503|chromosome:hg38:chr12:120464092:120469731:-
8+
FLFQDFLRQA
9+
>generic|STRG.12982.6_u_426_504|chromosome:hg38:chr3:177053888:177064967:-
10+
FLIQHLPLV
11+
>generic|STRG.16829.1_u_131_191|chromosome:hg38:chr8:70296772:70403229:-
12+
FLLDLATHL
13+
>generic|STRG.17886.2_u_2_317|chromosome:hg38:chr9:136727067:136728176:-
14+
GLGDWAAGLRV
15+
>generic|STRG.9923.4_u_201_531|chromosome:hg38:chr2:55419143:55419473:-
16+
SLISTYFHV
17+
>generic|STRG.17203.1_u_0_336|chromosome:hg38:chr9:10948390:11065091:-
18+
YIYEDEVRL
19+
>generic|STRG.1962.1_u_2036_3326|chromosome:hg38:chr1:247189980:247200226:-
20+
YLDPAQQNL
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
HLA-A*02:01
2+
HLA-B*15:11
3+
HLA-C*01:02
4+
HLA-C*03:03
5+
HLA-C*03:04

0 commit comments

Comments
 (0)