Mercurial > repos > devteam > vcffilter
view vcffilter.xml @ 4:6b935ab36d7b draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/vcflib/vcffilter commit bd03161519b5a55c4395ae9715688799319427b2
author | iuc |
---|---|
date | Mon, 26 Mar 2018 10:21:29 -0400 |
parents | 952059348a30 |
children | de885f4afb7f |
line wrap: on
line source
<tool id="vcffilter2" name="VCFfilter:" version="@WRAPPER_VERSION@+galaxy1"> <description>filter VCF data in a variety of attributes</description> <macros> <import>macros.xml</import> </macros> <expand macro="requirements"> <requirement type="package" version="1.7">htslib</requirement> </expand> <expand macro="stdio" /> <command><![CDATA[ ln -s '$input1' input1.vcf && bgzip input1.vcf && tabix -p vcf input1.vcf.gz && vcffilter #for $filter_el in $filter_repeat: $filter_el.filter_type '$filter_el.filter_value' #end for $filter_sites $tag_pass $tag_fail $append_filter $allele_tag $invert $or #if str($region): --region '$region' #end if input1.vcf.gz > '${out_file1}' ]]></command> <inputs> <param name="input1" type="data" format="vcf" label="VCF dataset to filter"/> <repeat name="filter_repeat" title="Add filters"> <param name="filter_type" type="select" label="Select the filter type"> <option value="-f">Info filter (-f)</option> <option value="-g">Genotype filter (-g)</option> </param> <param name="filter_value" type="text" value="DP > 10" label="Specify filterting value" help="See explanation of filtering options below"> <sanitizer> <valid initial="string.printable"> <remove value="'"/> </valid> <mapping initial="none"> <add source="'" target="__sq__"/> </mapping> </sanitizer> </param> </repeat> <param name="filter_sites" argument="--filter-sites" type="boolean" truevalue="--filter-sites" falsevalue="" label="Filter entire records, not just alleles"/> <param name="tag_pass" argument="--tag-pass" type="boolean" truevalue="--tag-pass" falsevalue="" label="Tag vcf records as positively filtered with this tag, print all records"/> <param name="tag_fail" argument="--tag-fail" type="boolean" truevalue="--tag-fail" falsevalue="" label="Tag vcf records as negatively filtered with this tag, print all records"/> <param name="append_filter" argument="--append-filter" type="boolean" truevalue="--append-filter" falsevalue="" label="Append the existing filter tag, don't just replace it"/> <param name="allele_tag" argument="--allele-tag" type="boolean" truevalue="--allele-tag" falsevalue="" label="Apply --tag-pass on a per-allele basis, adds or sets the corresponding INFO field tag"/> <param argument="--invert" type="boolean" truevalue="--invert" falsevalue="" label="Inverts the filter, e.g. grep -v"/> <param argument="--or" type="boolean" truevalue="--or" falsevalue="" label="Use logical OR instead of AND to combine filters"/> <param argument="--region" type="text" label="Specify a region on which to target the filtering" help="Regions should be specified as chr:start-end, e.g X:1000-2000"/> </inputs> <outputs> <data name="out_file1" format="vcf" /> </outputs> <tests> <test> <param name="filter_repeat_0|filter_type" value="-f"/> <param name="filter_repeat_0|filter_value" value="DP > 10"/> <param name="input1" value="vcflib.vcf"/> <output name="out_file1" file="vcffilter-test1.vcf"/> </test> </tests> <help><![CDATA[ You can specify the following options within the **Specify filtering expression** box in any combination:: -f, --info-filter specifies a filter to apply to the info fields of records, removes alleles which do not pass the filter -g, --genotype-filter specifies a filter to apply to the genotype fields of records -s, --filter-sites filter entire records, not just alleles -t, --tag-pass tag vcf records as positively filtered with this tag, print all records -F, --tag-fail tag vcf records as negatively filtered with this tag, print all records -A, --append-filter append the existing filter tag, don't just replace it -a, --allele-tag apply -t on a per-allele basis. adds or sets the corresponding INFO field tag -v, --invert inverts the filter, e.g. grep -v -o, --or use logical OR instead of AND to combine filters -r, --region specify a region on which to target the filtering (must be used in conjunction with -f or -g) Filters are specified in the form {ID} {operator} {value}:: -f "DP > 10" # for info fields -g "GT = 1|1" # for genotype fields -f "CpG" # for 'flag' fields Any number of filters may be specified. They are combined via logical AND unless the --or option is specified. For convenience, you can specify "QUAL" to refer to the quality of the site, even though it does not appear in the INFO fields. Operators can be any of:: =, !, <, >, |, & To restrict output to a specific location use the -r option (must be used in conjunction with -g or -f):: -r chr20:14000-15000 # only output calls between positions 14,000 and 15,000 on chromosome 20 -r chrX # only output call on chromosome X ----- Vcffilter @IS_PART_OF_VCFLIB@ ]]></help> <expand macro="citations" /> </tool>