changeset 6:de4c22a52df4 draft

Fixes
author florianbegusch
date Tue, 13 Aug 2019 07:46:48 -0400
parents a025a4a89e07
children 85b520815e85
files qiime2/qiime_composition_ancom.xml qiime2/qiime_dada2_denoise-paired.xml qiime2/qiime_dada2_denoise-pyro.xml qiime2/qiime_dada2_denoise-single.xml qiime2/qiime_deblur_denoise-16S.xml qiime2/qiime_deblur_denoise-other.xml qiime2/qiime_demux_filter-samples.xml qiime2/qiime_diversity_adonis.xml qiime2/qiime_diversity_alpha-group-significance.xml qiime2/qiime_diversity_alpha-phylogenetic-alt.xml qiime2/qiime_diversity_alpha-rarefaction.xml qiime2/qiime_diversity_beta-correlation.xml qiime2/qiime_diversity_beta-group-significance.xml qiime2/qiime_diversity_beta-rarefaction.xml qiime2/qiime_diversity_beta.xml qiime2/qiime_diversity_core-metrics-phylogenetic.xml qiime2/qiime_diversity_core-metrics.xml qiime2/qiime_diversity_procrustes-analysis.xml qiime2/qiime_emperor_biplot.xml qiime2/qiime_feature-classifier_classify-consensus-blast.xml qiime2/qiime_feature-classifier_classify-consensus-vsearch.xml qiime2/qiime_feature-classifier_classify-hybrid-vsearch-sklearn.xml qiime2/qiime_feature-classifier_classify-sklearn.xml qiime2/qiime_feature-classifier_extract-reads.xml qiime2/qiime_feature-classifier_fit-classifier-naive-bayes.xml qiime2/qiime_feature-table_rarefy.xml qiime2/qiime_feature-table_subsample.xml qiime2/qiime_gneiss_balance-taxonomy.xml qiime2/qiime_gneiss_dendrogram-heatmap.xml qiime2/qiime_longitudinal_feature-volatility.xml qiime2/qiime_longitudinal_first-differences.xml qiime2/qiime_longitudinal_maturity-index.xml qiime2/qiime_metadata_tabulate.xml qiime2/qiime_phylogeny_iqtree-ultrafast-bootstrap.xml qiime2/qiime_phylogeny_iqtree.xml qiime2/qiime_phylogeny_raxml.xml qiime2/qiime_quality-control_evaluate-taxonomy.xml qiime2/qiime_quality-filter_q-score.xml qiime2/qiime_rep_set.loc qiime2/qiime_sample-classifier_classify-samples-ncv.xml qiime2/qiime_sample-classifier_fit-classifier.xml qiime2/qiime_sample-classifier_fit-regressor.xml qiime2/qiime_sample-classifier_maturity-index.xml qiime2/qiime_sample-classifier_regress-samples-ncv.xml qiime2/qiime_sample-classifier_regress-samples.xml qiime2/qiime_taxa_barplot.xml qiime2/qiime_taxa_collapse.xml qiime2/qiime_taxa_filter-seqs.xml qiime2/qiime_taxa_filter-table.xml qiime2/qiime_taxonomy.loc qiime2/qiime_vsearch_uchime-denovo.xml qiime2/qiime_vsearch_uchime-ref.xml tool_data/ref_classifier.loc tool_data/ref_taxnonomy.loc tool_data_table_conf.xml.sample
diffstat 55 files changed, 655 insertions(+), 426 deletions(-) [+]
line wrap: on
line diff
--- a/qiime2/qiime_composition_ancom.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_composition_ancom.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -9,17 +9,15 @@
 
 --i-table=$itable
 
-#if $input_files_mmetadatafile:
-#def list_dict_to_string(list_dict):
-  #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
-  #for d in list_dict[1:]:
-	  #set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
-  #end for
-  #return $file_list
-#end def
+
+
+#if $metadatafile:
+ --m-metadata-file=$metadatafile
 #end if
 
---m-metadata-file=$list_dict_to_string($input_files_mmetadatafile) --m-metadata-column="$mmetadatacolumn"
+
+
+--m-metadata-column="$mmetadatacolumn"
 
 #if str($pdifferencefunction) != 'None':
 --p-difference-function=$pdifferencefunction
@@ -37,9 +35,10 @@
   ]]></command>
 	<inputs>
 		<param format="qza,no_unzip.zip" label="--i-table: FeatureTable[Composition] - The feature table to be used for ANCOM computation.  [required]" name="itable" optional="False" type="data"/>
-		<repeat name="input_files_mmetadatafile" optional="False" title="--m-metadata-file">
-			<param format="tabular" label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [required]" name="additional_input" type="data"/>
-		</repeat>
+
+		<param label="--m-metadata-file METADATA" name="metadatafile" type="data" format="tabular,qza,no_unzip.zip" optional="True" />
+
+
 		<param label="--m-metadata-column: MetadataColumn[Categorical] - Column from metadata file or artifact viewable as metadata. The categorical sample metadata column to test for differential abundance across.  [required]" name="mmetadatacolumn" optional="False" type="text"/>
 		<param label="--p-difference-function: " name="pdifferencefunction" optional="True" type="select">
 			<option selected="True" value="None">Selection is Optional</option>
--- a/qiime2/qiime_dada2_denoise-paired.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_dada2_denoise-paired.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -5,24 +5,88 @@
 		<requirement type="package" version="2019.4">qiime2</requirement>
 	</requirements>
 	<command><![CDATA[
+
+#def parse_file(file):
+	#import csv
+	#set $read = csv.reader(open($file, "r"))
+	#set $qc = 0
+	#for l in $read:
+	#if "50%" in l:
+	#set $num = 0.0
+	#for i in l[1:]:
+	#if float(i) <= 25.0
+	#set $num = i
+	#set $qc = l.index($num) - 1
+	#break
+	#end if
+	#end for
+	#end if
+#end for
+#return $qc
+#end def
+
+#def find_QC(file):
+	#set $f_file_path=str(file).split(".dat")[0] + '_files/forward-seven-number-summaries.csv'
+	#set $r_file_path=str(file).split(".dat")[0] + '_files/reverse-seven-number-summaries.csv'
+	#set $qc_f = $parse_file($f_file_path)
+	#set $qc_r = $parse_file($r_file_path)
+	#return $qc_f, $qc_r
+#end def
+
+#def find_adapters(mapping_fp):
+	#import csv
+	#set $forward = 0
+	#set $reversed = 0
+	#set $reader = csv.reader(open(str(mapping_fp)), delimiter='\t')
+	#for row in $reader:
+	#if "#" not in str(row[0]):
+	#set $forward = len(row[2])
+	#set $reversed = len(row[3])
+	#break
+	#end if
+	#end for
+#return int($forward), int($reversed)
+#end def
+
+#if str($mapping_fp) != 'None' and (int($ptrimleftf) == -1 or int($ptrimleftr) == -1):
+	#set $both_adapters = $find_adapters($mapping_fp)
+	#set $ptrimleftf=$both_adapters[0]
+	#set $ptrimleftr=$both_adapters[1]
+#end if
+
+#if str($sum_fp) != 'None' and (int($ptrunclenf) == -1 or int($ptrunclenr) == -1):
+	#set $both_qc = $find_QC($sum_fp)
+	#set $ptrunclenf=$both_qc[0]
+	#set $ptrunclenr=$both_qc[1]
+#end if
+
+
 qiime dada2 denoise-paired
 
 --i-demultiplexed-seqs=$idemultiplexedseqs
---p-trunc-len-f="$ptrunclenf"
---p-trunc-len-r="$ptrunclenr"
-#if $ptrimleftf:
+
+
+#if str($ptrunclenf):
+ --p-trunc-len-f="$ptrunclenf"
+#end if
+
+#if str($ptrunclenf):
+ --p-trunc-len-r="$ptrunclenr"
+#end if
+
+#if str($ptrimleftf):
  --p-trim-left-f=$ptrimleftf
 #end if
 
-#if $ptrimleftr:
+#if str($ptrimleftr):
  --p-trim-left-r=$ptrimleftr
 #end if
 
-#if $pmaxee:
+#if str($pmaxee):
  --p-max-ee=$pmaxee
 #end if
 
-#if $ptruncq:
+#if str($ptruncq):
  --p-trunc-q=$ptruncq
 #end if
 
@@ -30,7 +94,7 @@
  --p-chimera-method=$pchimeramethod
 #end if
 
-#if $pminfoldparentoverabundance:
+#if str($pminfoldparentoverabundance):
  --p-min-fold-parent-over-abundance=$pminfoldparentoverabundance
 #end if
 
@@ -41,7 +105,7 @@
 #end if
 
 
-#if $pnreadslearn:
+#if str($pnreadslearn):
  --p-n-reads-learn=$pnreadslearn
 #end if
 
@@ -58,6 +122,9 @@
 cp odenoisingstats.qza $odenoisingstats
 	]]></command>
 	<inputs>
+		<param format="tabular" label="Mapping file where 3rd and 4th columns must be forward and reverse primers respectively" name="mapping_fp" optional="True" type="data"/>
+		<param format="html" label="Summary file" name="sum_fp" optional="True" type="data"/>
+
 		<param format="qza,no_unzip.zip" label="--i-demultiplexed-seqs: ARTIFACT SampleData[PairedEndSequencesWithQuality] The paired-end demultiplexed sequences to be denoised.                                  [required]" name="idemultiplexedseqs" optional="False" type="data"/>
 		<param label="--p-trunc-len-f: INTEGER Position at which forward read sequences should be truncated due to decrease in quality. This truncates the 3' end of the of the input sequences, which will be the bases that were sequenced in the last cycles. Reads that are shorter than this value will be discarded. After this parameter is applied there must still be at least a 20 nucleotide overlap between the forward and reverse reads. If 0 is provided, no truncation or length filtering will be performed [required]" name="ptrunclenf" optional="False" value="" type="integer"/>
 		<param label="--p-trunc-len-r: INTEGER Position at which reverse read sequences should be truncated due to decrease in quality. This truncates the 3' end of the of the input sequences, which will be the bases that were sequenced in the last cycles. Reads that are shorter than this value will be discarded. After this parameter is applied there must still be at least a 20 nucleotide overlap between the forward and reverse reads. If 0 is provided, no truncation or length filtering will be performed [required]" name="ptrunclenr" optional="False" value="" type="integer"/>
