diff stacks_populations.xml @ 5:35e673d79262 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/stacks2 commit 4e87a14a5479800df9675c1cbcdbe1b11f63653b-dirty
author matthias
date Wed, 27 Feb 2019 10:01:16 -0500
parents cc87f9d30171
children 1e260cccfafb
line wrap: on
line diff
--- a/stacks_populations.xml	Fri Jan 04 03:37:16 2019 -0500
+++ b/stacks_populations.xml	Wed Feb 27 10:01:16 2019 -0500
@@ -1,11 +1,11 @@
-<tool id="stacks2_populations" name="Stacks2: populations" version="@STACKS_VERSION@+galaxy@WRAPPER_VERSION@">
-    <description>analyze a population of individual samples ('populations' program)</description>
+<tool id="stacks2_populations" name="Stacks2: populations" profile="@PROFILE@" version="@STACKS_VERSION@+galaxy@WRAPPER_VERSION@">
+    <description>Calculate population-level summary statistics</description>
     <macros>
         <import>macros.xml</import>
     </macros>
     <expand macro="requirements"/>
-    <expand macro="stdio"/>
-    <command><![CDATA[
+    <expand macro="version_cmd"/>
+    <command detect_errors="aggressive"><![CDATA[
 #import re
 
 mkdir stacks_inputs stacks_outputs
@@ -47,6 +47,8 @@
 
 -p $options_filtering.minpop
 -r $options_filtering.minperc
+-R $options_filtering.min_samples_overall
+$options_filtering.filter_haplotype_wise
 --min_maf $options_filtering.minminor
 --min_mac $options_filtering.min_mac
 #if str($options_filtering.max_obs_het)
@@ -122,7 +124,7 @@
 $populations_output.phylip
 $populations_output.phylip_var
 ##$populations_output.phylip_var_all
-##$populations_output.treemix
+$populations_output.treemix
 $populations_output.no_hap_exports
 $populations_output.fasta_samples_raw
 
@@ -130,17 +132,21 @@
 
 $advanced_options.log_fst_comp
 
-## populations outputs log info to stdout for vcf input 
+## populations outputs log info to stdout for vcf input
 ## for gstacks input it creates stacks_output/population.log
 ## in the latter case we take the log file
-## also for vcf input the output files are named input.p.... 
+## also for vcf input the output files are named input.p....
 ## instead of populations...
 
 #if str($options_usage.input_type) == 'vcf'
-    > $output_log
+    #if $output_log
+        > $output_log
+    #end if
     && find stacks_outputs -type f -iname "input.p*" | while read file; do mv "\$file" "\$(echo \$file | sed 's/\/input.p/\/populations/;')"; done
 #else
-    && mv stacks_outputs/populations.log $output_log
+    #if $output_log
+        && mv stacks_outputs/populations.log $output_log
+    #end if
 #end if
     ]]></command>
 
@@ -158,17 +164,19 @@
             </when>
         </conditional>
         <param name="popmap" type="data" format="tabular,txt" label="Specify a population map" argument="-M" help="Format is 'SAMPLE1 \t POP1 \n SAMPLE2 ...'." optional="true"/>
-        <param argument="--batch_size" type="integer" value="" optional="true" label="number of loci to process in a batch"  help="(default: 10,000 in de novo mode; in reference mode, one chromosome per batch). Increase to speed analysis, uses more memory, decrease to save memory)"/>
+        <param argument="--batch_size" type="integer" value="" optional="true" label="Number of loci to process in a batch"  help="(default: 10,000 in de novo mode; in reference mode, one chromosome per batch). Increase to speed analysis, uses more memory, decrease to save memory)"/>
 
         <!-- Data Filtering -->
         <section name="options_filtering" title="Data filtering options" expanded="true">
 
             <param name="minperc" argument="-r" type="float" value="0.0" min="0" max="1" label="Minimum percentage of individuals in a population required to process a locus for that population" />
             <param name="minpop" argument="-p" type="integer" value="1" label="Minimum number of populations a locus must be present in to process a locus" />
-            <param name="minminor" argument="--min_maf" type="float" value="0" min="0" max="0.5" label="minimum minor allele frequency" help="specify a minimum minor allele frequency required to process a nucleotide site at a locus" />
-            <param argument="--min_mac" type="integer" value="0" min="0" label="minimum minor allele count" help="specify a minimum minor allele count required to process a nucleotide site at a locus" />
+            <param name="min_samples_overall" argument="--min-samples-overall" type="float" value="0.0" min="0" max="1" label="minimum percentage of individuals across populations required to process a locus" />
+            <param name="filter_haplotype_wise" argument="--filter-haplotype-wise" type="boolean" truevalue="--filter-haplotype-wise" falsevalue="" checked="false" label="apply the above filters haplotype wise" help="unshared SNPs will be pruned to reduce haplotype-wise missing data." />
+            <param name="minminor" argument="--min_maf" type="float" value="0" min="0" max="0.5" label="Minimum minor allele frequency" help="specify a minimum minor allele frequency required to process a nucleotide site at a locus" />
+            <param argument="--min_mac" type="integer" value="0" min="0" label="Minimum minor allele count" help="specify a minimum minor allele count required to process a nucleotide site at a locus" />
             <param argument="--max_obs_het" type="float" value="" min="0" max="1" optional="true" label="Maximum observed heterozygosity required to process a nucleotide site at a locus." />
-            <!-- deprecated https://groups.google.com/forum/#!msg/stacks-users/jdC7gw_MuK4/1v0FG3u7AwAJ 
+            <!-- deprecated https://groups.google.com/forum/#!msg/stacks-users/jdC7gw_MuK4/1v0FG3u7AwAJ
             <param name="lnl" type="float" value="" optional="true" argument="\-\-lnl_lim" label="Filter loci with log likelihood values below this threshold" />-->
             <param name="filter_single_snp" type="select" label="Analyse all SNPs per locus" >
                 <option value="">yes</option>
@@ -184,13 +192,13 @@
             <param name="enzyme" argument="-e" type="select" label="Provide the restriction enzyme used" help="required if generating genomic output" >
                 <expand macro="enzymes"/>
             </param>
-            <param argument="--merge_sites" truevalue="--merge_sites" falsevalue="" type="boolean" checked="false" label="merge loci that were produced from the same restriction enzyme cutsite" help="(requires reference-aligned data)" />
-            <param argument="--merge_prune_lim" type="float" value="1.0" min="0.0" max="1.0" label="for merging adjacent loci: fraction of samples possessing both loci to prune remaining samples from analysis" />
+            <param argument="--merge_sites" truevalue="--merge_sites" falsevalue="" type="boolean" checked="false" label="Merge loci that were produced from the same restriction enzyme cutsite" help="(requires reference-aligned data)" />
+            <param argument="--merge_prune_lim" type="float" value="1.0" min="0.0" max="1.0" label="Fraction of samples possessing both loci to prune remaining samples from analysis" help="for merging adjacent loci"/>
         </section>
 
         <!-- Locus stats -->
         <section name="locus_stats" title="Locus Stats" expanded="true">
-            <param argument="--hwe" truevalue="--hwe" falsevalue="" type="boolean" checked="false" label="calculate divergence from Hardy-Weinberg equilibrium for each locus" />
+            <param argument="--hwe" truevalue="--hwe" falsevalue="" type="boolean" checked="false" label="Calculate divergence from Hardy-Weinberg equilibrium for each locus" />
         </section>
 
         <!-- Fstats -->
@@ -225,28 +233,28 @@
         <!-- File output options -->
         <section name="populations_output" title="Output options" expanded="true">
             <param name="ordered_export" argument="--ordered_export" truevalue="--ordered_export" falsevalue="" type="boolean" checked="false" label="If data is reference aligned, exports will be ordered; only a single representative of each overlapping site." />
-            <param name="fasta_loci" argument="--fasta_loci" truevalue="--fasta_loci" falsevalue="" type="boolean" checked="false" label="output locus consensus sequences in FASTA format" />
-            <param name="fasta_samples" argument="--fasta_samples" truevalue="--fasta_samples" falsevalue="" type="boolean" checked="false" label="output the sequences of the two haplotypes of each (diploid) sample, for each locus, in FASTA format" />
+            <param name="fasta_loci" argument="--fasta_loci" truevalue="--fasta_loci" falsevalue="" type="boolean" checked="false" label="Output locus consensus sequences in FASTA format" />
+            <param name="fasta_samples" argument="--fasta_samples" truevalue="--fasta_samples" falsevalue="" type="boolean" checked="false" label="Output the sequences of the two haplotypes of each (diploid) sample, for each locus, in FASTA format" />
             <param name="vcf" argument="--vcf" truevalue="--vcf" falsevalue="" type="boolean" checked="false" label="Output results in Variant Call Format (VCF)" />
             <param name="genepop" argument="--genepop" truevalue="--genepop" falsevalue="" type="boolean" checked="false" label="Output results in GenePop Format" />
             <param name="structure" argument="--structure" truevalue="--structure" falsevalue="" type="boolean" checked="false" label="Output results in Structure Format" />
-            <param argument="--radpainter" truevalue="--radpainter" falsevalue="" type="boolean" checked="false" label="output results in fineRADstructure/RADpainter format" />
+            <param argument="--radpainter" truevalue="--radpainter" falsevalue="" type="boolean" checked="false" label="Output results in fineRADstructure/RADpainter format" />
             <!--<param name="phase" argument="\-\-phase" truevalue="\-\-phase" falsevalue="" type="boolean" checked="false" label="Output genotypes in PHASE format" />-->
             <param name="fastphase" argument="--fastphase" truevalue="--fastphase" falsevalue="" type="boolean" checked="false" label="Output genotypes in fastPHASE format" />
             <param name="plink" argument="--plink" truevalue="--plink" falsevalue="" type="boolean" checked="false" label="Output genotypes in PLINK format" />
             <!--<param name="hzar" argument="\-\-hzar" truevalue="\-\-hzar" falsevalue="" type="boolean" checked="false" label="Output genotypes in Hybrid Zone Analysis using R (HZAR) format." />-->
             <param name="phylip" argument="--phylip" truevalue="--phylip" falsevalue="" type="boolean" checked="false" label="Output nucleotides that are fixed-within, and variant among populations in Phylip format for phylogenetic tree construction" />
             <param name="phylip_var" argument="--phylip_var" truevalue="--phylip_var" falsevalue="" type="boolean" checked="false" label="Include variable sites in the phylip output encoded using IUPAC notation." />
-            <!--<param name="phylip_var_all" argument="\-\-phylip_var_all" truevalue="\-\-phylip_var_all" falsevalue="" type="boolean" checked="false" label="Include all sequence as well as variable sites in the phylip output encoded using IUPAC notation." />
-            <param name="treemix" argument="\-\-treemix" truevalue="\-\-treemix" falsevalue="" type="boolean" checked="false" label="Output SNPs in a format useable for the TreeMix program (Pickrell and Pritchard)." />-->
-            <param argument="--no_hap_exports" truevalue="--no_hap_exports" falsevalue="" type="boolean" checked="false" label="omit haplotype outputs" />
-            <param argument="--fasta_samples_raw" truevalue="--fasta_samples_raw" falsevalue="" type="boolean" checked="false" label="output all haplotypes observed in each sample, for each locus, in FASTA format" />
+            <!--<param name="phylip_var_all" argument="\-\-phylip_var_all" truevalue="\-\-phylip_var_all" falsevalue="" type="boolean" checked="false" label="Include all sequence as well as variable sites in the phylip output encoded using IUPAC notation." />-->
+            <param name="treemix" argument="--treemix" truevalue="--treemix" falsevalue="" type="boolean" checked="false" label="Output SNPs in a format useable for the TreeMix program (Pickrell and Pritchard)." />
+            <param argument="--no_hap_exports" truevalue="--no_hap_exports" falsevalue="" type="boolean" checked="false" label="Omit haplotype outputs" />
+            <param argument="--fasta_samples_raw" truevalue="--fasta_samples_raw" falsevalue="" type="boolean" checked="false" label="Output all haplotypes observed in each sample, for each locus, in FASTA format" />
         </section>
 
         <!-- Kernel-smoothing algorithm -->
         <section name="kernel_smoothing" title="Kernel smoothing" expanded="false">
             <conditional name="options_kernel">
-                <param name="kernel" type="select" label="enable kernel-smoothed calculations" >
+                <param name="kernel" type="select" label="Enable kernel-smoothed calculations" >
                     <option value="">No</option>
                     <option value="-k">For Pi, Fis, Fst, Fst', and Phi_st</option>
                     <option value="--smooth_fstats">For Fst, Fst', and Phi_st</option>
@@ -254,13 +262,13 @@
                 </param>
                 <when value=""/>
                 <when value="-k">
-                    <param argument="--sigma" type="float" value="150000" label="standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
+                    <param argument="--sigma" type="float" value="150000" label="Standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
                 </when>
                 <when value="--smooth_fstats">
-                    <param argument="--sigma" type="float" value="150000" label="standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
+                    <param argument="--sigma" type="float" value="150000" label="Standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
                 </when>
                 <when value="--smooth_popstats">
-                    <param argument="--sigma" type="float" value="150000" label="standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
+                    <param argument="--sigma" type="float" value="150000" label="Standard deviation of the kernel smoothing weight distribution" help="distance over which to average values (default 150Kb)" />
                 </when>
             </conditional>
             <conditional name="bootstrap_resampling_mode">
@@ -283,7 +291,7 @@
 
         <!-- Output options -->
         <section name="advanced_options" title="Advanced options" expanded="False">
-            <param argument="--log_fst_comp" type="boolean" checked="false" truevalue="--log_fst_comp" falsevalue="" label="log components of Fst/Phi_st calculations to a data set" />
+            <param argument="--log_fst_comp" type="boolean" checked="false" truevalue="--log_fst_comp" falsevalue="" label="Log components of Fst/Phi_st calculations to a dataset" />
         </section>
         <expand macro="in_log"/>
     </inputs>
@@ -298,7 +306,7 @@
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
                     <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
                </collection>
             </param>
@@ -317,19 +325,25 @@
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
                     <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
                </collection>
             </param>
             <param name="add_log" value="yes" />
             <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
         </test>
         <!-- test w gstacks output as input and + all outputs -->
         <test>
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
                     <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
                </collection>
             </param>
@@ -347,6 +361,7 @@
             <param name="populations_output|plink" value="yes"/>
             <param name="populations_output|structure" value="yes"/>
             <param name="populations_output|radpainter" value="yes"/>
+            <param name="populations_output|treemix" value="yes"/>
             <assert_command>
                 <has_text text="--log_fst_comp" />
             </assert_command>
@@ -376,21 +391,28 @@
             <output ftype="tabular" name="out_plink_genotypes" value="populations/populations.plink.ped" lines_diff="2"/>
             <output ftype="tabular" name="out_structure" value="populations/populations.structure" lines_diff="2"/>
             <output ftype="tabular" name="out_radpainter" value="populations/populations.haps.radpainter"/>
+            <output ftype="tabular" name="out_treemix" value="populations/populations.treemix"/>
         </test>
         <!-- test w vcf input and default options, just checking if finished -->
         <test>
             <param name="options_usage|input_type" value="vcf" />
-            <param name="options_usage|input_vcf" ftype="vcf" value="gstacks/catalog.calls.tsv"/>
+            <param name="options_usage|input_vcf" ftype="vcf" value="gstacks/catalog.calls.vcf"/>
             <param name="popmap" ftype="tabular" value="denovo_map/popmap_cstacks.tsv" />
             <param name="add_log" value="yes" />
             <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
         </test>
         <!-- test w gstacks output as input and non default filtering -->
         <test>
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
                     <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
                </collection>
             </param>
@@ -399,15 +421,57 @@
             <section name="options_filtering">
                 <param name="minperc" value="0.1"/>
                 <param name="minpop" value="2"/>
+                <param name="min_samples_overall" value="0.01"/>
+                <param name="filter_haplotype_wise" value="--filter-haplotype-wise"/>
                 <param name="minminor" value="0.01" />
                 <param name="min_mac" value="1"/>
                 <param name="max_obs_het" value="0.8" />
-                <param name="filter_single_snp" value="--write_random_snp"/>
-                <param name="blacklist" value="blacklist.tsv" ftype="tabular" />
+                <param name="blacklist" value="populations/blacklist.tsv" ftype="tabular" />
             </section>
             <assert_command>
                 <has_text text="-r 0.1" />
                 <has_text text="-p 2" />
+                <has_text text="--min-samples-overall 0.01" />
+                <has_text text="--filter-haplotype-wise" />
+                <has_text text="--min_maf 0.01" />
+                <has_text text="--min_mac 1" />
+                <has_text text="--max_obs_het 0.8" />
+                <has_text text="-B " />
+            </assert_command>
+            <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
+        </test>
+        <!-- test w gstacks output as input and non default filtering (needed because filter-haplotype-wise is incompatible with write_random_snp/write_single_snp) -->
+        <test>
+            <param name="options_usage|input_type" value="stacks" />
+            <param name="options_usage|input_aln">
+                <collection type="list">
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
+                    <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
+               </collection>
+            </param>
+            <param name="popmap" ftype="tabular" value="denovo_map/popmap_cstacks.tsv" />
+            <param name="add_log" value="yes" />
+            <section name="options_filtering">
+                <param name="minperc" value="0.1"/>
+                <param name="minpop" value="2"/>
+                <param name="min_samples_overall" value="0.01"/>
+                <param name="minminor" value="0.01" />
+                <param name="min_mac" value="1"/>
+                <param name="max_obs_het" value="0.8" />
+                <!-- since write_random_snp runs in ifinite loop switch to write_single -->
+                <param name="filter_single_snp" value="--write_single_snp"/>
+                <param name="blacklist" value="populations/blacklist.tsv" ftype="tabular" />
+            </section>
+            <assert_command>
+                <has_text text="-r 0.1" />
+                <has_text text="-p 2" />
+                <has_text text="--min-samples-overall 0.01" />
                 <has_text text="--min_maf 0.01" />
                 <has_text text="--min_mac 1" />
                 <has_text text="--max_obs_het 0.8" />
@@ -415,13 +479,19 @@
                 <has_text text="-B " />
             </assert_command>
             <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
         </test>
         <!-- test w gstacks output as input and non default merging/hwe -->
         <test>
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.vcf" />
                     <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
                </collection>
             </param>
@@ -442,14 +512,21 @@
                 <has_text text="--hwe" />
             </assert_command>
             <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
         </test>
         <!-- test w gstacks output as input and non default fstats/kernel/bootstrap -->
         <test>
             <param name="options_usage|input_type" value="stacks" />
             <param name="options_usage|input_aln">
                 <collection type="list">
-                    <element name="catalog.calls.vcf" ftype="vcf" value="gstacks/catalog.calls.tsv" />
-                    <element name="catalog.fa.gz" ftype="fasta.gz" value="gstacks/catalog.fa.gz" />
+                    <element name="catalog.calls.vcf" ftype="vcf" value="refmap/catalog.calls.vcf" />
+                    <element name="catalog.fa.gz" ftype="fasta.gz" value="refmap/catalog.fa.gz" />
                </collection>
             </param>
             <param name="popmap" ftype="tabular" value="denovo_map/popmap_cstacks.tsv" />
@@ -479,173 +556,14 @@
                 <has_text text="--bootstrap_reps 23" />
             </assert_command>
             <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="txt" name="output_log"><assert_contents><has_text text="Populations is done." /></assert_contents></output>
+            <output ftype="tabular" name="out_haplotypes"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_hapstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="txt" name="out_populations_log_distribs"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats_sum"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sumstats"><assert_contents><has_text text="" /></assert_contents></output>
+            <output ftype="tabular" name="out_sql"><assert_contents><has_text text="" /></assert_contents></output>
         </test>
-
-
-
-         <!-- TODO test wo popmap  -->
-
-    <!--        <test>
-            <param name="options_usage|input_type" value="stacks" />
-            <param name="options_usage|input_aln">
-                <collection type="list">
-                    <element name="batch_1.catalog.alleles.tsv" ftype="tabular" value="genotypes/batch_1.catalog.alleles.tsv" />
-                    <element name="batch_1.catalog.snps.tsv" ftype="tabular" value="genotypes/batch_1.catalog.snps.tsv" />
-                    <element name="batch_1.catalog.tags.tsv" ftype="tabular" value="genotypes/batch_1.catalog.tags.tsv" />
-                    <element name="PopA_01.alleles.tsv" ftype="tabular" value="genotypes/PopA_01.alleles.tsv" />
-                    <element name="PopA_01.matches.tsv" ftype="tabular" value="genotypes/PopA_01.matches.tsv" />
-                    <element name="PopA_01.snps.tsv" ftype="tabular" value="genotypes/PopA_01.snps.tsv" />
-                    <element name="PopA_01.tags.tsv" ftype="tabular" value="genotypes/PopA_01.tags.tsv" />
-                    <element name="PopA_02.alleles.tsv" ftype="tabular" value="genotypes/PopA_02.alleles.tsv" />
-                    <element name="PopA_02.matches.tsv" ftype="tabular" value="genotypes/PopA_02.matches.tsv" />
-                    <element name="PopA_02.snps.tsv" ftype="tabular" value="genotypes/PopA_02.snps.tsv" />
-                    <element name="PopA_02.tags.tsv" ftype="tabular" value="genotypes/PopA_02.tags.tsv" />
-               </collection>
-            </param>
-            <param name="popmap" ftype="tabular" value="denovo_map/popmap.tsv" />
-            <param name="fstats_conditional|fstat" value="yes" />
-            <param name="fstats_conditional|correction_select|correction" value="p_value" />
-
-            <param name="populations_output|ordered_export" value="true" />
-            <param name="populations_output|vcf" value="true" />
-            <param name="populations_output|vcf_haplotypes" value="true" />
-            <param name="populations_output|genepop" value="true" />
-            <param name="populations_output|structure" value="true" />
-            <param name="populations_output|fasta_loci" value="true" />
-            <param name="populations_output|fasta_samples" value="true" />
-            <param name="populations_output|hzar" value="true" />
-            <param name="populations_output|phase" value="true" />
-            <param name="populations_output|fastphase" value="true" />
-            <param name="populations_output|beagle" value="true" />
-            <param name="populations_output|beagle_phased" value="true" />
-            <param name="populations_output|plink" value="true" />
-            <param name="populations_output|phylip" value="true" />
-            <param name="populations_output|phylip_var" value="true" />
-            <param name="populations_output|phylip_var_all" value="true" />
-            <param name="populations_output|treemix" value="true" />
-
-            <param name="merge_phase|enzyme" value="ecoRI" />
-
-            <output name="output_summary">
-                <assert_contents>
-                    <has_text text="Stacks Statistics" />
-                </assert_contents>
-            </output>
-
-            <output name="out_haplotypes">
-                <assert_contents>
-                    <has_text text="PopA_01" />
-                </assert_contents>
-            </output>
-            <output name="out_hapstats">
-                <assert_contents>
-                    <has_text text="Smoothed Gene Diversity" />
-                </assert_contents>
-            </output>
-            <output name="out_populations_log">
-                <assert_contents>
-                    <has_text text="populations version" />
-                </assert_contents>
-            </output>
-            <output name="out_sumstats_sum">
-                <assert_contents>
-                    <has_text text="Polymorphic Sites" />
-                </assert_contents>
-            </output>
-            <output name="out_sumstats">
-                <assert_contents>
-                    <has_text text="Smoothed Pi" />
-                </assert_contents>
-            </output>
-            <output name="out_vcf">
-                <assert_contents>
-                    <has_text text="fileformat=VCFv4.2" />
-                </assert_contents>
-            </output>
-            <output name="out_treemix_pop">
-                <assert_contents>
-                    <has_text text="TreeMix v1.1;" />
-                </assert_contents>
-            </output>
-            <output name="out_fasta">
-                <assert_contents>
-                    <has_text text="AATTCGTTTGCTGCTTCAGGAATCTCTCGTATAATCTGAGTATGTGCGTACGTACGCTATTTAGATGGATAACCGACGCTGCCAGACGCGAGAC" />
-                </assert_contents>
-            </output>
-        </test>
-        <test>
-            <param name="options_usage|input_type" value="vcf" />
-            <param name="options_usage|input_vcf" value="populations/batch_1.vcf" />
-            <param name="popmap" ftype="tabular" value="denovo_map/popmap.tsv" />
-            <param name="options_filtering|correction_select|correction" value="p_value" />
-
-            <param name="populations_output|ordered_export" value="true" />
-            <param name="populations_output|vcf" value="true" />
-            <param name="populations_output|vcf_haplotypes" value="true" />
-            <param name="populations_output|genepop" value="true" />
-            <param name="populations_output|structure" value="true" />
-            <param name="populations_output|fasta_loci" value="true" />
-            <param name="populations_output|fasta_samples" value="true" />
-            <param name="populations_output|hzar" value="true" />
-            <param name="populations_output|phase" value="true" />
-            <param name="populations_output|fastphase" value="true" />
-            <param name="populations_output|beagle" value="true" />
-            <param name="populations_output|beagle_phased" value="true" />
-            <param name="populations_output|plink" value="true" />
-            <param name="populations_output|phylip" value="true" />
-            <param name="populations_output|phylip_var" value="true" />
-            <param name="populations_output|phylip_var_all" value="true" />
-            <param name="populations_output|treemix" value="true" />
-
-            <param name="populations_output|options_genomic|genomic" value="false" />
-
-            <output name="output_summary">
-                <assert_contents>
-                    <has_text text="Stacks Statistics" />
-                </assert_contents>
-            </output>
-
-            <output name="out_haplotypes">
-                <assert_contents>
-                    <has_text text="PopA_01" />
-                </assert_contents>
-            </output>
-            <output name="out_hapstats">
-                <assert_contents>
-                    <has_text text="Smoothed Gene Diversity" />
-                </assert_contents>
-            </output>
-            <output name="out_populations_log">
-                <assert_contents>
-                    <has_text text="populations version" />
-                </assert_contents>
-            </output>
-            <output name="out_sumstats_sum">
-                <assert_contents>
-                    <has_text text="Polymorphic Sites" />
-                </assert_contents>
-            </output>
-            <output name="out_sumstats">
-                <assert_contents>
-                    <has_text text="Smoothed Pi" />
-                </assert_contents>
-            </output>
-            <output name="out_vcf">
-                <assert_contents>
-                    <has_text text="fileformat=VCFv4.2" />
-                </assert_contents>
-            </output>
-            <output name="out_treemix_pop">
-                <assert_contents>
-                    <has_text text="TreeMix v1.1;" />
-                </assert_contents>
-            </output>
-            <output name="out_fasta">
-                <assert_contents>
-                    <has_text text="CLocus_0_Sample_1_Locus_0_Allele_1" />
-                </assert_contents>
-            </output>
-        </test>-->
     </tests>
     <help>
 <![CDATA[