Mercurial > repos > florianbegusch > qiime2_suite
diff qiime2/qiime_longitudinal_feature-volatility.xml @ 14:a0a8d77a991c draft
Uploaded
author | florianbegusch |
---|---|
date | Thu, 03 Sep 2020 09:51:29 +0000 |
parents | f190567fe3f6 |
children |
line wrap: on
line diff
--- a/qiime2/qiime_longitudinal_feature-volatility.xml Thu Sep 03 09:46:00 2020 +0000 +++ b/qiime2/qiime_longitudinal_feature-volatility.xml Thu Sep 03 09:51:29 2020 +0000 @@ -1,42 +1,85 @@ <?xml version="1.0" ?> -<tool id="qiime_longitudinal_feature-volatility" name="qiime longitudinal feature-volatility" version="2019.7"> - <description> - Feature volatility analysis</description> - <requirements> - <requirement type="package" version="2019.7">qiime2</requirement> - </requirements> - <command><![CDATA[ +<tool id="qiime_longitudinal_feature-volatility" name="qiime longitudinal feature-volatility" + version="2020.8"> + <description>Feature volatility analysis</description> + <requirements> + <requirement type="package" version="2020.8">qiime2</requirement> + </requirements> + <command><![CDATA[ qiime longitudinal feature-volatility --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 if + +#if '__ob__' in str($pstatecolumn): + #set $pstatecolumn_temp = $pstatecolumn.replace('__ob__', '[') + #set $pstatecolumn = $pstatecolumn_temp +#end if +#if '__cb__' in str($pstatecolumn): + #set $pstatecolumn_temp = $pstatecolumn.replace('__cb__', ']') + #set $pstatecolumn = $pstatecolumn_temp +#end if +#if 'X' in str($pstatecolumn): + #set $pstatecolumn_temp = $pstatecolumn.replace('X', '\\') + #set $pstatecolumn = $pstatecolumn_temp +#end if +#if '__sq__' in str($pstatecolumn): + #set $pstatecolumn_temp = $pstatecolumn.replace('__sq__', "'") + #set $pstatecolumn = $pstatecolumn_temp +#end if +#if '__db__' in str($pstatecolumn): + #set $pstatecolumn_temp = $pstatecolumn.replace('__db__', '"') + #set $pstatecolumn = $pstatecolumn_temp +#end if + +--p-state-column=$pstatecolumn ---p-state-column="$pstatecolumn" +#if '__ob__' in str($pindividualidcolumn): + #set $pindividualidcolumn_temp = $pindividualidcolumn.replace('__ob__', '[') + #set $pindividualidcolumn = $pindividualidcolumn_temp +#end if +#if '__cb__' in str($pindividualidcolumn): + #set $pindividualidcolumn_temp = $pindividualidcolumn.replace('__cb__', ']') + #set $pindividualidcolumn = $pindividualidcolumn_temp +#end if +#if 'X' in str($pindividualidcolumn): + #set $pindividualidcolumn_temp = $pindividualidcolumn.replace('X', '\\') + #set $pindividualidcolumn = $pindividualidcolumn_temp +#end if +#if '__sq__' in str($pindividualidcolumn): + #set $pindividualidcolumn_temp = $pindividualidcolumn.replace('__sq__', "'") + #set $pindividualidcolumn = $pindividualidcolumn_temp +#end if +#if '__db__' in str($pindividualidcolumn): + #set $pindividualidcolumn_temp = $pindividualidcolumn.replace('__db__', '"') + #set $pindividualidcolumn = $pindividualidcolumn_temp +#end if #if str($pindividualidcolumn): - --p-individual-id-column="$pindividualidcolumn" + --p-individual-id-column=$pindividualidcolumn #end if -#if str($pcv): - --p-cv=$pcv -#end if +--p-cv=$pcv #if str($prandomstate): - --p-random-state="$prandomstate" + --p-random-state=$prandomstate #end if - -#set $pnjobs = '${GALAXY_SLOTS:-4}' +--p-n-jobs=$pnjobs -#if str($pnjobs): - --p-n-jobs="$pnjobs" -#end if - - -#if str($pnestimators): - --p-n-estimators=$pnestimators -#end if +--p-n-estimators=$pnestimators #if str($pestimator) != 'None': - --p-estimator=$pestimator +--p-estimator=$pestimator #end if #if $pparametertuning: @@ -44,80 +87,91 @@ #end if #if str($pmissingsamples) != 'None': - --p-missing-samples=$pmissingsamples +--p-missing-samples=$pmissingsamples #end if - -#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 str($pimportancethreshold) != 'None': +--p-importance-threshold=$pimportancethreshold #end if +#if str($pfeaturecount) != 'None': +--p-feature-count=$pfeaturecount +#end if --o-filtered-table=ofilteredtable + --o-feature-importance=ofeatureimportance + --o-volatility-plot=ovolatilityplot + --o-accuracy-results=oaccuracyresults + --o-sample-estimator=osampleestimator + +#if str($examples) != 'None': +--examples=$examples +#end if + ; -cp ofilteredtable.qza $ofilteredtable; -cp ofeatureimportance.qza $ofeatureimportance; -qiime tools export --input-path ovolatilityplot.qzv --output-path out && mkdir -p '$ovolatilityplot.files_path' -&& cp -r out/* '$ovolatilityplot.files_path' -&& mv '$ovolatilityplot.files_path/index.html' '$ovolatilityplot'; -qiime tools export --input-path oaccuracyresults.qzv --output-path out && mkdir -p '$oaccuracyresults.files_path' -&& cp -r out/* '$oaccuracyresults.files_path' -&& mv '$oaccuracyresults.files_path/index.html' '$oaccuracyresults'; cp osampleestimator.qza $osampleestimator - ]]></command> - <inputs> - <param format="qza,no_unzip.zip" label="--i-table: ARTIFACT FeatureTable[Frequency] Feature table containing all features that should be used for target prediction. [required]" name="itable" optional="False" type="data"/> - <param label="--p-state-column: TEXT Metadata containing collection time (state) values for each sample. Must contain exclusively numeric values. [required]" name="pstatecolumn" optional="False" type="text"/> - <param label="--p-individual-id-column: TEXT Metadata column containing IDs for individual subjects. [optional]" name="pindividualidcolumn" optional="True" type="text"/> - <param label="--p-cv: INTEGER Number of k-fold cross-validations to perform. Range(1, None) [default: 5]" name="pcv" optional="True" type="integer" min="1" value="5"/> - <param label="--p-random-state: INTEGER Seed used by random number generator. [optional]" name="prandomstate" optional="True" type="integer"/> - <param label="--p-n-estimators: INTEGER Range(1, None) 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" min="1" value="100"/> - <param label="--p-estimator: " name="pestimator" optional="True" type="select"> - <option selected="True" value="None">Selection is Optional</option> - <option value="RandomForestRegressor">RandomForestRegressor</option> - <option value="ExtraTreesRegressor">ExtraTreesRegressor</option> - <option value="GradientBoostingRegressor">GradientBoostingRegressor</option> - <option value="AdaBoostRegressor">AdaBoostRegressor</option> - <option value="ElasticNet">ElasticNet</option> - <option value="Ridge">Ridge</option> - <option value="Lasso">Lasso</option> - <option value="KNeighborsRegressor">KNeighborsRegressor</option> - <option value="LinearSVR">LinearSVR</option> - <option value="SVR">SVR</option> - </param> - <param label="--p-parameter-tuning: --p-no-parameter-tuning Automatically tune hyperparameters using random grid search. [default: False]" name="pparametertuning" selected="False" type="boolean"/> - <param label="--p-missing-samples: " name="pmissingsamples" optional="True" type="select"> - <option selected="True" value="None">Selection is Optional</option> - <option value="error">error</option> - <option value="ignore">ignore</option> - </param> - <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> + ]]></command> + <inputs> + <param format="qza,no_unzip.zip" label="--i-table: ARTIFACT 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 format="tabular,qza,no_unzip.zip" label="--m-metadata-file: METADATA... (multiple Sample metadata file containing arguments will be individual-id-column. merged) [required]" name="additional_input" optional="False" type="data" /> + </repeat> + <param label="--p-state-column: TEXT Metadata containing collection time (state) values for each sample. Must contain exclusively numeric values. [required]" name="pstatecolumn" optional="False" type="text" /> + <param label="--p-individual-id-column: TEXT Metadata column containing IDs for individual subjects. [optional]" name="pindividualidcolumn" optional="False" type="text" /> + <param label="--p-cv: INTEGER Number of k-fold cross-validations to perform. Range(1, None) [default: 5]" min="1" name="pcv" optional="True" type="integer" value="5" /> + <param label="--p-random-state: INTEGER Seed used by random number generator. [optional]" name="prandomstate" optional="False" type="text" /> + <param label="--p-n-estimators: INTEGER Range(1, None) 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]" min="1" name="pnestimators" optional="True" type="integer" value="100" /> + <param label="--p-estimator: " name="pestimator" optional="True" type="select"> + <option selected="True" value="None">Selection is Optional</option> + <option value="RandomForestRegressor">RandomForestRegressor</option> + <option value="ExtraTreesRegressor">ExtraTreesRegressor</option> + <option value="GradientBoostingRegressor">GradientBoostingRegressor</option> + <option value="AdaBoostRegressor">AdaBoostRegressor</option> + <option value="ElasticNet">ElasticNet</option> + <option value="Ridge">Ridge</option> + <option value="Lasso">Lasso</option> + <option value="KNeighborsRegressor">KNeighborsRegressor</option> + <option value="LinearSVR">LinearSVR</option> + <option value="SVR">SVR</option> + </param> + <param label="--p-parameter-tuning: --p-parameter-tuning: / --p-no-parameter-tuning Automatically tune hyperparameters using random grid search. [default: False]" name="pparametertuning" selected="False" type="boolean" /> + <param label="--p-missing-samples: " name="pmissingsamples" optional="True" type="select"> + <option selected="True" value="None">Selection is Optional</option> + <option value="error">error</option> + <option value="ignore">ignore</option> + </param> + <param label="--p-importance-threshold: " name="pimportancethreshold" optional="True" type="select"> + <option selected="True" value="None">Selection is Optional</option> + <option value="Float % Range(0">Float % Range(0</option> + <option value="None">None</option> + <option value="inclusive_start=False">inclusive_start=False</option> + </param> + <param label="--p-feature-count: " name="pfeaturecount" 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="--examples: Show usage examples and exit." name="examples" optional="False" type="data" /> + + </inputs> - </inputs> - <outputs> - <data format="qza" label="${tool.name} on ${on_string}: filteredtable.qza" name="ofilteredtable"/> - <data format="qza" label="${tool.name} on ${on_string}: featureimportance.qza" name="ofeatureimportance"/> - <data format="html" label="${tool.name} on ${on_string}: volatilityplot.qzv" name="ovolatilityplot"/> - <data format="html" label="${tool.name} on ${on_string}: accuracyresults.qzv" name="oaccuracyresults"/> - <data format="qza" label="${tool.name} on ${on_string}: sampleestimator.qza" name="osampleestimator"/> - </outputs> - <help><![CDATA[ + <outputs> + <data format="qza" label="${tool.name} on ${on_string}: filteredtable.qza" name="ofilteredtable" /> + <data format="qza" label="${tool.name} on ${on_string}: featureimportance.qza" name="ofeatureimportance" /> + <data format="html" label="${tool.name} on ${on_string}: volatilityplot.html" name="ovolatilityplot" /> + <data format="html" label="${tool.name} on ${on_string}: accuracyresults.html" name="oaccuracyresults" /> + <data format="qza" label="${tool.name} on ${on_string}: sampleestimator.qza" name="osampleestimator" /> + + </outputs> + + <help><![CDATA[ Feature volatility analysis -########################### +############################################################### Identify features that are predictive of a numeric metadata column, state_column (e.g., time), and plot their relative frequencies across @@ -142,6 +196,8 @@ Number of k-fold cross-validations to perform. random_state : Int, optional Seed used by random number generator. +n_jobs : Int, optional + Number of jobs to run in parallel. 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 @@ -157,6 +213,14 @@ samples are detected. "ignore" will cause the feature table and metadata to be filtered, so that only samples found in both files are retained. +importance_threshold : Float % Range(0, None, inclusive_start=False) | Str % Choices('q1', 'q2', 'q3'), optional + Filter feature table to exclude any features with an importance score + less than this threshold. Set to "q1", "q2", or "q3" to select the + first, second, or third quartile of values. Set to "None" to disable + this filter. +feature_count : Int % Range(1, None) | Str % Choices('all'), optional + Filter feature table to include top N most important features. Set to + "all" to include all features. Returns ------- @@ -170,9 +234,9 @@ Accuracy results visualization. sample_estimator : SampleEstimator[Regressor] Trained sample regressor. - ]]></help> -<macros> + ]]></help> + <macros> <import>qiime_citation.xml</import> -</macros> -<expand macro="qiime_citation"/> -</tool> + </macros> + <expand macro="qiime_citation"/> +</tool> \ No newline at end of file