root/galaxy-central/tools/multivariate_stats/kpca.xml

リビジョン 2, 6.2 KB (コミッタ: hatakeyama, 14 年 前)

import galaxy-central

行番号 
1<tool id="kpca1" name="Kernel Principal Component Analysis" version="1.0.0">
2  <description> </description>
3  <command interpreter="python">
4    kpca.py
5      --input=$input1
6      --output1=$out_file1
7      --output2=$out_file2
8      --var_cols=$var_cols
9      --kernel=$kernelChoice.kernel
10      --features=$features
11      #if $kernelChoice.kernel == "rbfdot" or $kernelChoice.kernel == "anovadot":
12      --sigma=$kernelChoice.sigma
13      --degree="None"
14      --scale="None"
15      --offset="None"
16      --order="None"
17      #elif $kernelChoice.kernel == "polydot":
18      --sigma="None"
19      --degree=$kernelChoice.degree
20      --scale=$kernelChoice.scale
21      --offset=$kernelChoice.offset
22      --order="None"
23      #elif $kernelChoice.kernel == "tanhdot":
24      --sigma="None"
25      --degree="None"
26      --scale=$kernelChoice.scale
27      --offset=$kernelChoice.offset
28      --order="None"
29      #elif $kernelChoice.kernel == "besseldot":
30      --sigma=$kernelChoice.sigma
31      --degree=$kernelChoice.degree
32      --scale="None"
33      --offset="None"
34      --order=$kernelChoice.order
35      #elif $kernelChoice.kernel == "anovadot":
36      --sigma=$kernelChoice.sigma
37      --degree=$kernelChoice.degree
38      --scale="None"
39      --offset="None"
40      --order="None"
41      #else:
42      --sigma="None"
43      --degree="None"
44      --scale="None"
45      --offset="None"
46      --order="None"
47      #end if
48  </command>
49  <inputs>
50    <param format="tabular" name="input1" type="data" label="Select data" help="Query missing? See TIP below."/>
51    <param name="var_cols" label="Select columns containing input variables " type="data_column" data_ref="input1" numerical="True" multiple="true" >
52        <validator type="no_options" message="Please select at least one column."/>
53    </param>
54    <param name="features" size="10" type="integer" value="2" label="Number of principal components to return" help="To return all, enter 0"/>
55    <conditional name="kernelChoice">
56        <param name="kernel" type="select" label="Kernel function">
57            <option value="rbfdot" selected="true">Gaussian Radial Basis Function</option>
58            <option value="polydot">Polynomial</option>
59            <option value="vanilladot">Linear</option>
60            <option value="tanhdot">Hyperbolic</option>
61            <option value="laplacedot">Laplacian</option>
62            <option value="besseldot">Bessel</option>
63            <option value="anovadot">ANOVA Radial Basis Function</option>
64            <option value="splinedot">Spline</option>
65        </param>
66        <when value="vanilladot" />
67        <when value="splinedot" />
68        <when value="rbfdot">
69            <param name="sigma" size="10" type="float" value="1" label="sigma (inverse kernel width)" />
70        </when>
71        <when value="laplacedot">
72            <param name="sigma" size="10" type="float" value="1" label="sigma (inverse kernel width)" />
73        </when>
74        <when value="polydot">
75            <param name="degree" size="10" type="integer" value="1" label="degree" />
76            <param name="scale" size="10" type="integer" value="1" label="scale" />
77            <param name="offset" size="10" type="integer" value="1" label="offset" />
78        </when>
79        <when value="tanhdot">
80            <param name="scale" size="10" type="integer" value="1" label="scale" />
81            <param name="offset" size="10" type="integer" value="1" label="offset" />
82        </when>
83        <when value="besseldot">
84            <param name="sigma" size="10" type="integer" value="1" label="sigma" />
85            <param name="order" size="10" type="integer" value="1" label="order" />
86            <param name="degree" size="10" type="integer" value="1" label="degree" />
87        </when>
88        <when value="anovadot">
89            <param name="sigma" size="10" type="integer" value="1" label="sigma" />
90            <param name="degree" size="10" type="integer" value="1" label="degree" />
91        </when>
92    </conditional>   
93  </inputs>
94  <outputs>
95    <data format="input" name="out_file1" metadata_source="input1" />
96    <data format="pdf" name="out_file2" />
97  </outputs>
98  <requirements>
99    <requirement type="python-module">rpy</requirement>
100  </requirements>
101  <tests>
102    <test>
103        <param name="input1" value="iris.tabular"/>
104        <param name="var_cols" value="1,2,3,4"/>
105        <param name="kernel" value="polydot"/>
106        <param name="features" value="2"/>
107        <param name="offset" value="0"/>
108        <param name="scale" value="1"/>
109        <param name="degree" value="2"/>
110        <output name="out_file1" file="kpca_out1.tabular"/>
111        <output name="out_file2" file="kpca_out2.pdf"/>
112    </test>
113    <test>
114        <param name="input1" value="iris.tabular"/>
115        <param name="var_cols" value="2,3,4"/>
116        <param name="kernel" value="besseldot"/>
117        <param name="features" value="1"/>
118        <param name="sigma" value="1"/>
119        <param name="order" value="1"/>
120        <param name="degree" value="1"/>
121        <output name="out_file1" file="kpca_out3.tabular"/>
122        <output name="out_file2" file="kpca_out4.pdf"/>
123    </test>
124  </tests>
125  <help>
126
127
128.. class:: infomark
129
130**TIP:** If your data is not TAB delimited, use *Edit Queries-&gt;Convert characters*
131
132-----
133
134.. class:: infomark
135
136**What it does**
137
138This tool uses functions from 'kernlab' library from R statistical package to perform Kernel Principal Component Analysis (kPCA) on the input data. It outputs two files, one containing the summary statistics of the performed kPCA, and the other containing a scatterplot matrix of rotated values reported by kPCA.   
139
140*Alexandros Karatzoglou, Alex Smola, Kurt Hornik, Achim Zeileis (2004). kernlab - An S4 Package for Kernel Methods in R. Journal of Statistical Software 11(9), 1-20. URL http://www.jstatsoft.org/v11/i09/*
141
142-----
143
144.. class:: warningmark
145
146**Note**
147
148This tool currently treats all variables as continuous numeric variables. Running the tool on categorical variables might result in incorrect results. Rows containing non-numeric (or missing) data in any of the chosen columns will be skipped from the analysis.
149
150  </help>
151</tool>
Note: リポジトリブラウザについてのヘルプは TracBrowser を参照してください。