Mercurial > repos > devteam > kernel_principal_component_analysis
annotate kpca.xml @ 1:3d58aa83e4a3 draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
author | devteam |
---|---|
date | Wed, 11 Nov 2015 12:17:56 -0500 |
parents | e9ebd4bfbdfc |
children |
rev | line source |
---|---|
0 | 1 <tool id="kpca1" name="Kernel Principal Component Analysis" version="1.0.0"> |
2 <description> </description> | |
3 <requirements> | |
4 <requirement type="package" version="1.0.3">rpy</requirement> | |
5 <requirement type="package" version="2.11.0">R</requirement> | |
6 <requirement type="package" version="0.1-4">kernlab</requirement> | |
7 <requirement type="package" version="1.7.1">numpy</requirement> | |
8 <requirement type="package" version="0.7.1">bx-python</requirement> | |
9 </requirements> | |
10 <command interpreter="python"> | |
11 kpca.py | |
12 --input=$input1 | |
13 --output1=$out_file1 | |
14 --output2=$out_file2 | |
15 --var_cols=$var_cols | |
16 --kernel=$kernelChoice.kernel | |
17 --features=$features | |
18 #if $kernelChoice.kernel == "rbfdot" or $kernelChoice.kernel == "anovadot": | |
19 --sigma=$kernelChoice.sigma | |
20 --degree="None" | |
21 --scale="None" | |
22 --offset="None" | |
23 --order="None" | |
24 #elif $kernelChoice.kernel == "polydot": | |
25 --sigma="None" | |
26 --degree=$kernelChoice.degree | |
27 --scale=$kernelChoice.scale | |
28 --offset=$kernelChoice.offset | |
29 --order="None" | |
30 #elif $kernelChoice.kernel == "tanhdot": | |
31 --sigma="None" | |
32 --degree="None" | |
33 --scale=$kernelChoice.scale | |
34 --offset=$kernelChoice.offset | |
35 --order="None" | |
36 #elif $kernelChoice.kernel == "besseldot": | |
37 --sigma=$kernelChoice.sigma | |
38 --degree=$kernelChoice.degree | |
39 --scale="None" | |
40 --offset="None" | |
41 --order=$kernelChoice.order | |
42 #elif $kernelChoice.kernel == "anovadot": | |
43 --sigma=$kernelChoice.sigma | |
44 --degree=$kernelChoice.degree | |
45 --scale="None" | |
46 --offset="None" | |
47 --order="None" | |
48 #else: | |
49 --sigma="None" | |
50 --degree="None" | |
51 --scale="None" | |
52 --offset="None" | |
53 --order="None" | |
54 #end if | |
55 </command> | |
56 <inputs> | |
57 <param format="tabular" name="input1" type="data" label="Select data" help="Dataset missing? See TIP below."/> | |
58 <param name="var_cols" label="Select columns containing input variables " type="data_column" data_ref="input1" numerical="True" multiple="true" > | |
59 <validator type="no_options" message="Please select at least one column."/> | |
60 </param> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
61 <param name="features" type="integer" value="2" label="Number of principal components to return" help="To return all, enter 0"/> |
0 | 62 <conditional name="kernelChoice"> |
63 <param name="kernel" type="select" label="Kernel function"> | |
64 <option value="rbfdot" selected="true">Gaussian Radial Basis Function</option> | |
65 <option value="polydot">Polynomial</option> | |
66 <option value="vanilladot">Linear</option> | |
67 <option value="tanhdot">Hyperbolic</option> | |
68 <option value="laplacedot">Laplacian</option> | |
69 <option value="besseldot">Bessel</option> | |
70 <option value="anovadot">ANOVA Radial Basis Function</option> | |
71 <option value="splinedot">Spline</option> | |
72 </param> | |
73 <when value="vanilladot" /> | |
74 <when value="splinedot" /> | |
75 <when value="rbfdot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
76 <param name="sigma" type="float" value="1" label="sigma (inverse kernel width)" /> |
0 | 77 </when> |
78 <when value="laplacedot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
79 <param name="sigma" type="float" value="1" label="sigma (inverse kernel width)" /> |
0 | 80 </when> |
81 <when value="polydot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
82 <param name="degree" type="integer" value="1" label="degree" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
83 <param name="scale" type="integer" value="1" label="scale" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
84 <param name="offset" type="integer" value="1" label="offset" /> |
0 | 85 </when> |
86 <when value="tanhdot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
87 <param name="scale" type="integer" value="1" label="scale" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
88 <param name="offset" type="integer" value="1" label="offset" /> |
0 | 89 </when> |
90 <when value="besseldot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
91 <param name="sigma" type="integer" value="1" label="sigma" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
92 <param name="order" type="integer" value="1" label="order" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
93 <param name="degree" type="integer" value="1" label="degree" /> |
0 | 94 </when> |
95 <when value="anovadot"> | |
1
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
96 <param name="sigma" type="integer" value="1" label="sigma" /> |
3d58aa83e4a3
planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/kernel_principal_component_analysis commit a1517c9d22029095120643bbe2c8fa53754dd2b7
devteam
parents:
0
diff
changeset
|
97 <param name="degree" type="integer" value="1" label="degree" /> |
0 | 98 </when> |
99 </conditional> | |
100 </inputs> | |
101 <outputs> | |
102 <data format="input" name="out_file1" metadata_source="input1" /> | |
103 <data format="pdf" name="out_file2" /> | |
104 </outputs> | |
105 <tests> | |
106 <test> | |
107 <param name="input1" value="iris.tabular"/> | |
108 <param name="var_cols" value="1,2,3,4"/> | |
109 <param name="kernel" value="polydot"/> | |
110 <param name="features" value="2"/> | |
111 <param name="offset" value="0"/> | |
112 <param name="scale" value="1"/> | |
113 <param name="degree" value="2"/> | |
114 <output name="out_file1" file="kpca_out1.tabular"/> | |
115 <output name="out_file2" file="kpca_out2.pdf"/> | |
116 </test> | |
117 </tests> | |
118 <help> | |
119 | |
120 | |
121 .. class:: infomark | |
122 | |
123 **TIP:** If your data is not TAB delimited, use *Edit Datasets->Convert characters* | |
124 | |
125 ----- | |
126 | |
127 .. class:: infomark | |
128 | |
129 **What it does** | |
130 | |
131 This 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. | |
132 | |
133 *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/* | |
134 | |
135 ----- | |
136 | |
137 .. class:: warningmark | |
138 | |
139 **Note** | |
140 | |
141 This 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. | |
142 | |
143 </help> | |
144 </tool> |