Previous changeset 0:b42c82186e85 (2019-08-27) |
Commit message:
"planemo upload for repository https://github.com/phac-nml/snvphyl-galaxy commit 57067916cb7b9c5b65c1da59d4bbb846c3e3af2f" |
modified:
consolidate_vcfs.xml |
added:
macros.xml test-data/expected_regions_disabled.txt test-data/expected_regions_empty.txt test-data/expected_regions_v3.txt test-data/freebayes/v3.bcf test-data/mpileup/v3.bcf test-data/v3.bcf.gz |
removed:
test-data/expected_regions.txt |
b |
diff -r b42c82186e85 -r 4c249c0aebad consolidate_vcfs.xml --- a/consolidate_vcfs.xml Tue Aug 27 12:30:25 2019 -0400 +++ b/consolidate_vcfs.xml Tue Jun 23 10:25:20 2020 -0400 |
[ |
b'@@ -1,8 +1,9 @@\n-<tool id="consolidate_vcfs" name="Consolidate VCFs" version ="1.8.2">\n+<tool id="consolidate_vcfs" name="Consolidate VCFs" version ="@VERSION@+galaxy1">\n <description>combine freebayes and mpileup files for use by vcf2snvalignment</description>\n- <requirements>\n- <requirement type="package" version="1.8.2">snvphyl-tools</requirement>\n- </requirements>\n+ <macros>\n+ <import>macros.xml</import>\n+ </macros>\n+ <expand macro="requirements"/>\n <command detect_errors="exit_code"><![CDATA[\n \n #set $name = str($freebayes).split(\'/\')[-1]\n@@ -24,6 +25,11 @@\n \t bcftools index $name &&\n \t#end if\n \n+\t## If there is no density filtering performed we still need to output an empty file\n+\t#if not $use_density_filter:\n+\t echo \'#No density filtering\' > \'$filtered_density\' &&\n+\t#end if\n+\n consolidate_vcfs.pl\n \n \n@@ -37,44 +43,37 @@\n #set $path = str($mpileup).split(\'/\')[-1]\n --mpileup "$path"\n \n- #set $path = str($path).split(\'/\')[-1]\n- #if $filtered_density:\n- --filtered-density-out "$filtered_density"\n- #end if\n-\n- #if $use_density_filter.select_list == "no":\n+ #if not $use_density_filter:\n --skip-density-filter\n #else\n- #if $use_density_filter.window_size:\n- --window-size "$use_density_filter.window_size"\n+ #if $filtered_density:\n+ --filtered-density-out \'$filtered_density\'\n #end if\n- #if $use_density_filter.threshold:\n- --density-threshold "$use_density_filter.threshold"\n+\n+ #if $window_size:\n+ --window-size "$window_size"\n+ #end if\n+ #if $threshold:\n+ --density-threshold "$threshold"\n #end if\n #end if\n \n ##mark where the output files will be sent to, simply have to match them up later in the xml output section\n -o $bcf_combined\n+\n ]]>\n </command>\n <inputs>\n- <param name="coverage" type="integer" value="15" label="Minimum coverage"/>\n- <param name="mean_mapping" type="integer" value="30" label="Minimum mean mapping quality"/>\n- <param name="snv_abundance_ratio" type="text" value="0.75" optional="false" label="SNV abundance ratio"/>\n- <param name="freebayes" type="data" label="FreeBayes filtered BCF" help="" optional="false" format="bcf_bgzip,bcf" />\n- <param name="mpileup" type="data" label="Mpileup BCF" help="" optional="false" format="bcf_bgzip,bcf" />\n- <conditional name="use_density_filter">\n- <param name="select_list" type="select" label= "SNV density filtering">\n- <option value="yes">Apply</option>\n- <option value="no">Don\'t apply</option>\n- </param>\n- <when value="yes">\n- <param name="window_size" type="integer" label="Size of search window" format="" optional="false" value="100"/>\n- <param name="threshold" type="integer" label="Density threshold cutoff" format="" optional="false" value="10"/>\n- </when>\n- <when value="no">\n- </when>\n- </conditional>\n+ <param name="coverage" type="integer" value="15" label="Minimum coverage" help="(--coverage-cutoff)" />\n+ <param name="mean_mapping" type="integer" value="30" label="Minimum mean mapping quality" help="(--min-mean-mapping)" />\n+ <param name="snv_abundance_ratio" type="text" value="0.75" optional="false" label="SNV abundance ratio" help="(--snv-abundance-ratio)" />\n+ <param name="freebayes" type="data" label="FreeBayes filtered BCF" optional="false" format="bcf_bgzip,bcf" help="(--vcfsplit)" />\n+ <param name="mpileup" type="data" label="Mpileup BCF" optional="false" format="bcf_bgzip,bcf" help="(--mpileup)" />\n+ <param name="use_density_filter" type="boolean" checked="true" label="Apply SNV density filtering" help="(--skip-density-filter)" />\n+ <param name="window_size" type="integer" min="1" label="SNV Density Filtering: Size of search window" format="" optional="false" value="500"\n+ help="(--windo'..b'/>\n </inputs>\n <outputs>\n <data format="bcf_bgzip" name="bcf_combined"/>\n@@ -87,10 +86,11 @@\n <param name="mpileup" value="mpileup/v1.bcf" />\n <param name="mean_mapping" value="30" />\n <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="use_density_filter" value="true" />\n <param name="window_size" value="500" />\n <param name="threshold" value="2" />\n <output name="bcf_combined" file="v1.bcf.gz" compare="sim_size" delta="500"/>\n- <output name="filtered_density" file="expected_regions.txt"/>\n+ <output name="filtered_density" file="expected_regions_empty.txt"/>\n </test>\n <test>\n <param name="coverage" value="5"/>\n@@ -98,18 +98,63 @@\n <param name="mpileup" value="mpileup/v2.bcf" />\n <param name="mean_mapping" value="30" />\n <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="use_density_filter" value="true" />\n <param name="window_size" value="500" />\n <param name="threshold" value="2" />\n <output name="bcf_combined" file="v2.bcf.gz" compare="sim_size" delta="500"/>\n- <output name="filtered_density" file="expected_regions.txt"/>\n+ <output name="filtered_density" file="expected_regions_empty.txt"/>\n+ </test>\n+ <test>\n+ <param name="coverage" value="5"/>\n+ <param name="freebayes" value="freebayes/v3.bcf" />\n+ <param name="mpileup" value="mpileup/v3.bcf" />\n+ <param name="mean_mapping" value="30" />\n+ <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="use_density_filter" value="true" />\n+ <param name="window_size" value="10" />\n+ <param name="threshold" value="3" />\n+ <output name="bcf_combined" file="v3.bcf.gz" compare="sim_size" delta="250"/>\n+ <output name="filtered_density" file="expected_regions_v3.txt"/>\n+ </test>\n+ <test>\n+ <param name="coverage" value="5"/>\n+ <param name="freebayes" value="freebayes/v3.bcf" />\n+ <param name="mpileup" value="mpileup/v3.bcf" />\n+ <param name="mean_mapping" value="30" />\n+ <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="use_density_filter" value="true" />\n+ <param name="window_size" value="10" />\n+ <param name="threshold" value="4" />\n+ <output name="bcf_combined" file="v3.bcf.gz" compare="sim_size" delta="250"/>\n+ <output name="filtered_density" file="expected_regions_empty.txt"/>\n+ </test>\n+ <test>\n+ <param name="coverage" value="5"/>\n+ <param name="freebayes" value="freebayes/v3.bcf" />\n+ <param name="mpileup" value="mpileup/v3.bcf" />\n+ <param name="mean_mapping" value="30" />\n+ <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="window_size" value="1" />\n+ <param name="threshold" value="2" />\n+ <output name="bcf_combined" file="v3.bcf.gz" compare="sim_size" delta="250"/>\n+ <output name="filtered_density" file="expected_regions_empty.txt"/>\n+ </test>\n+ <test>\n+ <param name="coverage" value="5"/>\n+ <param name="freebayes" value="freebayes/v3.bcf" />\n+ <param name="mpileup" value="mpileup/v3.bcf" />\n+ <param name="mean_mapping" value="30" />\n+ <param name="snv_abundance_ratio" value="0.75" />\n+ <param name="use_density_filter" value="false" />\n+ <param name="window_size" value="10" />\n+ <param name="threshold" value="3" />\n+ <output name="bcf_combined" file="v3.bcf.gz" compare="sim_size" delta="250"/>\n+ <output name="filtered_density" file="expected_regions_disabled.txt"/>\n </test>\n </tests>\n \n <help>\n Merges variant and non-variant calls (in VCF format) produced from two independent base callers, FreeBayes, and SAMtools/BCFtools. Produces a merged set of high-quality variant and non-variant calls (in BCF format). Optionally, produces a list of SNV-dense regions above the passed thresholds.\n </help>\n-\n- <citations>\n- </citations>\n-\n+ <expand macro="citations"/>\n </tool>\n' |
b |
diff -r b42c82186e85 -r 4c249c0aebad macros.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/macros.xml Tue Jun 23 10:25:20 2020 -0400 |
b |
@@ -0,0 +1,16 @@ +<macros> + <token name="@VERSION@">1.8.2</token> + + <xml name="requirements"> + <requirements> + <requirement type="package" version="@VERSION@">snvphyl-tools</requirement> + <yield/> + </requirements> + </xml> + <xml name="citations"> + <citations> + <citation type="doi">10.1099/mgen.0.000116</citation> + <yield/> + </citations> + </xml> +</macros> |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/expected_regions.txt --- a/test-data/expected_regions.txt Tue Aug 27 12:30:25 2019 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,1 +0,0 @@ -#Calculation and writing of high density regions has completed. |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/expected_regions_disabled.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/expected_regions_disabled.txt Tue Jun 23 10:25:20 2020 -0400 |
b |
@@ -0,0 +1,1 @@ +#No density filtering |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/expected_regions_empty.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/expected_regions_empty.txt Tue Jun 23 10:25:20 2020 -0400 |
b |
@@ -0,0 +1,1 @@ +#Calculation and writing of high density regions has completed. |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/expected_regions_v3.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/expected_regions_v3.txt Tue Jun 23 10:25:20 2020 -0400 |
b |
@@ -0,0 +1,2 @@ +reference 4 8 +#Calculation and writing of high density regions has completed. |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/freebayes/v3.bcf |
b |
Binary file test-data/freebayes/v3.bcf has changed |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/mpileup/v3.bcf |
b |
Binary file test-data/mpileup/v3.bcf has changed |
b |
diff -r b42c82186e85 -r 4c249c0aebad test-data/v3.bcf.gz |
b |
Binary file test-data/v3.bcf.gz has changed |