0
|
1 <?xml version="1.0" ?>
|
|
2 <tool id="qiime_diversity_beta-correlation" name="qiime diversity beta-correlation" version="2019.4">
|
|
3 <description> - Beta diversity correlation</description>
|
|
4 <requirements>
|
|
5 <requirement type="package" version="2019.4">qiime2</requirement>
|
|
6 </requirements>
|
|
7 <command><![CDATA[
|
|
8 qiime diversity beta-correlation
|
|
9
|
|
10 --i-distance-matrix=$idistancematrix
|
|
11 --m-metadata-column="$mmetadatacolumn"
|
|
12
|
|
13 #if str($pmethod) != 'None':
|
|
14 --p-method=$pmethod
|
|
15 #end if
|
|
16
|
|
17 #if $ppermutations:
|
|
18 --p-permutations=$ppermutations
|
|
19 #end if
|
|
20
|
|
21 #if $pintersectids:
|
|
22 --p-intersect-ids
|
|
23 #end if
|
|
24
|
|
25 #if str($plabel1):
|
|
26 --p-label1="$plabel1"
|
|
27 #end if
|
|
28
|
|
29 #if str($plabel2):
|
|
30 --p-label2="$plabel2"
|
|
31 #end if
|
|
32
|
|
33 #if $input_files_mmetadatafile:
|
|
34 #def list_dict_to_string(list_dict):
|
|
35 #set $file_list = list_dict[0]['additional_input'].__getattr__('file_name')
|
|
36 #for d in list_dict[1:]:
|
|
37 #set $file_list = $file_list + ',' + d['additional_input'].__getattr__('file_name')
|
|
38 #end for
|
|
39 #return $file_list
|
|
40 #end def
|
|
41 --m-metadata-file=$list_dict_to_string($input_files_mmetadatafile)
|
|
42 #end if
|
|
43
|
|
44 --o-metadata-distance-matrix=ometadatadistancematrix
|
|
45 --o-mantel-scatter-visualization=omantelscattervisualization
|
|
46 ;
|
|
47 cp ometadatadistancematrix.qza $ometadatadistancematrix;
|
|
48 qiime tools export --input-path omantelscattervisualization.qzv --output-path out && mkdir -p '$omantelscattervisualization.files_path'
|
|
49 && cp -r out/* '$omantelscattervisualization.files_path'
|
|
50 && mv '$omantelscattervisualization.files_path/index.html' '$omantelscattervisualization'
|
|
51 ]]></command>
|
|
52 <inputs>
|
|
53 <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"/>
|
|
54 <param label="--m-metadata-column: COLUMN MetadataColumn[Numeric] Numeric metadata column from which to compute pairwise Euclidean distances [required]" name="mmetadatacolumn" optional="False" type="text"/>
|
|
55 <param label="--p-method: " name="pmethod" optional="True" type="select">
|
|
56 <option selected="True" value="None">Selection is Optional</option>
|
|
57 <option value="spearman">spearman</option>
|
|
58 <option value="pearson">pearson</option>
|
|
59 </param>
|
|
60 <param label="--p-permutations: INTEGER Range(0, None) The number of permutations to be run when computing p-values. Supplying a value of zero will disable permutation testing and p-values will not be calculated (this results in *much* quicker execution time if p-values are not desired). [default: 999]" name="ppermutations" optional="True" type="integer" min="0" value="999"/>
|
|
61 <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"/>
|
|
62 <param label="--p-label1: TEXT Label for `distance-matrix` in the output visualization. [default: 'Metadata']" name="plabel1" optional="True" type="text" value="'Metadata'"/>
|
|
63 <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'"/>
|
|
64 <repeat name="input_files_mmetadatafile" optional="True" title="--m-metadata-file">
|
|
65 <param label="--m-metadata-file" name="additional_input" type="data" format="tabular,qza,no_unzip.zip" />
|
|
66 </repeat>
|
|
67 </inputs>
|
|
68 <outputs>
|
|
69 <data format="qza" label="${tool.name} on ${on_string}: metadatadistancematrix.qza" name="ometadatadistancematrix"/>
|
|
70 <data format="html" label="${tool.name} on ${on_string}: mantelscattervisualization.qzv" name="omantelscattervisualization"/>
|
|
71 </outputs>
|
|
72 <help><![CDATA[
|
|
73 Beta diversity correlation
|
|
74 ##########################
|
|
75
|
|
76 Create a distance matrix from a numeric metadata column and apply a two-
|
|
77 sided Mantel test to identify correlation between two distance matrices.
|
|
78 Actions used internally: `distance-matrix` from q2-metadata and `mantel`
|
|
79 from q2-diversity.
|
|
80
|
|
81 Parameters
|
|
82 ----------
|
|
83 metadata : MetadataColumn[Numeric]
|
|
84 Numeric metadata column from which to compute pairwise Euclidean
|
|
85 distances
|
|
86 distance_matrix : DistanceMatrix
|
|
87 Matrix of distances between pairs of samples.
|
|
88 method : Str % Choices('spearman', 'pearson'), optional
|
|
89 The correlation test to be applied in the Mantel test.
|
|
90 permutations : Int % Range(0, None), optional
|
|
91 The number of permutations to be run when computing p-values. Supplying
|
|
92 a value of zero will disable permutation testing and p-values will not
|
|
93 be calculated (this results in *much* quicker execution time if
|
|
94 p-values are not desired).
|
|
95 intersect_ids : Bool, optional
|
|
96 If supplied, IDs that are not found in both distance matrices will be
|
|
97 discarded before applying the Mantel test. Default behavior is to error
|
|
98 on any mismatched IDs.
|
|
99 label1 : Str, optional
|
|
100 Label for `distance_matrix` in the output visualization.
|
|
101 label2 : Str, optional
|
|
102 Label for `metadata_distance_matrix` in the output visualization.
|
|
103
|
|
104 Returns
|
|
105 -------
|
|
106 metadata_distance_matrix : DistanceMatrix
|
|
107 The Distance Matrix produced from the metadata column and used in the
|
|
108 mantel test
|
|
109 mantel_scatter_visualization : Visualization
|
|
110 Scatter plot rendering of the manteltest results
|
|
111 ]]></help>
|
|
112 <macros>
|
|
113 <import>qiime_citation.xml</import>
|
|
114 </macros>
|
|
115 <expand macro="qiime_citation"/>
|
|
116 </tool>
|