Mercurial > repos > iuc > snpeff
comparison snpEff.xml @ 33:94653948fdb9 draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/snpeff commit e4cbbb48006ac767c69efe53eab2a63306124bb5
| author | iuc |
|---|---|
| date | Sat, 04 Oct 2025 17:00:46 +0000 |
| parents | ebe9fd7e5bd1 |
| children |
comparison
equal
deleted
inserted
replaced
| 32:ebe9fd7e5bd1 | 33:94653948fdb9 |
|---|---|
| 2 <description> annotate variants</description> | 2 <description> annotate variants</description> |
| 3 <macros> | 3 <macros> |
| 4 <import>snpEff_macros.xml</import> | 4 <import>snpEff_macros.xml</import> |
| 5 </macros> | 5 </macros> |
| 6 <requirements> | 6 <requirements> |
| 7 <expand macro="requirement" /> | 7 <expand macro="requirement"> |
| 8 <requirement type="package" version="9.5">coreutils</requirement> | |
| 9 </expand> | |
| 8 </requirements> | 10 </requirements> |
| 9 <expand macro="stdio" /> | 11 <expand macro="stdio" /> |
| 10 <expand macro="version_command" /> | 12 <expand macro="version_command" /> |
| 11 <command><![CDATA[ | 13 <command><![CDATA[ |
| 12 #if $intervals | 14 #if $intervals |
| 45 -onlyTr '$transcripts' | 47 -onlyTr '$transcripts' |
| 46 #end if | 48 #end if |
| 47 #if $intervals ### fix this for multiple dataset input | 49 #if $intervals ### fix this for multiple dataset input |
| 48 -interval intervals.bed | 50 -interval intervals.bed |
| 49 #end if | 51 #end if |
| 50 #if $statsFile: | |
| 51 -stats '$statsFile' | |
| 52 #end if | |
| 53 #if $csvStats: | |
| 54 -csvStats '$csvFile' | |
| 55 #end if | |
| 56 #if str($chr).strip() != '': | 52 #if str($chr).strip() != '': |
| 57 -chr '$chr' | 53 -chr '$chr' |
| 54 #end if | |
| 55 #if $generate_stats or $generate_gene_stats or $csvStats: | |
| 56 #if $csvStats: | |
| 57 $csvStats snpeff_stats.csv | |
| 58 #end if | |
| 59 #if $generate_stats or ($generate_gene_stats and not $csvStats): | |
| 60 ## the base name passed in via the -csvStats or the -s option also determines the name of the genes.txt file | |
| 61 ## so in the absence of the first we need the second to have a consistent name of the genes.txt file | |
| 62 -s snpeff_stats.html | |
| 63 #end if | |
| 64 #else: | |
| 65 ## when no stats output is requested by the user, we can make things a little more efficient | |
| 66 ## by telling snpEff that it doesn't have to write even the default (html and genes.txt) ones. | |
| 67 -noStats | |
| 58 #end if | 68 #end if |
| 59 $noLog | 69 $noLog |
| 60 ## Regulation names can include parentheses: H3K4me3-MSC_(VB)_enriched_sites | 70 ## Regulation names can include parentheses: H3K4me3-MSC_(VB)_enriched_sites |
| 61 ## Enclose them in in single and double quotes, as the conda snpEff bash script will remove outer quotes | 71 ## Enclose them in in single and double quotes, as the conda snpEff bash script will remove outer quotes |
| 62 #if $snpDb.genomeSrc == 'cached': | 72 #if $snpDb.genomeSrc == 'cached': |
| 86 -dataDir "\$PWD/temp" | 96 -dataDir "\$PWD/temp" |
| 87 -download | 97 -download |
| 88 '$snpDb.genome_version' | 98 '$snpDb.genome_version' |
| 89 #end if | 99 #end if |
| 90 '$input' > '$snpeff_output' | 100 '$input' > '$snpeff_output' |
| 91 #if $statsFile: | 101 #if $generate_gene_stats: |
| 92 && | 102 ## remove the first, unnecessary comment line from the output |
| 93 #import os | 103 && tail -n+2 snpeff_stats.genes.txt > genes.txt |
| 94 #if $csvStats: | 104 #end if |
| 95 #set $genes_file = str($csvFile) + '.genes.txt' | 105 #if $generate_stats: |
| 96 #else | 106 ## independently of whether the user asked for the gene.txt file, |
| 97 #set $genes_file = str($statsFile) + '.genes.txt' | 107 ## we need to add it to files_path because the stats html report links to it. |
| 98 #end if | 108 && mkdir '$statsFile.files_path' && |
| 99 #set $genes_file_name = os.path.split($genes_file)[-1] | 109 mv snpeff_stats.genes.txt $statsFile.files_path |
| 100 mkdir '$statsFile.files_path' && | |
| 101 mv '$genes_file' '#echo os.path.join($statsFile.files_path, $genes_file_name)#' | |
| 102 #end if | 110 #end if |
| 103 ]]></command> | 111 ]]></command> |
| 104 <inputs> | 112 <inputs> |
| 105 <param name="input" type="data" format="vcf,bed" label="Sequence changes (SNPs, MNPs, InDels)"/> | 113 <param name="input" type="data" format="vcf,bed" label="Sequence changes (SNPs, MNPs, InDels)"/> |
| 106 <param argument="-i" name="inputFormat" type="select" label="Input format" help="Specify the format of input dataset(s)"> | 114 <param argument="-i" name="inputFormat" type="select" label="Input format" help="Specify the format of input dataset(s)"> |
| 112 <option value="gatk">GATK-compatible VCF (only if input is VCF)</option> | 120 <option value="gatk">GATK-compatible VCF (only if input is VCF)</option> |
| 113 <option value="bed">BED</option> | 121 <option value="bed">BED</option> |
| 114 <option value="bedAnn">BED annotations</option> | 122 <option value="bedAnn">BED annotations</option> |
| 115 </param> | 123 </param> |
| 116 <param argument="-csvStats" type="boolean" truevalue="-csvStats" falsevalue="" checked="false" label="Create CSV report?" help="Useful for downstream analyses and report generation" /> | 124 <param argument="-csvStats" type="boolean" truevalue="-csvStats" falsevalue="" checked="false" label="Create CSV report?" help="Useful for downstream analyses and report generation" /> |
| 117 <param argument="-noStats" name="generate_stats" type="boolean" truevalue="" falsevalue="-noStats" checked="true" label="Produce Summary Stats?" help="Generates an HTML summary of results"/> | 125 <param name="generate_stats" type="boolean" checked="true" label="Produce Summary Stats?" help="Generates an HTML summary of results"/> |
| 126 <param name="generate_gene_stats" type="boolean" label="Produce Gene Statistics output?" help="Generates a table of effects per gene as an extra output"/> | |
| 118 <conditional name="snpDb"> | 127 <conditional name="snpDb"> |
| 119 <param name="genomeSrc" type="select" label="Genome source"> | 128 <param name="genomeSrc" type="select" label="Genome source"> |
| 120 <!-- These options are referenced in the help section of SnpEff download tool. If you change them, change help of SnpEff download as well --> | 129 <!-- These options are referenced in the help section of SnpEff download tool. If you change them, change help of SnpEff download as well --> |
| 121 <option value="cached">Locally installed snpEff database</option> | 130 <option value="cached">Locally installed snpEff database</option> |
| 122 <option value="history">Downloaded snpEff database in your history</option> | 131 <option value="history">Downloaded snpEff database in your history</option> |
| 125 </param> | 134 </param> |
| 126 <when value="cached"> | 135 <when value="cached"> |
| 127 <param name="genomeVersion" type="select" label="Genome"> | 136 <param name="genomeVersion" type="select" label="Genome"> |
| 128 <!--GENOME DESCRIPTION--> | 137 <!--GENOME DESCRIPTION--> |
| 129 <options from_data_table="snpeffv_genomedb"> | 138 <options from_data_table="snpeffv_genomedb"> |
| 130 <filter type="static_value" name="snpeff_version" value="@SNPEFF_VERSION@" column="1"/> | 139 <filter type="regexp" column="1" value="@COMPATIBLE_DB_VERSIONS_REGEX@" /> |
| 131 <filter type="unique_value" column="2" /> | 140 <filter type="unique_value" column="2" /> |
| 132 </options> | 141 </options> |
| 133 </param> | 142 </param> |
| 134 <section name="reg_section" expanded="false" title="Regulation options"> | 143 <section name="reg_section" expanded="false" title="Regulation options"> |
| 135 <param name="regulation" type="select" display="checkboxes" multiple="true" label="Non-coding and regulatory annotation" help="These are available for only a few genomes"> | 144 <param name="regulation" type="select" display="checkboxes" multiple="true" label="Non-coding and regulatory annotation" help="These are available for only a few genomes"> |
| 136 <options from_data_table="snpeffv_regulationdb"> | 145 <options from_data_table="snpeffv_regulationdb"> |
| 137 <filter type="param_value" ref="genomeVersion" key="genome" column="2" /> | 146 <filter type="regexp" column="1" value="@COMPATIBLE_DB_VERSIONS_REGEX@" /> |
| 147 <filter type="param_value" ref="genomeVersion" column="2" /> | |
| 138 <filter type="unique_value" column="3" /> | 148 <filter type="unique_value" column="3" /> |
| 139 </options> | 149 </options> |
| 140 </param> | 150 </param> |
| 141 </section> | 151 </section> |
| 142 </when> | 152 </when> |
| 143 <when value="history"> | 153 <when value="history"> |
| 144 <param name="snpeff_db" type="data" format="snpeffdb" label="@SNPEFF_VERSION@ Genome Data"> | 154 <param name="snpeff_db" type="data" format="snpeffdb" label="@SNPEFF_VERSION@ Genome Data"> |
| 145 <validator type="expression" message="This version of SnpEff will only work with @SNPEFF_VERSION@ genome databases">value is not None and value.metadata.snpeff_version == "@SNPEFF_VERSION@"</validator> | 155 <validator type="expression" message="This version of SnpEff will only work with @COMPATIBLE_DB_VERSIONS_STRING@ genome databases">value.metadata.snpeff_version in @COMPATIBLE_DB_VERSIONS@</validator> |
| 146 </param> | 156 </param> |
| 147 <section name="reg_section" expanded="false" title="Regulation options"> | 157 <section name="reg_section" expanded="false" title="Regulation options"> |
| 148 <!-- From metadata --> | 158 <!-- From metadata --> |
| 149 <param name="regulation" type="select" display="checkboxes" multiple="true" label="Non-coding and regulatory annotation" help="These are available for only a few genomes"> | 159 <param name="regulation" type="select" display="checkboxes" multiple="true" label="Non-coding and regulatory annotation" help="These are available for only a few genomes"> |
| 150 <options> | 160 <options> |
| 158 <validator type="empty_field" message="A genome version name is required" /> | 168 <validator type="empty_field" message="A genome version name is required" /> |
| 159 </param> | 169 </param> |
| 160 </when> | 170 </when> |
| 161 <when value="custom"> | 171 <when value="custom"> |
| 162 <param name="snpeff_db" type="data" format="snpeffdb" label="@SNPEFF_VERSION@ Genome Data"> | 172 <param name="snpeff_db" type="data" format="snpeffdb" label="@SNPEFF_VERSION@ Genome Data"> |
| 163 <validator type="expression" message="This version of SnpEff will only work with @SNPEFF_VERSION@ genome databases">value is not None and value.metadata.snpeff_version == "@SNPEFF_VERSION@"</validator> | 173 <validator type="expression" message="This version of SnpEff will only work with @COMPATIBLE_DB_VERSIONS_STRING@ genome databases">value.metadata.snpeff_version in @COMPATIBLE_DB_VERSIONS@</validator> |
| 164 </param> | 174 </param> |
| 165 <param name="codon_table" type="select" label="Select genetic code for this sequence" help="If this sequence uses non-standard genetic code, select one from these options"> | 175 <param name="codon_table" type="select" label="Select genetic code for this sequence" help="If this sequence uses non-standard genetic code, select one from these options"> |
| 166 <option selected="true" value="Standard">Standard</option> | 176 <option selected="true" value="Standard">Standard</option> |
| 167 <option value="Vertebrate_Mitochondrial">Vertebrate_Mitochondrial</option> | 177 <option value="Vertebrate_Mitochondrial">Vertebrate_Mitochondrial</option> |
| 168 <option value="Yeast_Mitochondrial">Yeast_Mitochondrial</option> | 178 <option value="Yeast_Mitochondrial">Yeast_Mitochondrial</option> |
| 186 <option value="Blepharisma_Macronuclear">Blepharisma_Macronuclear</option> | 196 <option value="Blepharisma_Macronuclear">Blepharisma_Macronuclear</option> |
| 187 <option value="Chlorophycean_Mitochondrial">Chlorophycean_Mitochondrial</option> | 197 <option value="Chlorophycean_Mitochondrial">Chlorophycean_Mitochondrial</option> |
| 188 <option value="Trematode_Mitochondrial">Trematode_Mitochondrial</option> | 198 <option value="Trematode_Mitochondrial">Trematode_Mitochondrial</option> |
| 189 <option value="Scenedesmus_obliquus_Mitochondrial">Scenedesmus_obliquus_Mitochondrial</option> | 199 <option value="Scenedesmus_obliquus_Mitochondrial">Scenedesmus_obliquus_Mitochondrial</option> |
| 190 <option value="Thraustochytrium_Mitochondrial">Thraustochytrium_Mitochondrial</option> | 200 <option value="Thraustochytrium_Mitochondrial">Thraustochytrium_Mitochondrial</option> |
| 191 </param> | 201 </param> |
| 192 </when> | 202 </when> |
| 193 </conditional> | 203 </conditional> |
| 194 <param name="udLength" argument="-ud" type="select" label="Upstream / Downstream length"> | 204 <param name="udLength" argument="-ud" type="select" label="Upstream / Downstream length"> |
| 195 <option value="0" selected="true">No upstream / downstream intervals (0 bases)</option> | 205 <option value="0" selected="true">No upstream / downstream intervals (0 bases)</option> |
| 196 <option value="200">200 bases</option> | 206 <option value="200">200 bases</option> |
| 326 <change_format> | 336 <change_format> |
| 327 <when input="outputConditional.outputFormat" value="bed" format="bed" /> | 337 <when input="outputConditional.outputFormat" value="bed" format="bed" /> |
| 328 <when input="outputConditional.outputFormat" value="bedAnn" format="bed" /> | 338 <when input="outputConditional.outputFormat" value="bedAnn" format="bed" /> |
| 329 </change_format> | 339 </change_format> |
| 330 </data> | 340 </data> |
| 331 <data name="statsFile" format="html" label="${tool.name} on ${on_string} - HTML stats"> | 341 <data name="statsFile" format="html" label="${tool.name} on ${on_string} - HTML stats" from_work_dir="snpeff_stats.html"> |
| 332 <filter>generate_stats</filter> | 342 <filter>generate_stats</filter> |
| 333 </data> | 343 </data> |
| 334 <data name="csvFile" format="csv" label="${tool.name} on ${on_string} - CSV stats"> | 344 <data name="genes_file" format="tabular" label="${tool.name} on ${on_string} - Gene stats" from_work_dir="genes.txt"> |
| 345 <filter>generate_gene_stats</filter> | |
| 346 </data> | |
| 347 <data name="csvFile" format="txt" label="${tool.name} on ${on_string} - CSV stats" from_work_dir="snpeff_stats.csv"> | |
| 335 <filter>csvStats</filter> | 348 <filter>csvStats</filter> |
| 336 </data> | 349 </data> |
| 337 </outputs> | 350 </outputs> |
| 338 <tests> | 351 <tests> |
| 352 <test expect_num_outputs="1"> | |
| 353 <param name="input" ftype="vcf" value="input.vcf"/> | |
| 354 <param name="inputFormat" value="vcf"/> | |
| 355 <param name="outputFormat" value="vcf"/> | |
| 356 <conditional name="snpDb"> | |
| 357 <param name="genomeSrc" value="cached"/> | |
| 358 <param name="genomeVersion" value="ebola_zaire"/> | |
| 359 </conditional> | |
| 360 <param name="udLength" value="0"/> | |
| 361 <param name="generate_stats" value="false"/> | |
| 362 <output name="snpeff_output"> | |
| 363 <assert_contents> | |
| 364 <has_text_matching expression="KJ660346.1\t572\t.*missense_variant" /> | |
| 365 <has_text_matching expression="KJ660346.1\t1024\t.*synonymous_variant" /> | |
| 366 </assert_contents> | |
| 367 </output> | |
| 368 </test> | |
| 339 <test expect_num_outputs="2"> | 369 <test expect_num_outputs="2"> |
| 340 <param name="input" ftype="vcf" value="input.vcf"/> | 370 <param name="input" ftype="vcf" value="input.vcf"/> |
| 341 <param name="inputFormat" value="vcf"/> | 371 <param name="inputFormat" value="vcf"/> |
| 342 <param name="outputFormat" value="vcf"/> | 372 <param name="outputFormat" value="vcf"/> |
| 343 <param name="genomeSrc" value="named"/> | 373 <conditional name="snpDb"> |
| 344 <param name="genome_version" value="ebola_zaire"/> | 374 <param name="genomeSrc" value="cached"/> |
| 375 <param name="genomeVersion" value="ebola_zaire"/> | |
| 376 </conditional> | |
| 345 <param name="udLength" value="0"/> | 377 <param name="udLength" value="0"/> |
| 346 <param name="generate_stats" value="true"/> | |
| 347 <output name="snpeff_output"> | 378 <output name="snpeff_output"> |
| 348 <assert_contents> | 379 <assert_contents> |
| 349 <has_text_matching expression="KJ660346.1\t572\t.*missense_variant" /> | 380 <has_text_matching expression="KJ660346.1\t572\t.*missense_variant" /> |
| 350 <has_text_matching expression="KJ660346.1\t1024\t.*synonymous_variant" /> | 381 <has_text_matching expression="KJ660346.1\t1024\t.*synonymous_variant" /> |
| 351 </assert_contents> | 382 </assert_contents> |
| 352 </output> | 383 </output> |
| 353 <output name="statsFile"> | 384 <output name="statsFile"> |
| 354 <assert_contents> | 385 <assert_contents> |
| 355 <has_text text="<b>"/> | 386 <has_text text="<b>"/> |
| 387 </assert_contents> | |
| 388 </output> | |
| 389 </test> | |
| 390 <test expect_num_outputs="2"> | |
| 391 <param name="input" ftype="vcf" value="input.vcf"/> | |
| 392 <param name="inputFormat" value="vcf"/> | |
| 393 <param name="outputFormat" value="vcf"/> | |
| 394 <conditional name="snpDb"> | |
| 395 <param name="genomeSrc" value="cached"/> | |
| 396 <param name="genomeVersion" value="ebola_zaire"/> | |
| 397 </conditional> | |
| 398 <param name="udLength" value="0"/> | |
| 399 <param name="generate_stats" value="false"/> | |
| 400 <param name="generate_gene_stats" value="true"/> | |
| 401 <output name="snpeff_output"> | |
| 402 <assert_contents> | |
| 403 <has_text_matching expression="KJ660346.1\t572\t.*missense_variant" /> | |
| 404 <has_text_matching expression="KJ660346.1\t1024\t.*synonymous_variant" /> | |
| 405 </assert_contents> | |
| 406 </output> | |
| 407 <output name="genes_file"> | |
| 408 <assert_contents> | |
| 409 <has_text text="#GeneName"/> | |
| 356 </assert_contents> | 410 </assert_contents> |
| 357 </output> | 411 </output> |
| 358 </test> | 412 </test> |
| 359 <!-- Test interval option--> | 413 <!-- Test interval option--> |
| 360 <test expect_num_outputs="2"> | 414 <test expect_num_outputs="2"> |
| 361 <param name="input" ftype="vcf" value="input.vcf"/> | 415 <param name="input" ftype="vcf" value="input.vcf"/> |
| 362 <param name="inputFormat" value="vcf"/> | 416 <param name="inputFormat" value="vcf"/> |
| 363 <param name="outputFormat" value="vcf"/> | 417 <param name="outputFormat" value="vcf"/> |
| 364 <param name="genomeSrc" value="named"/> | 418 <conditional name="snpDb"> |
| 365 <param name="interval" value="intervals.bed"/> | 419 <param name="genomeSrc" value="cached"/> |
| 366 <param name="genome_version" value="ebola_zaire"/> | 420 <param name="genomeVersion" value="ebola_zaire"/> |
| 421 </conditional> | |
| 422 <param name="intervals" value="intervals.bed"/> | |
| 367 <param name="udLength" value="0"/> | 423 <param name="udLength" value="0"/> |
| 368 <param name="generate_stats" value="false"/> | 424 <param name="generate_stats" value="false"/> |
| 369 <param name="csvStats" value="true"/> | 425 <param name="csvStats" value="true"/> |
| 370 <output name="snpeff_output"> | 426 <output name="snpeff_output"> |
| 371 <assert_contents> | 427 <assert_contents> |