--- a/qiime2/qiime_dada2_denoise-pyro.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_dada2_denoise-pyro.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,21 +8,24 @@
 qiime dada2 denoise-pyro
 
 --i-demultiplexed-seqs=$idemultiplexedseqs
---p-trunc-len="$ptrunclen"
 
-#if $ptrimleft:
+#if str($ptrunclen):
+ --p-trunc-len="$ptrunclen"
+#end if
+
+#if str($ptrimleft):
  --p-trim-left=$ptrimleft
 #end if
 
-#if $pmaxee:
+#if str($pmaxee):
  --p-max-ee=$pmaxee
 #end if
 
-#if $ptruncq:
+#if str($ptruncq):
  --p-trunc-q=$ptruncq
 #end if
 
-#if $pmaxlen:
+#if str($pmaxlen):
  --p-max-len=$pmaxlen
 #end if
 
@@ -30,7 +33,7 @@
  --p-chimera-method=$pchimeramethod
 #end if
 
-#if $pminfoldparentoverabundance:
+#if str($pminfoldparentoverabundance):
  --p-min-fold-parent-over-abundance=$pminfoldparentoverabundance
 #end if
 
@@ -40,11 +43,11 @@
 #end if
 
 
-#if $pnreadslearn:
+#if str($pnreadslearn):
  --p-n-reads-learn=$pnreadslearn
 #end if
 
-#if $pnohashedfeatureids:
+#if str($pnohashedfeatureids):
  --p-no-hashed-feature-ids
 #end if
 
--- a/qiime2/qiime_dada2_denoise-single.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_dada2_denoise-single.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,17 +8,20 @@
 qiime dada2 denoise-single
 
 --i-demultiplexed-seqs=$idemultiplexedseqs
---p-trunc-len="$ptrunclen"
 
-#if $ptrimleft:
+#if str($ptrunclen):
+ --p-trunc-len="$ptrunclen"
+#end if
+
+#if str($ptrimleft):
  --p-trim-left=$ptrimleft
 #end if
 
-#if $pmaxee:
+#if str($pmaxee):
  --p-max-ee=$pmaxee
 #end if
 
-#if $ptruncq:
+#if str($ptruncq):
  --p-trunc-q=$ptruncq
 #end if
 
@@ -26,7 +29,7 @@
  --p-chimera-method=$pchimeramethod
 #end if
 
-#if $pminfoldparentoverabundance:
+#if str($pminfoldparentoverabundance):
  --p-min-fold-parent-over-abundance=$pminfoldparentoverabundance
 #end if
 
@@ -36,11 +39,11 @@
 #end if
 
 
-#if $pnreadslearn:
+#if str($pnreadslearn):
  --p-n-reads-learn=$pnreadslearn
 #end if
 
-#if $pnohashedfeatureids:
+#if str($pnohashedfeatureids):
  --p-no-hashed-feature-ids
 #end if
 
--- a/qiime2/qiime_deblur_denoise-16S.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_deblur_denoise-16S.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,33 +8,38 @@
 qiime deblur denoise-16S
 
 --i-demultiplexed-seqs=$idemultiplexedseqs
---p-trim-length="$ptrimlength"
+
+
 
-#if $plefttrimlen:
+#if str($ptrimlength):
+ --p-trim-length=$ptrimlength
+#end if
+
+#if str($plefttrimlen):
  --p-left-trim-len=$plefttrimlen
 #end if
 
-#if $psamplestats:
+#if str($psamplestats):
  --p-sample-stats
 #end if
 
-#if $pmeanerror:
+#if str($pmeanerror):
  --p-mean-error=$pmeanerror
 #end if
 
-#if $pindelprob:
+#if str($pindelprob):
  --p-indel-prob=$pindelprob
 #end if
 
-#if $pindelmax:
+#if str($pindelmax):
  --p-indel-max=$pindelmax
 #end if
 
-#if $pminreads:
+#if str($pminreads):
  --p-min-reads=$pminreads
 #end if
 
-#if $pminsize:
+#if str($pminsize):
  --p-min-size=$pminsize
 #end if
 
@@ -45,7 +50,7 @@
 #end if
 
 
-#if $pnohashedfeatureids:
+#if str($pnohashedfeatureids):
  --p-no-hashed-feature-ids
 #end if
 
--- a/qiime2/qiime_deblur_denoise-other.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_deblur_denoise-other.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -9,33 +9,36 @@
 
 --i-demultiplexed-seqs=$idemultiplexedseqs
 --i-reference-seqs=$ireferenceseqs
---p-trim-length="$ptrimlength"
 
-#if $plefttrimlen:
+#if str($ptrimlength):
+ --p-trim-length="$ptrimlength"
+#end if
+
+#if str($plefttrimlen):
  --p-left-trim-len=$plefttrimlen
 #end if
 
-#if $psamplestats:
+#if str($psamplestats):
  --p-sample-stats
 #end if
 
-#if $pmeanerror:
+#if str($pmeanerror):
  --p-mean-error=$pmeanerror
 #end if
 
-#if $pindelprob:
+#if str($pindelprob):
  --p-indel-prob=$pindelprob
 #end if
 
-#if $pindelmax:
+#if str($pindelmax):
  --p-indel-max=$pindelmax
 #end if
 
-#if $pminreads:
+#if str($pminreads):
  --p-min-reads=$pminreads
 #end if
 
-#if $pminsize:
+#if str($pminsize):
  --p-min-size=$pminsize
 #end if
 
@@ -46,7 +49,7 @@
 #end if
 
 
-#if $pnohashedfeatureids:
+#if str($pnohashedfeatureids):
  --p-no-hashed-feature-ids
 #end if
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/qiime2/qiime_demux_filter-samples.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -0,0 +1,71 @@
+<?xml version="1.0" ?>
+<tool id="qiime_demux_filter-samples" name="qiime demux filter-samples" version="2019.7">
+	<description> - Filter samples out of demultiplexed data.</description>
+	<requirements>
+		<requirement type="package" version="2019.7">qiime2</requirement>
+	</requirements>
+	<command><![CDATA[
+qiime demux filter-samples 
+    
+--i-demux=$idemux
+
+
+#if $input_files_mmetadatafile:
+#def list_dict_to_string(list_dict):
+  #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
+  #for d in list_dict[1:]:
+	  #set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
+  #end for
+  #return $file_list
+#end def
+  --m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
+#end if
+
+
+
+#if '__sq__' in str($pwhere):
+  #set $pwhere_temp = $pwhere.replace('__sq__', "'")
+  #set $pwhere = $pwhere_temp
+#end if
+
+
+#if str($pwhere):
+ --p-where="$pwhere"
+#end if
+
+
+#if $pexcludeids:
+ --p-exclude-ids
+#end if
+
+#if str($citations) != 'None':
+ --citations=$citations
+#end if
+
+
+--o-filtered-demux=ofiltereddemux
+
+;
+cp ofiltereddemux.qza $ofiltereddemux
+	]]></command>
+	<inputs>
+
+		<repeat name="input_files_mmetadatafile" optional="False" title="--m-metadata-file">
+			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. Sample metadata file containing individual_id_column.  [required]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
+		</repeat>
+
+		<param format="qza,no_unzip.zip" label="--i-demux: ARTIFACT SampleData[SequencesWithQuality¹ | PairedEndSequencesWithQuality² | JoinedSequencesWithQuality³] The demultiplexed data from which samples should be filtered.                                    [required]" name="idemux" optional="False" type="data"/>
+		<param label="--p-where: TEXT       Optional SQLite WHERE clause specifying sample metadata criteria that must be met to be included in the filtered data. If not provided, all samples in `metadata` that are also in the demultiplexed data will be retained.                                 [optional]" name="pwhere" optional="True" type="text"/>
+		<param label="--p-exclude-ids: --p-no-exclude-ids Defaults to False. If True, the samples selected by the `metadata` and optional `where` parameter will be excluded from the filtered data.       [default: False]" name="pexcludeids" selected="False" type="boolean"/>
+	</inputs>
+	<outputs>
+		<data format="qza" label="${tool.name} on ${on_string}: filtereddemux.qza" name="ofiltereddemux"/>
+	</outputs>
+	<help><![CDATA[
+
+	]]></help>
+<macros>
+    <import>qiime_citation.xml</import>
+</macros>
+<expand macro="qiime_citation"/>
+</tool>
--- a/qiime2/qiime_diversity_adonis.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_adonis.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -32,7 +32,7 @@
 
 
 
-#if $ppermutations:
+#if str($ppermutations):
  --p-permutations=$ppermutations
 #end if
 
--- a/qiime2/qiime_diversity_alpha-group-significance.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_alpha-group-significance.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -14,7 +14,7 @@
 #def list_dict_to_string(list_dict):
 #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
 #for d in list_dict[1:]:
-	#set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
+	#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
 #end for
 #return $file_list
 #end def
