view qiime2-2020.8/qiime_longitudinal_pairwise-distances.xml @ 22:292c84bd5ab6 draft

Uploaded
author florianbegusch
date Fri, 04 Sep 2020 12:55:05 +0000
parents d93d8888f0b0
children
line wrap: on
line source

<?xml version="1.0" ?>
<tool id="qiime_longitudinal_pairwise-distances" name="qiime longitudinal pairwise-distances"
      version="2020.8">
  <description>Paired pairwise distance testing and boxplots</description>
  <requirements>
    <requirement type="package" version="2020.8">qiime2</requirement>
  </requirements>
  <command><![CDATA[
qiime longitudinal pairwise-distances

--i-distance-matrix=$idistancematrix
# 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($pgroupcolumn):
  #set $pgroupcolumn_temp = $pgroupcolumn.replace('__ob__', '[')
  #set $pgroupcolumn = $pgroupcolumn_temp
#end if
#if '__cb__' in str($pgroupcolumn):
  #set $pgroupcolumn_temp = $pgroupcolumn.replace('__cb__', ']')
  #set $pgroupcolumn = $pgroupcolumn_temp
#end if
#if 'X' in str($pgroupcolumn):
  #set $pgroupcolumn_temp = $pgroupcolumn.replace('X', '\\')
  #set $pgroupcolumn = $pgroupcolumn_temp
#end if
#if '__sq__' in str($pgroupcolumn):
  #set $pgroupcolumn_temp = $pgroupcolumn.replace('__sq__', "'")
  #set $pgroupcolumn = $pgroupcolumn_temp
#end if
#if '__db__' in str($pgroupcolumn):
  #set $pgroupcolumn_temp = $pgroupcolumn.replace('__db__', '"')
  #set $pgroupcolumn = $pgroupcolumn_temp
#end if

--p-group-column=$pgroupcolumn


#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-1=$pstate1

--p-state-2=$pstate2

#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

--p-individual-id-column=$pindividualidcolumn


#if $pparametric:
 --p-parametric
#end if

#if str($ppalette) != 'None':
--p-palette=$ppalette
#end if

#if str($preplicatehandling) != 'None':
--p-replicate-handling=$preplicatehandling
#end if

--o-visualization=ovisualization

#if str($examples) != 'None':
--examples=$examples
#end if

;
cp odistancematrix.qza $odistancematrix

;
qiime tools export  ovisualization.qzv --output-path out
&& mkdir -p '$ovisualization.files_path'
&& cp -r out/* '$ovisualization.files_path'
&& mv '$ovisualization.files_path/index.html' '$ovisualization'

;
qiime tools export  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-distance-matrix: ARTIFACT DistanceMatrix       Matrix of distances between pairs of samples. [required]" name="idistancematrix" 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-group-column: TEXT  Metadata column on which to separate groups for comparison                                 [required]" name="pgroupcolumn" optional="False" type="text" />
    <param label="--p-state-column: TEXT  Metadata column containing state (e.g., Time) across which samples are paired.                  [required]" name="pstatecolumn" optional="False" type="text" />
    <param label="--p-state-1: TEXT       Baseline state column value.               [required]" name="pstate1" optional="False" type="text" />
    <param label="--p-state-2: TEXT       State column value to pair with baseline.  [required]" name="pstate2" optional="False" type="text" />
    <param label="--p-individual-id-column: TEXT Metadata column containing subject IDs to use for pairing samples. WARNING: if replicates exist for an individual ID at either state-1 or state-2, that subject will be dropped and reported in standard output by default. Set replicate_handling=\'random\' to instead randomly select one member.        [required]" name="pindividualidcolumn" optional="False" type="text" />
    <param label="--p-parametric: --p-parametric: / --p-no-parametric Perform parametric (ANOVA and t-tests) or non-parametric (Kruskal-Wallis, Wilcoxon, and Mann-Whitney U tests) statistical tests. [default: False]" name="pparametric" selected="False" type="boolean" />
    <param label="--p-palette: " name="ppalette" optional="True" type="select">
      <option selected="True" value="None">Selection is Optional</option>
      <option value="Set1">Set1</option>
      <option value="Set2">Set2</option>
      <option value="Set3">Set3</option>
      <option value="Pastel1">Pastel1</option>
      <option value="Pastel2">Pastel2</option>
      <option value="Paired">Paired</option>
      <option value="Accent">Accent</option>
      <option value="Dark2">Dark2</option>
      <option value="tab10">tab10</option>
      <option value="tab20">tab20</option>
      <option value="tab20b">tab20b</option>
      <option value="tab20c">tab20c</option>
      <option value="viridis">viridis</option>
      <option value="plasma">plasma</option>
      <option value="inferno">inferno</option>
      <option value="magma">magma</option>
      <option value="terrain">terrain</option>
      <option value="rainbow">rainbow</option>
      <option value="cividis">cividis</option>
    </param>
    <param label="--p-replicate-handling: " name="preplicatehandling" optional="True" type="select">
      <option selected="True" value="None">Selection is Optional</option>
      <option value="error">error</option>
      <option value="random">random</option>
      <option value="drop">drop</option>
    </param>
    <param label="--examples: Show usage examples and exit." name="examples" optional="False" type="data" />
    
  </inputs>

  <outputs>
    <data format="html" label="${tool.name} on ${on_string}: visualization.html" name="ovisualization" />
    
  </outputs>

  <help><![CDATA[
Paired pairwise distance testing and boxplots
###############################################################

Performs pairwise distance testing between sample pairs from each subject.
Sample pairs may represent a typical intervention study, e.g., samples
collected pre- and post-treatment; paired samples from two different
timepoints (e.g., in a longitudinal study design), or identical samples
receiving different two different treatments. This action tests whether the
pairwise distance between each subject pair differs between groups (e.g.,
groups of subjects receiving different treatments) and produces boxplots of
paired distance distributions for each group.

Parameters
----------
distance_matrix : DistanceMatrix
    Matrix of distances between pairs of samples.
metadata : Metadata
    Sample metadata file containing individual_id_column.
group_column : Str
    Metadata column on which to separate groups for comparison
state_column : Str
    Metadata column containing state (e.g., Time) across which samples are
    paired.
state_1 : Str
    Baseline state column value.
state_2 : Str
    State column value to pair with baseline.
individual_id_column : Str
    Metadata column containing subject IDs to use for pairing samples.
    WARNING: if replicates exist for an individual ID at either state_1 or
    state_2, that subject will be dropped and reported in standard output
    by default. Set replicate_handling="random" to instead randomly select
    one member.
parametric : Bool, optional
    Perform parametric (ANOVA and t-tests) or non-parametric (Kruskal-
    Wallis, Wilcoxon, and Mann-Whitney U tests) statistical tests.
palette : Str % Choices('Set1', 'Set2', 'Set3', 'Pastel1', 'Pastel2', 'Paired', 'Accent', 'Dark2', 'tab10', 'tab20', 'tab20b', 'tab20c', 'viridis', 'plasma', 'inferno', 'magma', 'terrain', 'rainbow', 'cividis'), optional
    Color palette to use for generating boxplots.
replicate_handling : Str % Choices('error', 'random', 'drop'), optional
    Choose how replicate samples are handled. If replicates are detected,
    "error" causes method to fail; "drop" will discard all replicated
    samples; "random" chooses one representative at random from among
    replicates.

Returns
-------
visualization : Visualization
  ]]></help>
  <macros>
    <import>qiime_citation.xml</import>
  </macros>
  <expand macro="qiime_citation"/>
</tool>