@@ -39,26 +39,16 @@
 		<data format="html" label="${tool.name} on ${on_string}: visualization.qzv" name="ovisualization"/>
 	</outputs>
 	<help><![CDATA[
-Beta diversity group significance
-#################################
+Alpha diversity comparisons
 
-Determine whether groups of samples are significantly different from one
-another using a permutation-based statistical test.
+Visually and statistically compare groups of alpha diversity values.
 
 Parameters
 ----------
-distance_matrix : DistanceMatrix
-    Matrix of distances between pairs of samples.
-metadata : MetadataColumn[Categorical]
-    Categorical sample metadata column.
-method : Str % Choices('permanova', 'anosim', 'permdisp'), optional
-    The group significance test to be applied.
-pairwise : Bool, optional
-    Perform pairwise tests between all pairs of groups in addition to the
-    test across all groups. This can be very slow if there are a lot of
-    groups in the metadata column.
-permutations : Int, optional
-    The number of permutations to be run when computing p-values.
+alpha_diversity : SampleData[AlphaDiversity]
+    Vector of alpha diversity values by sample.
+metadata : Metadata
+    The sample metadata.
 
 Returns
 -------
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/qiime2/qiime_diversity_alpha-phylogenetic-alt.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -0,0 +1,37 @@
+<?xml version="1.0" ?>
+<tool id="qiime_diversity_alpha-phylogenetic-alt" name="qiime diversity alpha-phylogenetic-alt" version="2019.7">
+	<description> - Alpha diversity (phylogenetic) - alternative implementation</description>
+	<requirements>
+		<requirement type="package" version="2019.7">qiime2</requirement>
+	</requirements>
+	<command><![CDATA[
+qiime diversity alpha-phylogenetic-alt
+
+--i-table=$itable
+--i-phylogeny=$iphylogeny
+
+--p-metric=$pmetric
+
+--o-alpha-diversity=oalphadiversity
+
+;
+cp oalphadiversity.qza $oalphadiversity
+	]]></command>
+	<inputs>
+		<param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] The feature table containing the samples for which alpha diversity should be computed.       [required]" name="itable" optional="False" type="data"/>
+		<param format="qza,no_unzip.zip" label="--i-phylogeny: ARTIFACT  Phylogenetic tree containing tip identifiers that Phylogeny[Rooted]     correspond to the feature identifiers in the table. This tree can contain tip ids that are not present in the table, but all feature ids in the table must be present in this tree.                  [required]" name="iphylogeny" optional="False" type="data"/>
+		<param label="--p-metric: " name="pmetric" optional="False" type="select">
+			<option value="faith_pd">faith_pd</option>
+		</param>
+	</inputs>
+	<outputs>
+		<data format="qza" label="${tool.name} on ${on_string}: alphadiversity.qza" name="oalphadiversity"/>
+	</outputs>
+	<help><![CDATA[
+
+	]]></help>
+<macros>
+    <import>qiime_citation.xml</import>
+</macros>
+<expand macro="qiime_citation"/>
+</tool>
--- a/qiime2/qiime_diversity_alpha-rarefaction.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_alpha-rarefaction.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,7 +8,11 @@
 qiime diversity alpha-rarefaction
 
 --i-table=$itable
---p-max-depth="$pmaxdepth"
+
+
+#if str($pmaxdepth):
+ --p-max-depth="$pmaxdepth"
+#end if
 
 #if str($iphylogeny) != 'None':
  --i-phylogeny=$iphylogeny
@@ -19,15 +23,15 @@
 #end if
 
 
-#if $pmindepth:
+#if str($pmindepth):
  --p-min-depth=$pmindepth
 #end if
 
-#if $psteps:
+#if str($psteps):
  --p-steps=$psteps
 #end if
 
-#if $piterations:
+#if str($piterations):
  --p-iterations=$piterations
 #end if
 
@@ -35,7 +39,7 @@
 #def list_dict_to_string(list_dict):
 #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
 #for d in list_dict[1:]:
-	#set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
+	#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
 #end for
 #return $file_list
 #end def
--- a/qiime2/qiime_diversity_beta-correlation.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_beta-correlation.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -24,11 +24,11 @@
  --p-method=$pmethod
 #end if
 
-#if $ppermutations:
+#if str($ppermutations):
  --p-permutations=$ppermutations
 #end if
 
-#if $pintersectids:
+#if str($pintersectids):
  --p-intersect-ids
 #end if
 
@@ -57,17 +57,13 @@
 
 
 
-#if $input_files_mmetadatafile:
-#def list_dict_to_string(list_dict):
-#set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
-#for d in list_dict[1:]:
-	#set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
-#end for
-#return $file_list
-#end def
---m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
+#if $metadatafile:
+ --m-metadata-file=$metadatafile
 #end if
 
+
+
+
 --o-metadata-distance-matrix=ometadatadistancematrix
 --o-mantel-scatter-visualization=omantelscattervisualization
 ;
@@ -88,9 +84,9 @@
 		<param label="--p-intersect-ids: --p-no-intersect-ids If supplied, IDs that are not found in both distance matrices will be discarded before applying the Mantel test. Default behavior is to error on any mismatched IDs.                                   [default: False]" name="pintersectids" selected="False" type="boolean"/>
 		<param label="--p-label1: TEXT      Label for `distance-matrix` in the output visualization.                    [default: 'Metadata']" name="plabel1" optional="True" type="text" value="Metadata"/>
 		<param label="--p-label2: TEXT      Label for `metadata-distance-matrix` in the output visualization.             [default: 'Distance Matrix']" name="plabel2" optional="True" type="text" value="Distance Matrix"/>
-		<repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file  [required]">
-			<param label="--m-metadata-file" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
-		</repeat>
+
+		<param label="--m-metadata-file METADATA" name="metadatafile" type="data" format="tabular,qza,no_unzip.zip" optional="True" />
+
 	</inputs>
 	<outputs>
 		<data format="qza" label="${tool.name} on ${on_string}: metadatadistancematrix.qza" name="ometadatadistancematrix"/>
--- a/qiime2/qiime_diversity_beta-group-significance.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_beta-group-significance.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -12,19 +12,11 @@
 
 
 
-#if $input_files_mmetadatafile:
-#def list_dict_to_string(list_dict):
-	#set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
-	#for d in list_dict[1:]:
-		#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
-	#end for
-	#return $file_list
-#end def
- --m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
+#if $metadatafile:
+ --m-metadata-file=$metadatafile
 #end if
 
 
-
 #if str($pmethod) != 'None':
  --p-method=$pmethod
 #end if
@@ -33,7 +25,7 @@
  --p-pairwise
 #end if
 
-#if $ppermutations:
+#if str($ppermutations):
  --p-permutations=$ppermutations
 #end if
 
@@ -55,9 +47,7 @@
 		<param label="--p-pairwise: --p-no-pairwise Perform pairwise tests between all pairs of groups in addition to the test across all groups. This can be very slow if there are a lot of groups in the metadata column.                                [default: False]" name="ppairwise" selected="False" type="boolean"/>
 		<param label="--p-permutations: INTEGER The number of permutations to be run when computing p-values.                                [default: 999]" name="ppermutations" optional="True" type="integer" value="999"/>
 
-		<repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file [required]">
-			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [optional]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
-		</repeat>
+		<param label="--m-metadata-file METADATA [required]" name="metadatafile" type="data" format="tabular,qza,no_unzip.zip" optional="False" />
 	</inputs>
 	<outputs>
 		<data format="html" label="${tool.name} on ${on_string}: visualization.qzv" name="ovisualization"/>
--- a/qiime2/qiime_diversity_beta-rarefaction.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_beta-rarefaction.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,15 +8,20 @@
 qiime diversity beta-rarefaction
 
 --i-table=$itable
+
 --p-metric=$pmetric
+
 --p-clustering-method=$pclusteringmethod
---p-sampling-depth="$psamplingdepth"
+
+#if str($psamplingdepth):
+ --p-sampling-depth="$psamplingdepth"
+#end if
 
 #if str($iphylogeny) != 'None':
  --i-phylogeny=$iphylogeny
 #end if
 
-#if $piterations:
+#if str($piterations):
  --p-iterations=$piterations
 #end if
 
--- a/qiime2/qiime_diversity_beta.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_beta.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,9 +8,10 @@
 qiime diversity beta
 
 --i-table=$itable
+
 --p-metric=$pmetric
 
-#if $ppseudocount:
+#if str($ppseudocount):
  --p-pseudocount=$ppseudocount
 #end if
 
--- a/qiime2/qiime_diversity_core-metrics-phylogenetic.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_core-metrics-phylogenetic.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -9,7 +9,10 @@
 
 --i-table=$itable
 --i-phylogeny=$iphylogeny
---p-sampling-depth="$psamplingdepth"
+
+#if str($psamplingdepth):
+ --p-sampling-depth="$psamplingdepth"
+#end if
 
 #set $pnjobs = '${GALAXY_SLOTS:-4}'
 #if str($pnjobs):
@@ -21,7 +24,7 @@
 #def list_dict_to_string(list_dict):
 #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
 #for d in list_dict[1:]:
-	#set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
+	#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
 #end for
 #return $file_list
 #end def
--- a/qiime2/qiime_diversity_core-metrics.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_core-metrics.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,7 +8,10 @@
 qiime diversity core-metrics
 
 --i-table=$itable
---p-sampling-depth="$psamplingdepth"
+
+#if str($psamplingdepth):
+ --p-sampling-depth="$psamplingdepth"
+#end if
 
 #set $pnjobs = '${GALAXY_SLOTS:-4}'
 #if str($pnjobs):
--- a/qiime2/qiime_diversity_procrustes-analysis.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_diversity_procrustes-analysis.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -10,7 +10,7 @@
 --i-reference=$ireference
 --i-other=$iother
 
-#if $pdimensions:
+#if str($pdimensions):
  --p-dimensions=$pdimensions
 #end if
 
--- a/qiime2/qiime_emperor_biplot.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_emperor_biplot.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -40,7 +40,7 @@
  --p-ignore-missing-samples
 #end if
 
-#if $pnumberoffeatures:
+#if str($pnumberoffeatures):
  --p-number-of-features=$pnumberoffeatures
 #end if
  
--- a/qiime2/qiime_feature-classifier_classify-consensus-blast.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-classifier_classify-consensus-blast.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -19,15 +19,15 @@
 #end if
 
 
-#if $pmaxaccepts:
+#if str($pmaxaccepts):
  --p-maxaccepts=$pmaxaccepts
 #end if
 
-#if $ppercidentity:
+#if str($ppercidentity):
  --p-perc-identity=$ppercidentity
 #end if
 
-#if $pquerycov:
+#if str($pquerycov):
  --p-query-cov=$pquerycov
 #end if
 
@@ -35,11 +35,11 @@
  --p-strand=$pstrand
 #end if
 
-#if $pevalue:
+#if str($pevalue):
  --p-evalue=$pevalue
 #end if
 
-#if $pminconsensus:
+#if str($pminconsensus):
  --p-min-consensus=$pminconsensus
 #end if
 
--- a/qiime2/qiime_feature-classifier_classify-consensus-vsearch.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-classifier_classify-consensus-vsearch.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -21,15 +21,15 @@
 
 
 
-#if $pmaxaccepts:
+#if str($pmaxaccepts):
  --p-maxaccepts=$pmaxaccepts
 #end if
 
-#if $ppercidentity:
+#if str($ppercidentity):
  --p-perc-identity=$ppercidentity
 #end if
 
-#if $pquerycov:
+#if str($pquerycov):
  --p-query-cov=$pquerycov
 #end if
 
@@ -37,7 +37,7 @@
  --p-strand=$pstrand
 #end if
 
-#if $pminconsensus:
+#if str($pminconsensus):
  --p-min-consensus=$pminconsensus
 #end if
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/qiime2/qiime_feature-classifier_classify-hybrid-vsearch-sklearn.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -0,0 +1,116 @@
+<?xml version="1.0" ?>
+<tool id="qiime_feature-classifier_classify-hybrid-vsearch-sklearn" name="qiime feature-classifier classify-hybrid-vsearch-sklearn" version="2019.7">
+	<description> -  ALPHA Hybrid classifier: VSEARCH exact match + sklearn classifier</description>
+	<requirements>
+		<requirement type="package" version="2019.7">qiime2</requirement>
+	</requirements>
+	<command><![CDATA[
+qiime feature-classifier classify-hybrid-vsearch-sklearn
+    
+--i-query=$iquery
+--i-reference-reads=$ireferencereads
+--i-reference-taxonomy=$ireferencetaxonomy
+--i-classifier=$iclassifier
+
+#if str($pmaxaccepts) != 'None':
+ --p-maxaccepts=$pmaxaccepts
+#end if
+
+#if str($ppercidentity):
+ --p-perc-identity=$ppercidentity
+#end if
+
+#if str($pquerycov):
+ --p-query-cov=$pquerycov
+#end if
+
+#if str($pstrand) != 'None':
+ --p-strand=$pstrand
+#end if
+
+#if str($pminconsensus):
+ --p-min-consensus=$pminconsensus
+#end if
+
+#if str($pconfidence) != 'None':
+ --p-confidence=$pconfidence
+#end if
+
+#if str($preadorientation) != 'None':
+ --p-read-orientation=$preadorientation
+#end if
+
+#set $pthreads = '${GALAXY_SLOTS:-4}'
+
+#if str($pthreads):
+
+#if str($pthreads):
+ --p-threads="$pthreads"
+#end if
+
+#end if
+
+
+#if $pprefilter:
+ --p-prefilter
+#end if
+
+#if str($psamplesize):
+ --p-sample-size=$psamplesize
+#end if
+
+#if str($prandseed):
+ --p-randseed=$prandseed
+#end if
+
+
+--o-classification=oclassification
+
+;
+cp oclassification.qza $oclassification
+	]]></command>
+	<inputs>
+		<param format="qza,no_unzip.zip" label="--i-query: ARTIFACT FeatureData[Sequence] Sequences to classify taxonomically.        [required]" name="iquery" optional="False" type="data"/>
+		<param format="qza,no_unzip.zip" label="--i-reference-reads: ARTIFACT FeatureData[Sequence] reference sequences.                        [required]" name="ireferencereads" optional="False" type="data"/>
+		<param format="qza,no_unzip.zip" label="--i-reference-taxonomy: ARTIFACT FeatureData[Taxonomy] reference taxonomy labels.                  [required]" name="ireferencetaxonomy" optional="False" type="data"/>
+		<param format="qza,no_unzip.zip" label="--i-classifier: ARTIFACT TaxonomicClassifier Pre-trained sklearn taxonomic classifier for classifying the reads.                      [required]" name="iclassifier" optional="False" type="data"/>
+		<param label="--p-maxaccepts: " name="pmaxaccepts" optional="True" type="select">
+			<option selected="True" value="None">Selection is Optional</option>
+			<option value="Int % Range(1">Int % Range(1</option>
+			<option value="None">None</option>
+		</param>
+		<param label="--p-perc-identity: PROPORTION Range(0.0, 1.0, inclusive_end=True) Percent sequence similarity to use for PREFILTER. Reject match if percent identity to query is lower. Set to a lower value to perform a rough pre-filter. This parameter is ignored if `prefilter` is disabled. [default: 0.5]" name="ppercidentity" optional="True" type="float" value="0.5"/>
+		<param label="--p-query-cov: PROPORTION Range(0.0, 1.0, inclusive_end=True) Query coverage threshold to use for PREFILTER. Reject match if query alignment coverage per high-scoring pair is lower. Set to a lower value to perform a rough pre-filter. This parameter is ignored if `prefilter` is disabled.                            [default: 0.8]" name="pquerycov" optional="True" type="float" value="0.8"/>
+		<param label="--p-strand: " name="pstrand" optional="True" type="select">
+			<option selected="True" value="None">Selection is Optional</option>
+			<option value="both">both</option>
+			<option value="plus">plus</option>
+		</param>
+		<param label="--p-min-consensus: NUMBER Range(0.5, 1.0, inclusive_start=False, inclusive_end=True) Minimum fraction of assignments must match top hit to be accepted as consensus assignment.   [default: 0.51]" name="pminconsensus" optional="True" type="float" value="0.51"/>
+		<param label="--p-confidence: " name="pconfidence" optional="True" type="select">
+			<option selected="True" value="None">Selection is Optional</option>
+			<option value="Float % Range(0">Float % Range(0</option>
+			<option value="1">1</option>
+			<option value="inclusive_end=True">inclusive_end=True</option>
+		</param>
+		<param label="--p-read-orientation: " name="preadorientation" optional="True" type="select">
+			<option selected="True" value="None">Selection is Optional</option>
+			<option value="same">same</option>
+			<option value="reverse-complement">reverse-complement</option>
+			<option value="auto">auto</option>
+		</param>
+		<param label="--p-prefilter: --p-no-prefilter Toggle positive filter of query sequences on or off. [default: True]" name="pprefilter" selected="False" type="boolean"/>
+		<param label="--p-sample-size: INTEGER Range(1, None)      Randomly extract the given number of sequences from the reference database to use for prefiltering. This parameter is ignored if `prefilter` is disabled. [default: 1000]" name="psamplesize" optional="True" type="integer" value="1000"/>
+		<param label="--p-randseed: INTEGER  Use integer as a seed for the pseudo-random generator Range(0, None)      used during prefiltering. A given seed always produces the same output, which is useful for replicability. Set to 0 to use a pseudo-random seed. This parameter is ignored if `prefilter` is disabled.    [default: 0]" name="prandseed" optional="True" type="integer" value="0"/>
+	</inputs>
+	<outputs>
+		<data format="qza" label="${tool.name} on ${on_string}: classification.qza" name="oclassification"/>
+	</outputs>
+	<help><![CDATA[
+
+	]]></help>
+<macros>
+    <import>qiime_citation.xml</import>
+</macros>
+<expand macro="qiime_citation"/>
+</tool>
--- a/qiime2/qiime_feature-classifier_classify-sklearn.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-classifier_classify-sklearn.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,8 +7,17 @@
 	<command><![CDATA[
 qiime feature-classifier classify-sklearn
 
+
+#if str( $id_to_classifier_fp.selector ) == 'history'
+#set $classifier = $id_to_classifier_fp.classifier_fp
+--i-classifier '$classifier'
+#else:
+#set $classifier = $id_to_classifier_fp.classifier_fp.fields.path
+--i-classifier '$classifier'
+#end if
+
+
 --i-reads=$ireads
---i-classifier=$iclassifier
 
 #set $pnjobs = '${GALAXY_SLOTS:-4}'
 
@@ -17,8 +26,10 @@
 #end if
 
 
-#if $pconfidence:
- --p-confidence=$pconfidence
+#if str($pconfidence) != '':
+  #if float($pconfidence) >= 0.0:
+	--p-confidence=$pconfidence
+  #end if
 #end if
 
 #if str($preadorientation) != 'None':
@@ -30,8 +41,22 @@
 cp oclassification.qza $oclassification
 	]]></command>
 	<inputs>
+		<conditional name="id_to_classifier_fp" optional="True">
+		   <param name="selector" type="select" label="Reference classifier to query">
+			  <option value="cached">Public classifiers</option>
+			  <option value="history">Classifiers from your history</option>
+		   </param>
+		   <when value="cached">
+			  <param name="classifier_fp" label="Reference classifier" type="select" optional="True">
+				 <options from_data_table="qiime_rep_set" />
+			  </param>
+		   </when>
+		   <when value="history">
+			  <param name="classifier_fp" type="data" format="qza,no_unzip.zip" label="Reference classifier" optional="True" />
+		   </when>
+		</conditional>
+
 		<param format="qza,no_unzip.zip" label="--i-reads: ARTIFACT FeatureData[Sequence] The feature data to be classified.         [required]" name="ireads" optional="False" type="data"/>
-		<param format="qza,no_unzip.zip" label="--i-classifier: ARTIFACT TaxonomicClassifier  The taxonomic classifier for classifying the reads. [required]" name="iclassifier" optional="False" type="data"/>
 		<param label="--p-confidence: NUMBER  Confidence threshold for limiting taxonomic depth. Provide -1 to disable confidence calculation, or 0 to calculate confidence but not apply it to limit the taxonomic depth of the assignments.    [default: 0.7]" name="pconfidence" optional="True" type="float" value="0.7"/>
 		<param label="--p-read-orientation: " name="preadorientation" optional="True" type="select">
 			<option selected="True" value="None">Selection is Optional</option>
--- a/qiime2/qiime_feature-classifier_extract-reads.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-classifier_extract-reads.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -5,9 +5,21 @@
 		<requirement type="package" version="2019.4">qiime2</requirement>
 	</requirements>
 	<command><![CDATA[
+
+
+#if str( $input_sequences.selector ) == 'history'
+	#set $seq = $input_sequences.i_sequences
+
+#else:
+	qiime tools import --type 'FeatureData[Sequence]' --input-path '$input_sequences.i_sequences.fields.path' --output-path database.qza;
+	#set $seq = 'database.qza'
+#end if
+
+
 qiime feature-classifier extract-reads
 
---i-sequences=$isequences
+--i-sequences=$seq
+
 --p-f-primer="$pfprimer"
 --p-r-primer="$prprimer"
 
@@ -36,7 +48,21 @@
 cp oreads.qza $oreads
 	]]></command>
 	<inputs>
-		<param format="qza,no_unzip.zip" label="--i-sequences: ARTIFACT FeatureData[Sequence] [required]" name="isequences" optional="False" type="data"/>
+		<conditional name="input_sequences" optional="False">
+		   <param name="selector" type="select" label="--i-sequences: FeatureData[Sequence] [required] - Reference sequences to query">
+			  <option value="cached">Public databases</option>
+			  <option value="history">Databases from your history</option>
+		   </param>
+		   <when value="cached">
+			  <param name="i_sequences" label="--i-sequences: FeatureData[Sequence] [required] - Reference sequences" type="select" optional="True">
+				 <options from_data_table="qiime_rep_set" />
+			  </param>
+		   </when>
+		   <when value="history">
+			  <param name="i_sequences" type="data" format="qza,no_unzip.zip" label="Reference databases" optional="True" />
+		   </when>
+		</conditional>
+
 		<param label="--p-f-primer: TEXT       forward primer sequence                   [required]" name="pfprimer" optional="False" type="text"/>
 		<param label="--p-r-primer: TEXT       reverse primer sequence                   [required]" name="prprimer" optional="False" type="text"/>
 		<param label="--p-trunc-len: INTEGER   read is cut to trunc-len if trunc-len is positive. Applied before trim-left.               [default: 0]" name="ptrunclen" optional="True" type="integer" value="0"/>
--- a/qiime2/qiime_feature-classifier_fit-classifier-naive-bayes.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-classifier_fit-classifier-naive-bayes.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -5,29 +5,34 @@
 		<requirement type="package" version="2019.4">qiime2</requirement>
 	</requirements>
 	<command><![CDATA[
-qiime feature-classifier fit-classifier-naive-bayes
-
---i-reference-reads=$ireferencereads
 
 
 #if str( $id_to_taxonomy_fp.selector ) == 'history'
 	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
-	--i-reference-taxonomy '$tax'
 #else:
-	#set $tax = $id_to_taxonomy_fp.taxonomy_fp.fields.path
-	--i-reference-taxonomy '$tax'
+	#set $tax_path = $id_to_taxonomy_fp.taxonomy_fp.fields.path
+	qiime tools import --type 'FeatureData[Taxonomy]'  --source-format HeaderlessTSVTaxonomyFormat --input-path $tax_path --output-path ref-taxonomy.qza;
+	#set $tax='ref-taxonomy.qza'
 #end if
 
 
+qiime feature-classifier fit-classifier-naive-bayes
+
+
+--i-reference-taxonomy '$tax'
+
+
+--i-reference-reads=$ireferencereads
+
 #if str($iclassweight) != 'None':
  --i-class-weight=$iclassweight
 #end if
 
-#if $pclassifyalpha:
+#if str($pclassifyalpha):
  --p-classify--alpha=$pclassifyalpha
 #end if
 
-#if $pclassifychunksize:
+#if str($pclassifychunksize):
  --p-classify--chunk-size=$pclassifychunksize
 #end if
 
@@ -119,7 +124,7 @@
  --p-no-feat-ext--lowercase
 #end if
 
-#if $pfeatextnfeatures:
+#if str($pfeatextnfeatures):
  --p-feat-ext--n-features=$pfeatextnfeatures
 #end if
 
--- a/qiime2/qiime_feature-table_rarefy.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-table_rarefy.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,7 +8,10 @@
 qiime feature-table rarefy
 
 --i-table=$itable
---p-sampling-depth="$psamplingdepth"
+
+#if str($psamplingdepth):
+ --p-sampling-depth="$psamplingdepth"
+#end if
 
 #if $pwithreplacement:
  --p-with-replacement
--- a/qiime2/qiime_feature-table_subsample.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_feature-table_subsample.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,7 +8,11 @@
 qiime feature-table subsample
 
 --i-table=$itable
---p-subsampling-depth="$psubsamplingdepth"
+
+#if str($psubsamplingdepth):
+ --p-subsampling-depth="$psubsamplingdepth"
+#end if
+
 --p-axis=$paxis
 
 --o-sampled-table=osampledtable
--- a/qiime2/qiime_gneiss_balance-taxonomy.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_gneiss_balance-taxonomy.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,33 +7,37 @@
 	<command><![CDATA[
 qiime gneiss balance-taxonomy
 
+
+#if str( $id_to_taxonomy_fp.selector ) == 'history'
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
+	--i-taxonomy '$tax'
+#else:
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp.fields.path
+	--i-taxonomy '$tax'
+#end if
+
+
 --i-table=$itable
 --i-tree=$itree
---i-taxonomy=$itaxonomy
 --p-balance-name="$pbalancename"
 
 
-#if $input_files_mmetadatafile:
-#def list_dict_to_string(list_dict):
-	#set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
-	#for d in list_dict[1:]:
-		#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
-	#end for
-	#return $file_list
-#end def
- --m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
+
+#if $metadatafile:
+ --m-metadata-file=$metadatafile
 #end if
 
 
-#if $ppseudocount:
+
+#if str($ppseudocount):
  --p-pseudocount=$ppseudocount
 #end if
 
-#if $ptaxalevel:
+#if str($ptaxalevel):
  --p-taxa-level=$ptaxalevel
 #end if
 
-#if $pnfeatures:
+#if str($pnfeatures):
  --p-n-features=$pnfeatures
 #end if
 
@@ -51,6 +55,22 @@
 && mv '$ovisualization.files_path/index.html' '$ovisualization'
 	]]></command>
 	<inputs>
+
+		<conditional name="id_to_taxonomy_fp" optional="True">
+		   <param name="selector" type="select" label="Reference taxonomy to query">
+			  <option value="cached">Public databases</option>
+			  <option value="history">Databases from your history</option>
+		   </param>
+		   <when value="cached">
+			  <param argument="--taxonomy_fp" label="Reference taxonomy" type="select" optional="True">
+				 <options from_data_table="qiime_taxonomy" />
+			  </param>
+		   </when>
+		   <when value="history">
+			  <param argument="--taxonomy_fp" type="data" format="qza,no_unzip.zip" label="Reference databases" optional="True" />
+		   </when>
+		</conditional>
+
 		<param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] A table of abundances.                    [required]" name="itable" optional="False" type="data"/>
 		<param format="qza,no_unzip.zip" label="--i-tree: ARTIFACT       The tree used to calculate the balances. Hierarchy                                                       [required]" name="itree" optional="False" type="data"/>
 		<param format="qza,no_unzip.zip" label="--i-taxonomy: ARTIFACT FeatureData[Taxonomy] Taxonomy information for the OTUs.        [required]" name="itaxonomy" optional="False" type="data"/>
@@ -61,9 +81,7 @@
 		<param label="--p-threshold: NUMBER    A threshold to designate discrete categories for a numerical metadata column. This will split the numerical column values into two categories, values below the threshold, and values above the threshold. If not specified, this threshold will default to the mean.                                     [optional]" name="pthreshold" optional="True" type="float"/>
 		<param label="--m-metadata-column: COLUMN  MetadataColumn[Categorical | Numeric] Metadata column for plotting the balance (optional).                               [optional]" name="mmetadatacolumn" optional="True" type="text"/>
 
-		<repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file">
-			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [optional]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
-		</repeat>
+		<param label="--m-metadata-file METADATA" name="metadatafile" type="data" format="tabular,qza,no_unzip.zip"  optional="True" />
 
 	</inputs>
 	<outputs>
--- a/qiime2/qiime_gneiss_dendrogram-heatmap.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_gneiss_dendrogram-heatmap.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -24,11 +24,11 @@
 #end if
 
 
-#if $ppseudocount:
+#if str($ppseudocount):
  --p-pseudocount=$ppseudocount
 #end if
 
-#if $pndim:
+#if str($pndim):
  --p-ndim=$pndim
 #end if
 
--- a/qiime2/qiime_longitudinal_feature-volatility.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_longitudinal_feature-volatility.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -16,7 +16,7 @@
  --p-individual-id-column="$pindividualidcolumn"
 #end if
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
@@ -31,7 +31,7 @@
 #end if
 
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
--- a/qiime2/qiime_longitudinal_first-differences.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_longitudinal_first-differences.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -8,8 +8,17 @@
 qiime longitudinal first-differences
 
 --p-state-column="$pstatecolumn"
+--p-metric="$pmetric"
+
+
+
+#if '__pd__' in str($pindividualidcolumn):
+	#set $pwhere_temp = $pindividualidcolumn.replace('__pd__', "#")
+	#set $pindividualidcolumn = $pwhere_temp
+#end if
 --p-individual-id-column="$pindividualidcolumn"
---p-metric="$pmetric"
+
+
 
 #if str($itable) != 'None':
  --i-table=$itable
@@ -53,7 +62,7 @@
 		</param>
 		<param label="--p-baseline: NUMBER    A value listed in the state-column metadata column against which all other states should be compared. Toggles calculation of static differences instead of first differences (which are calculated if no value is given for baseline). If a 'baseline' value is provided, sample differences at each state are compared against the baseline state, instead of the previous state. Must be a value listed in the state-column.                              [optional]" name="pbaseline" optional="True" type="float"/>
 
-		<repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file  [required]">
+		<repeat name="input_files_mmetadatafile" optional="False" title="--m-metadata-file  [required]">
 			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [optional]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
 		</repeat>
 
--- a/qiime2/qiime_longitudinal_maturity-index.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_longitudinal_maturity-index.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -20,7 +20,7 @@
  --p-estimator=$pestimator
 #end if
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
@@ -32,7 +32,7 @@
  --p-step=$pstep
 #end if
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
--- a/qiime2/qiime_metadata_tabulate.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_metadata_tabulate.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -20,7 +20,7 @@
 #end if
 
 
-#if $ppagesize:
+#if str($ppagesize):
  --p-page-size=$ppagesize
 #end if
 
--- a/qiime2/qiime_phylogeny_iqtree-ultrafast-bootstrap.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_phylogeny_iqtree-ultrafast-bootstrap.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -20,7 +20,7 @@
 #end if
 
 
-#if $pnruns:
+#if str($pnruns):
  --p-n-runs=$pnruns
 #end if
 
@@ -28,7 +28,7 @@
  --p-substitution-model=$psubstitutionmodel
 #end if
 
-#if $pbootstrapreplicates:
+#if str($pbootstrapreplicates):
  --p-bootstrap-replicates=$pbootstrapreplicates
 #end if
 
--- a/qiime2/qiime_phylogeny_iqtree.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_phylogeny_iqtree.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -19,7 +19,7 @@
  --p-n-cores="$pncores"
 #end if
 
-#if $pnruns:
+#if str($pnruns):
  --p-n-runs=$pnruns
 #end if
 
--- a/qiime2/qiime_phylogeny_raxml.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_phylogeny_raxml.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -13,7 +13,7 @@
  --p-seed="$pseed"
 #end if
 
-#if $pnsearches:
+#if str($pnsearches):
  --p-n-searches=$pnsearches
 #end if
 
--- a/qiime2/qiime_quality-control_evaluate-taxonomy.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_quality-control_evaluate-taxonomy.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -9,7 +9,10 @@
 
 --i-expected-taxa=$iexpectedtaxa
 --i-observed-taxa=$iobservedtaxa
---p-depth="$pdepth"
+
+#if str($pdepth):
+ --p-depth="$pdepth"
+#end if
 
 #if str($ifeaturetable) != 'None':
  --i-feature-table=$ifeaturetable
--- a/qiime2/qiime_quality-filter_q-score.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_quality-filter_q-score.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -9,19 +9,19 @@
 
 --i-demux=$idemux
 
-#if $pminquality:
+#if str($pminquality):
  --p-min-quality=$pminquality
 #end if
 
-#if $pqualitywindow:
+#if str($pqualitywindow):
  --p-quality-window=$pqualitywindow
 #end if
 
-#if $pminlengthfraction:
+#if str($pminlengthfraction):
  --p-min-length-fraction=$pminlengthfraction
 #end if
 
-#if $pmaxambiguous:
+#if str($pmaxambiguous):
  --p-max-ambiguous=$pmaxambiguous
 #end if
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/qiime2/qiime_rep_set.loc	Tue Aug 13 07:46:48 2019 -0400
@@ -0,0 +1,9 @@
+silva_132_release_rep_set_all_99_silva132_99	silva (132_release) - rep_set_all - 99 - 99_otus	silva_132_release_rep_set_all_99_silva132_99.fna	/home/galaxy/galaxy/tool-data/qiime_rep_set/silva_132_release_rep_set_all_99_silva132_99.fna
+silva_132_release_rep_set_all_97_silva132_97	silva (132_release) - rep_set_all - 97 - 97_otus	silva_132_release_rep_set_all_97_silva132_97.fna	/home/galaxy/galaxy/tool-data/qiime_rep_set/silva_132_release_rep_set_all_97_silva132_97.fna
+silva_128_release_rep_set_all_97_97_otus	silva (128_release) - rep_set_all - 97 - 97_otus	silva_128_release_rep_set_all_97_97_otus.fasta	/home/galaxy/galaxy/tool-data/qiime_rep_set/silva_128_release_rep_set_all_97_97_otus.fasta
+unite_20.11.2016_sh_refs_qiime_ver7_97_20.11.2016	unite (20.11.2016) - sh_refs_qiime_ver7_97_20	unite_20.11.2016_sh_refs_qiime_ver7_97_20.11.2016.fasta	/home/galaxy/galaxy/tool-data/qiime_rep_set/unite_20.11.2016_sh_refs_qiime_ver7_97_20.11.2016.fasta
+greengenes_13_8_97_otus	greengenes (13_8_relese) - 97_otus	greengenes_13_8_97_otus.fasta	/home/galaxy/galaxy/tool-data/qiime_rep_set/greengenes_13_8_97_otus.fasta
+greengenes_13_8_99_otus	greengenes (13_8_relese) - 99_otus	greengenes_13_8_99_otus.fasta	/home/galaxy/galaxy/tool-data/qiime_rep_set/greengenes_13_8_99_otus.fasta
+GreenGenes_13_8_99_V4_GTGCCAGCMGCCGCGGTAA_GGACTACHVHHHTWTCTAAT	GreenGenes_13_8_99_V4_GTGCCAGCMGCCGCGGTAA_GGACTACHVHHHTWTCTAAT	GreenGenes_13_8_99_V4_GTGCCAGCMGCCGCGGTAA_GGACTACHVHHHTWTCTAAT.qza	/home/galaxy/galaxy/tool-data/QIIME2_reference_classifiers/GreenGenes_13_8_99_V4_GTGCCAGCMGCCGCGGTAA_GGACTACHVHHHTWTCTAAT.qza
+GreenGenes_13_8_99_V4_GTGYCAGCMGCCGCGGTAA_GGACTACNVGGGTWTCTAAT	GreenGenes_13_8_99_V4_GTGYCAGCMGCCGCGGTAA_GGACTACNVGGGTWTCTAAT	GreenGenes_13_8_99_V4_GTGYCAGCMGCCGCGGTAA_GGACTACNVGGGTWTCTAAT.qza	/home/galaxy/galaxy/tool-data/QIIME2_reference_classifiers/GreenGenes_13_8_99_V4_GTGYCAGCMGCCGCGGTAA_GGACTACNVGGGTWTCTAAT.qza
+GreenGenes_13_8_97_V1_V2_AGAGTTTGATCCTGGCTCAG_CTGCTGCCTYCCGTA	GreenGenes_13_8_97_V1_V2_AGAGTTTGATCCTGGCTCAG_CTGCTGCCTYCCGTA	GreenGenes_13_8_97_V1_V2_AGAGTTTGATCCTGGCTCAG_CTGCTGCCTYCCGTA.qza	/home/galaxy/galaxy/tool-data/QIIME2_reference_classifiers/GreenGenes_13_8_97_V1_V2_AGAGTTTGATCCTGGCTCAG_CTGCTGCCTYCCGTA.qza
--- a/qiime2/qiime_sample-classifier_classify-samples-ncv.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_sample-classifier_classify-samples-ncv.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -17,7 +17,7 @@
 #end if
 
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
@@ -32,7 +32,7 @@
 #end if
 
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
--- a/qiime2/qiime_sample-classifier_fit-classifier.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_sample-classifier_fit-classifier.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -14,7 +14,7 @@
  --p-step=$pstep
 #end if
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
@@ -29,7 +29,7 @@
 #end if
 
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
--- a/qiime2/qiime_sample-classifier_fit-regressor.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_sample-classifier_fit-regressor.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -14,7 +14,7 @@
  --p-step=$pstep
 #end if
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
@@ -28,7 +28,7 @@
 #end if
 
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
--- a/qiime2/qiime_sample-classifier_maturity-index.xml	Mon Aug 05 01:29:30 2019 -0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,208 +0,0 @@
-<?xml version="1.0" ?>
-<tool id="qiime_sample-classifier_maturity-index" name="qiime sample-classifier maturity-index" version="2019.4">
-	<description> - Microbial maturity index prediction.</description>
-	<requirements>
-		<requirement type="package" version="2019.4">qiime2</requirement>
-	</requirements>
-	<command>
-	<![CDATA[
-	qiime sample-classifier maturity-index --i-table=$itable
-
-	#if $input_files_mmetadatafile:
-	#def list_dict_to_string(list_dict):
-		#set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
-		#for d in list_dict[1:]:
-			#set $file_list = $file_list + ' --m-metadata-file=' + d['additional_input'].__getattr__('file_name')
-		#end for
-		#return $file_list
-	#end def
-
-	 --m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
-	#end fi
-
-
-	--p-group-by="$pgroupby" --p-column="$pcolumn" --p-control="$pcontrol"
-
-	#set $pnjobs = '${GALAXY_SLOTS:-4}'
-
-	#if str($pnjobs):
-	 --p-n-jobs="$pnjobs"
-	#end if
-
-
-	#if $pparametertuning:
-	  --p-parameter-tuning
-	#else
-		--p-no-parameter-tuning
-	#end if
-
-	#if $pstep:
-	 --p-step=$pstep
-	#end if
-
-	#if $pstratify:
-	  --p-stratify
-	#else
-		--p-no-stratify
-	#end if
-
-	#if $poptimizefeatureselection:
-	  --p-optimize-feature-selection
-	#else
-		--p-no-optimize-feature-selection
-	#end if
-
-	#if $ptestsize:
-	 --p-test-size=$ptestsize
-	#end if
-	 --o-visualization=ovisualization
-	#if str($pestimator) != 'None':
-	 --p-estimator=$pestimator
-	#end if
-
-	#if $pmazstats:
-	  --p-maz-stats
- 	#else
- 		--p-no-maz-stats
-	#end if
-
-	#if str($cmdconfig) != 'None':
-	 --cmd-config=$cmdconfig
-	#end if
-
-	#if $pcv:
-	 --p-cv=$pcv
-	#end if
-
-	#if $pnestimators:
-	 --p-n-estimators=$pnestimators
-	#end if
-
-	#if str($prandomstate):
-	 --p-random-state="$prandomstate"
-	#end if
-	;
-	qiime tools export --input-path ovisualization.qzv --output-path out   && mkdir -p '$ovisualization.files_path'
-	&& cp -r out/* '$ovisualization.files_path'
-	&& mv '$ovisualization.files_path/index.html' '$ovisualization'
-	]]>
-	</command>
-	<inputs>
-		<param format="qza,no_unzip.zip" label="--i-table: FeatureTable[Frequency] Feature table containing all features that should be used for target prediction. [required]" name="itable" optional="False" type="data"/>
-
-		<repeat name="input_files_mmetadatafile" optional="False" title="--m-metadata-file">
-			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [required]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
-		</repeat>
-
-		<param label="--p-column: Numeric metadata column to use as prediction target.  [required]" name="pcolumn" optional="False" type="text"/>
-
-		<param label="--p-group-by: Categorical metadata column to use for plotting and significance testing between main treatment groups.  [required]" name="pgroupby" optional="False" type="text"/>
-		<param label="--p-control: Value of group_by to use as control group. The regression model will be trained using only control group data, and the maturity scores of other groups consequently will be assessed relative to this group.  [required]" name="pcontrol" optional="False" type="text"/>
-
-		<param label="--p-estimator: Regression model to use for prediction.
-                                  [default: RandomForestRegressor]" name="pestimator" optional="True" type="select">
-			<option selected="True" value="None">Selection is Optional</option>
-			<option value="Ridge">Ridge</option>
-			<option value="RandomForestRegressor">RandomForestRegressor</option>
-			<option value="GradientBoostingRegressor">GradientBoostingRegressor</option>
-			<option value="ExtraTreesRegressor">ExtraTreesRegressor</option>
-			<option value="SVR">SVR</option>
-			<option value="ElasticNet">ElasticNet</option>
-			<option value="Lasso">Lasso</option>
-		</param>
-		<param label="--p-n-estimators: Number of trees to grow for estimation. More trees will improve predictive accuracy up to a threshold level, but will also increase time and memory requirements. This parameter only affects ensemble estimators, such as Random Forest, AdaBoost, ExtraTrees, and GradientBoosting.  [default: 100]" name="pnestimators" optional="True" type="integer" value="100"/>
-
-		<param label="--p-test-size: Fraction of input samples to exclude from training set and use for classifier testing. [default: 0.2]" name="ptestsize" optional="True" type="float" value="0.2"/>
-
-		<param label="--p-step: If optimize_feature_selection is True, step is the percentage of features to remove at each iteration.  [default: 0.05]" name="pstep" optional="True" type="float" value="0.05"/>
-
-		<param label="--p-cv: Number of k-fold cross-validations to perform.  [default: 5]" name="pcv" optional="True" type="integer" value="5"/>
-
-		<param label="--p-random-state: Seed used by random number generator. [optional]" name="prandomstate" optional="True" type="text"/>
-
-		<param label="--p-parameter-tuning: --p-no-parameter-tuning Automatically tune hyperparameters using random grid search.  [default: True]" name="pparametertuning" checked="True" type="boolean"/>
-		<param label="--p-optimize-feature-selection: --p-no-optimize-feature-selection Automatically optimize input feature selection using recursive feature elimination.  [default: True]" name="poptimizefeatureselection" checked="True" type="boolean"/>
-
-		<param label="--p-stratify: --p-no-stratify  Evenly stratify training and test data among metadata categories. If True, all values in column must match at least two samples. [default: False]" name="pstratify" checked="False" type="boolean"/>
-
-		<param label="--p-maz-stats: --p-no-maz-stats Calculate anova and pairwise tests on MAZ scores.  [default: True]" name="pmazstats" checked="True" type="boolean"/>
-
-		<param label="--cmd-config: Use config file for command options" name="cmdconfig" optional="True" type="data"/>
-	</inputs>
-	<outputs>
-		<data format="html" label="${tool.name} on ${on_string}: visualization.qzv" name="ovisualization"/>
-	</outputs>
-	<help>
-		<![CDATA[
-Microbial maturity index prediction.
--------------------------------------
-
-Calculates a "microbial maturity" index from a regression model trained on
-feature data to predict a given continuous metadata column, e.g., to
-predict age as a function of microbiota composition. The model is trained
-on a subset of control group samples, then predicts the column value for
-all samples. This visualization computes maturity index z-scores to compare
-relative "maturity" between each group, as described in
-doi:10.1038/nature13421. This method can be used to predict between-group
-differences in relative trajectory across any type of continuous metadata
-gradient, e.g., intestinal microbiome development by age, microbial
-succession during wine fermentation, or microbial community differences
-along environmental gradients, as a function of two or more different
-"treatment" groups.
-
-Parameters
-----------
-table : FeatureTable[Frequency]
-    Feature table containing all features that should be used for target
-    prediction.
-metadata : Metadata
-		\
-column : Str
-    Numeric metadata column to use as prediction target.
-group_by : Str
-    Categorical metadata column to use for plotting and significance
-    testing between main treatment groups.
-control : Str
-    Value of group_by to use as control group. The regression model will be
-    trained using only control group data, and the maturity scores of other
-    groups consequently will be assessed relative to this group.
-estimator : Str % Choices({'ElasticNet', 'ExtraTreesRegressor', 'GradientBoostingRegressor', 'Lasso', 'RandomForestRegressor', 'Ridge', 'SVR'}), optional
-    Regression model to use for prediction.
-n_estimators : Int % Range(1, None), optional
-    Number of trees to grow for estimation. More trees will improve
-    predictive accuracy up to a threshold level, but will also increase
-    time and memory requirements. This parameter only affects ensemble
-    estimators, such as Random Forest, AdaBoost, ExtraTrees, and
-    GradientBoosting.
-test_size : Float % Range(0.0, 1.0, inclusive_start=False), optional
-    Fraction of input samples to exclude from training set and use for
-    classifier testing.
-step : Float % Range(0.0, 1.0, inclusive_start=False), optional
-    If optimize_feature_selection is True, step is the percentage of
-    features to remove at each iteration.
-cv : Int % Range(1, None), optional
-    Number of k-fold cross-validations to perform.
-random_state : Int, optional
-    Seed used by random number generator.
-parameter_tuning : Bool, optional
-    Automatically tune hyperparameters using random grid search.
-optimize_feature_selection : Bool, optional
-    Automatically optimize input feature selection using recursive feature
-    elimination.
-stratify : Bool, optional
-    Evenly stratify training and test data among metadata categories. If
-    True, all values in column must match at least two samples.
-maz_stats : Bool, optional
-    Calculate anova and pairwise tests on MAZ scores.
-
-Returns
--------
-visualization : Visualization
-		\
-		]]>
-	</help>
-<macros>
-	<import>qiime_citation.xml</import>
-</macros>
-<expand macro="qiime_citation" />
-</tool>
--- a/qiime2/qiime_sample-classifier_regress-samples-ncv.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_sample-classifier_regress-samples-ncv.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -10,7 +10,7 @@
 --i-table=$itable
 --m-metadata-column="$mmetadatacolumn"
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
@@ -25,7 +25,7 @@
 #end if
 
 
-#if $pnestimators:
+#if str($pnestimators):
  --p-n-estimators=$pnestimators
 #end if
 
--- a/qiime2/qiime_sample-classifier_regress-samples.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_sample-classifier_regress-samples.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -18,7 +18,7 @@
  --p-step=$pstep
 #end if
 
-#if $pcv:
+#if str($pcv):
  --p-cv=$pcv
 #end if
 
--- a/qiime2/qiime_taxa_barplot.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_taxa_barplot.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,8 +7,17 @@
 	<command><![CDATA[
 qiime taxa barplot
 
+
+#if str( $id_to_taxonomy_fp.selector ) == 'history'
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
+	--i-taxonomy '$tax'
+#else:
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp.fields.path
+	--i-taxonomy '$tax'
+#end if
+
+
 --i-table=$itable
---i-taxonomy=$itaxonomy
 
 #if $input_files_mmetadatafile:
 #def list_dict_to_string(list_dict):
@@ -28,11 +37,27 @@
 && mv '$ovisualization.files_path/index.html' '$ovisualization';
 	]]></command>
 	<inputs>
-		<param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] Feature table to visualize at various taxonomic levels.                                    [required]" name="itable" optional="False" type="data"/>
-		<param format="qza,no_unzip.zip" label="--i-taxonomy: ARTIFACT FeatureData[Taxonomy] Taxonomic annotations for features in the provided feature table. All features in the feature table must have a corresponding taxonomic annotation. Taxonomic annotations that are not present in the feature table will be ignored.                           [required]" name="itaxonomy" optional="False" type="data"/>
 
-		<repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file  [required]">
-			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [optional]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
+		<conditional name="id_to_taxonomy_fp" optional="True">
+		   <param name="selector" type="select" label="Reference taxonomy to query">
+			  <option value="cached">Public databases</option>
+			  <option value="history">Databases from your history</option>
+		   </param>
+		   <when value="cached">
+			  <param argument="--taxonomy_fp" label="Reference taxonomy" type="select" optional="True">
+				 <options from_data_table="qiime_taxonomy" />
+			  </param>
+		   </when>
+		   <when value="history">
+			  <param argument="--taxonomy_fp" type="data" format="qza,no_unzip.zip" label="Reference databases" optional="True" />
+		   </when>
+		</conditional>
+
+
+		<param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] Feature table to visualize at various taxonomic levels.                                    [required]" name="itable" optional="False" type="data"/>
+
+		<repeat name="input_files_mmetadatafile" optional="False" title="--m-metadata-file  [required]">
+			<param label="--m-metadata-file: Metadata file or artifact viewable as metadata. This option may be supplied multiple times to merge metadata. [optional]" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" optional="False" />
 		</repeat>
 
 	</inputs>
--- a/qiime2/qiime_taxa_collapse.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_taxa_collapse.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,17 +7,44 @@
 	<command><![CDATA[
 qiime taxa collapse
 
+#if str( $id_to_taxonomy_fp.selector ) == 'history'
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
+	--i-taxonomy '$tax'
+#else:
+	#set $tax = $id_to_taxonomy_fp.taxonomy_fp.fields.path
+	--i-taxonomy '$tax'
+#end if
+
+
 --i-table=$itable
---i-taxonomy=$itaxonomy
---p-level="$plevel"
+
+#if str($plevel):
+ --p-level="$plevel"
+#end if
 
 --o-collapsed-table=ocollapsedtable
 ;
 cp ocollapsedtable.qza $ocollapsedtable
 	]]></command>
 	<inputs>
+
+		<conditional name="id_to_taxonomy_fp" optional="True">
+		   <param name="selector" type="select" label="Reference taxonomy to query">
+			  <option value="cached">Public databases</option>
+			  <option value="history">Databases from your history</option>
+		   </param>
+		   <when value="cached">
+			  <param argument="--taxonomy_fp" label="Reference taxonomy" type="select" optional="True">
+				 <options from_data_table="qiime_taxonomy" />
+			  </param>
+		   </when>
+		   <when value="history">
+			  <param argument="--taxonomy_fp" type="data" format="qza,no_unzip.zip" label="Reference databases" optional="True" />
+		   </when>
+		</conditional>
+		
+
 		<param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] Feature table to be collapsed.             [required]" name="itable" optional="False" type="data"/>
-		<param format="qza,no_unzip.zip" label="--i-taxonomy: ARTIFACT FeatureData[Taxonomy] Taxonomic annotations for features in the provided feature table. All features in the feature table must have a corresponding taxonomic annotation. Taxonomic annotations that are not present in the feature table will be ignored.                           [required]" name="itaxonomy" optional="False" type="data"/>
 		<param label="--p-level: INTEGER      The taxonomic level at which the features should be collapsed. All ouput features will have exactly this many levels of taxonomic annotation.       [required]" name="plevel" optional="False" value="" type="integer"/>
 	</inputs>
 	<outputs>
--- a/qiime2/qiime_taxa_filter-seqs.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_taxa_filter-seqs.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,8 +7,6 @@
 	<command><![CDATA[
 qiime taxa filter-seqs
 
---i-sequences=$isequences
-
 
 #if str( $id_to_taxonomy_fp.selector ) == 'history'
 	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
@@ -19,6 +17,8 @@
 #end if
 
 
+--i-sequences=$isequences
+
 #if str($pinclude):
  --p-include="$pinclude"
 #end if
--- a/qiime2/qiime_taxa_filter-table.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_taxa_filter-table.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -7,8 +7,6 @@
 	<command><![CDATA[
 qiime taxa filter-table
 
---i-table=$itable
-
 
 #if str( $id_to_taxonomy_fp.selector ) == 'history'
 	#set $tax = $id_to_taxonomy_fp.taxonomy_fp
@@ -19,6 +17,8 @@
 #end if
 
 
+--i-table=$itable
+
 #if str($pinclude):
  --p-include="$pinclude"
 #end if
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/qiime2/qiime_taxonomy.loc	Tue Aug 13 07:46:48 2019 -0400
@@ -0,0 +1,8 @@
+silva_132_release_taxonomy_all_99_taxonomy_all_levels	silva (132_release) - taxonomy_all - 99 - taxonomy_all_levels	silva_132_release_taxonomy_all_99_taxonomy_all_levels.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/silva_132_release_taxonomy_all_99_taxonomy_all_levels.txt	
+silva_132_release_taxonomy_all_97_taxonomy_all_levels	silva (132_release) - taxonomy_all - 97 - taxonomy_all_levels	silva_132_release_taxonomy_all_97_taxonomy_all_levels.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/silva_132_release_taxonomy_all_97_taxonomy_all_levels.txt	
+greengenes_13_8_97_otu_taxonomy	greengenes (13_8) - 97_otu_taxonomy	greengenes_13_8_97_otu_taxonomy.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/greengenes_13_8_97_otu_taxonomy.txt	
+greengenes_13_8_99_otu_taxonomy	greengenes (13_8) - 99_otu_taxonomy	greengenes_13_8_99_otu_taxonomy.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/greengenes_13_8_99_otu_taxonomy.txt	
+silva_128_release_taxonomy_all_97_taxonomy_all_levels	silva (128_release) - taxonomy_all - 97 - taxonomy_all_levels	silva_128_release_taxonomy_all_97_taxonomy_all_levels.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/silva_128_release_taxonomy_all_97_taxonomy_all_levels.txt	
+unite_20.11.2016_sh_taxonomy_qiime_ver7_97_20.11.2016	unite (20.11.2016) - sh_taxonomy_qiime_ver7_97_20	unite_20.11.2016_sh_taxonomy_qiime_ver7_97_20.11.2016.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/unite_20.11.2016_sh_taxonomy_qiime_ver7_97_20.11.2016.txt	
+taxmap_ncbi_ssu_ref_132	taxmap_ncbi_ssu_ref_132	taxmap_ncbi_ssu_ref_132.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/taxmap_ncbi_ssu_ref_132.txt	
+taxmap_slv_ssu_ref_132	taxmap_slv_ssu_ref_132	taxmap_slv_ssu_ref_132.txt	/home/galaxy/galaxy/tool-data/qiime_taxonomy/taxmap_slv_ssu_ref_132.txt	
--- a/qiime2/qiime_vsearch_uchime-denovo.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_vsearch_uchime-denovo.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -14,7 +14,7 @@
  --p-dn=$pdn
 #end if
 
-#if $pmindiffs:
+#if str($pmindiffs):
  --p-mindiffs=$pmindiffs
 #end if
 
@@ -26,7 +26,7 @@
  --p-minh=$pminh
 #end if
 
-#if $pxn:
+#if str($pxn):
  --p-xn=$pxn
 #end if
 
--- a/qiime2/qiime_vsearch_uchime-ref.xml	Mon Aug 05 01:29:30 2019 -0400
+++ b/qiime2/qiime_vsearch_uchime-ref.xml	Tue Aug 13 07:46:48 2019 -0400
@@ -15,7 +15,7 @@
  --p-dn=$pdn
 #end if
 
-#if $pmindiffs:
+#if str($pmindiffs):
  --p-mindiffs=$pmindiffs
 #end if
 
@@ -27,7 +27,7 @@
  --p-minh=$pminh
 #end if
 
-#if $pxn:
+#if str($pxn):
  --p-xn=$pxn
 #end if
 
--- a/tool_data/ref_classifier.loc	Mon Aug 05 01:29:30 2019 -0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-#<unique_id>  <name>  <database_caption>  <qza_file_path>
-#
-#For each reference database, you need to download the qza file in qiime path
-#
-
--- a/tool_data/ref_taxnonomy.loc	Mon Aug 05 01:29:30 2019 -0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-#<unique_id>  <name>  <database_caption>  <qza_file_path>
-#
-#For each reference database, you need to download the qza file in qiime path
-#
-
--- a/tool_data_table_conf.xml.sample	Mon Aug 05 01:29:30 2019 -0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-<tables>
-    <table name="taxonomy_fp" comment_char="#">
-        <columns>value, name, dbkey, path</columns>
-        <file path="tool_data/ref_taxnonomy.loc" />
-    </table>
-    <table name="classifier_fp" comment_char="#">
-        <columns>value, name, dbkey, path</columns>
-        <file path="tool-data/ref_classifier.loc" />
-    </table>
-</tables>
-