Mercurial > repos > ebi-gxa > scanpy_run_umap
comparison scanpy-run-umap.xml @ 1:0ac2f9f2313b draft
"planemo upload for repository https://github.com/ebi-gene-expression-group/container-galaxy-sc-tertiary/tree/develop/tools/tertiary-analysis/scanpy commit 4846776f55931e176f7e77af7c185ec6fec7d142"
author | ebi-gxa |
---|---|
date | Mon, 16 Sep 2019 08:16:59 -0400 |
parents | 88c1516e25e0 |
children | 6eb7a2e37adf |
comparison
equal
deleted
inserted
replaced
0:88c1516e25e0 | 1:0ac2f9f2313b |
---|---|
1 <?xml version="1.0" encoding="utf-8"?> | 1 <?xml version="1.0" encoding="utf-8"?> |
2 <tool id="scanpy_run_umap" name="Scanpy RunUMAP" version="@TOOL_VERSION@+galaxy1"> | 2 <tool id="scanpy_run_umap" name="Scanpy RunUMAP" version="@TOOL_VERSION@+galaxy1"> |
3 <description>visualise cell clusters using UMAP</description> | 3 <description>visualise cell clusters using UMAP</description> |
4 <macros> | 4 <macros> |
5 <import>scanpy_macros.xml</import> | 5 <import>scanpy_macros2.xml</import> |
6 </macros> | 6 </macros> |
7 <expand macro="requirements"/> | 7 <expand macro="requirements"/> |
8 <command detect_errors="exit_code"><![CDATA[ | 8 <command detect_errors="exit_code"><![CDATA[ |
9 ln -s '${input_obj_file}' input.h5 && | 9 ln -s '${input_obj_file}' input.h5 && |
10 PYTHONIOENCODING=utf-8 scanpy-run-umap.py | 10 PYTHONIOENCODING=utf-8 scanpy-run-umap |
11 -i input.h5 | 11 --use-graph '${use_graph}' |
12 -f '${input_format}' | 12 --key-added '${key_added}' |
13 -o output.h5 | 13 #if $embeddings |
14 -F '${output_format}' | 14 --export-embedding embeddings.csv |
15 #if $embeddings | 15 #end if |
16 --output-embeddings-file embeddings.csv | 16 #if $settings.default == "false" |
17 --n-components ${settings.n_components} | |
18 --min-dist ${settings.min_dist} | |
19 --spread ${settings.spread} | |
20 --alpha ${settings.alpha} | |
21 --gamma ${settings.gamma} | |
22 --negative-sample-rate ${settings.negative_sample_rate} | |
23 --random-state ${settings.random_seed} | |
24 #if $settings.init_pos | |
25 --init-pos '${settings.init_pos}' | |
17 #end if | 26 #end if |
18 #if $settings.default == "false" | 27 #if $settings.maxiter |
19 -n '${settings.n_components}' | 28 --maxiter ${settings.maxiter} |
20 --min-dist '${settings.min_dist}' | 29 #end if |
21 --spread '${settings.spread}' | 30 #end if |
22 --alpha '${settings.alpha}' | 31 @INPUT_OPTS@ |
23 --gamma '${settings.gamma}' | 32 @OUTPUT_OPTS@ |
24 --negative-sample-rate '${settings.negative_sample_rate}' | |
25 #if $settings.init_pos | |
26 --init-pos '${settings.init_pos}' | |
27 #end if | |
28 #if $settings.maxiter | |
29 --maxiter '${settings.maxiter}' | |
30 #end if | |
31 #if $settings.a | |
32 -a '${settings.a}' | |
33 #end if | |
34 #if $settings.b | |
35 -b '${settings.b}' | |
36 #end if | |
37 #if $settings.random_seed is not None | |
38 -s '${settings.random_seed}' | |
39 #end if | |
40 #end if | |
41 | 33 |
42 @PLOT_OPTS@ | |
43 ]]></command> | 34 ]]></command> |
44 | 35 |
45 <inputs> | 36 <inputs> |
46 <expand macro="input_object_params"/> | 37 <expand macro="input_object_params"/> |
47 <expand macro="output_object_params"/> | 38 <expand macro="output_object_params"/> |
48 <param name="embeddings" type="boolean" checked="true" label="Output embeddings in csv format"/> | 39 <param name="embeddings" type="boolean" checked="true" label="Output embeddings in csv format"/> |
40 <param name="use_graph" argument="--use-graph" value="neighbors" type="text" | |
41 label="Name of the slot that holds the KNN graph"/> | |
42 <param name="key_added" argument="--key-added" type="text" optional="true" | |
43 label="Additional suffix to the name of the slot to save the embedding"/> | |
44 | |
49 <conditional name="settings"> | 45 <conditional name="settings"> |
50 <param name="default" type="boolean" checked="true" label="Use programme defaults"/> | 46 <param name="default" type="boolean" checked="true" label="Use programme defaults"/> |
51 <when value="true"/> | 47 <when value="true"/> |
52 <when value="false"> | 48 <when value="false"> |
53 <param name="n_components" argument="--n-components" type="integer" value="2" label="The number of dimensions of the embedding"/> | 49 <param name="n_components" argument="--n-components" type="integer" value="2" label="The number of dimensions of the embedding"/> |
60 <option value="spectral" selected="true">spectral</option> | 56 <option value="spectral" selected="true">spectral</option> |
61 <option value="paga">paga</option> | 57 <option value="paga">paga</option> |
62 <option value="random">random</option> | 58 <option value="random">random</option> |
63 </param> | 59 </param> |
64 <param name="maxiter" argument="--maxiter" type="integer" optional="true" label="Number of iterations of optimisation"/> | 60 <param name="maxiter" argument="--maxiter" type="integer" optional="true" label="Number of iterations of optimisation"/> |
65 <param name="a" argument="-a" type="float" optional="true" label="More specific parameter controlling embedding, automatically determined from --min-dist and --spread if unset"/> | 61 <param name="random_seed" argument="--random-state" type="integer" value="0" label="Seed for numpy random number generator"/> |
66 <param name="b" argument="-b" type="float" optional="true" label="More specific parameter controlling embedding, automatically determined from --min-dist and --spread if unset"/> | |
67 <param name="random_seed" argument="--random-seed" type="integer" value="0" label="Seed for numpy random number generator"/> | |
68 </when> | 62 </when> |
69 </conditional> | |
70 <conditional name="do_plotting"> | |
71 <param name="plot" type="boolean" checked="false" label="Make UMAP plot"/> | |
72 <when value="true"> | |
73 <expand macro="output_plot_params"/> | |
74 <param name="color_by" argument="--color-by" type="text" value="louvain" label="Color by attributes, comma separated strings"/> | |
75 </when> | |
76 <when value="false"/> | |
77 </conditional> | 63 </conditional> |
78 </inputs> | 64 </inputs> |
79 | 65 |
80 <outputs> | 66 <outputs> |
81 <data name="output_h5" format="h5" from_work_dir="output.h5" label="${tool.name} on ${on_string}: UMAP object"/> | 67 <data name="output_h5" format="h5" from_work_dir="output.h5" label="${tool.name} on ${on_string}: UMAP object"/> |
82 <data name="output_png" format="png" from_work_dir="output.png" label="${tool.name} on ${on_string}: UMAP plot"> | |
83 <filter>do_plotting['plot']</filter> | |
84 </data> | |
85 <data name="output_embed" format="csv" from_work_dir="embeddings.csv" label="${tool.name} on ${on_string}: UMAP embeddings"> | 68 <data name="output_embed" format="csv" from_work_dir="embeddings.csv" label="${tool.name} on ${on_string}: UMAP embeddings"> |
86 <filter>embeddings</filter> | 69 <filter>embeddings</filter> |
87 </data> | 70 </data> |
88 </outputs> | 71 </outputs> |
89 | 72 |
93 <param name="input_format" value="anndata"/> | 76 <param name="input_format" value="anndata"/> |
94 <param name="output_format" value="anndata"/> | 77 <param name="output_format" value="anndata"/> |
95 <param name="default" value="false"/> | 78 <param name="default" value="false"/> |
96 <param name="embeddings" value="true"/> | 79 <param name="embeddings" value="true"/> |
97 <param name="random_seed" value="0"/> | 80 <param name="random_seed" value="0"/> |
98 <param name="plot" value="true"/> | |
99 <param name="color_by" value="louvain"/> | |
100 <output name="output_h5" file="run_umap.h5" ftype="h5" compare="sim_size"/> | 81 <output name="output_h5" file="run_umap.h5" ftype="h5" compare="sim_size"/> |
101 <output name="output_png" file="run_umap.png" ftype="png" compare="sim_size"/> | |
102 <output name="output_embed" file="run_umap.embeddings.csv" ftype="csv" compare="sim_size"> | 82 <output name="output_embed" file="run_umap.embeddings.csv" ftype="csv" compare="sim_size"> |
103 <assert_contents> | 83 <assert_contents> |
104 <has_n_columns n="2" sep=","/> | 84 <has_n_columns n="2" sep=","/> |
105 </assert_contents> | 85 </assert_contents> |
106 </output> | 86 </output> |
107 </test> | 87 </test> |
108 </tests> | 88 </tests> |
109 | 89 |
110 <help><![CDATA[ | 90 <help><![CDATA[ |
111 ======================================================== | 91 ========================================================== |
112 Embed the neighborhood graph using UMAP (`tl.umap`) | 92 Embed the neighborhood graph using UMAP (`scanpy.tl.umap`) |
113 ======================================================== | 93 ========================================================== |
94 | |
95 For making UMAP plots, please use `Scanpy PlotEmbed` with the output of this tool and enter "umap" as the | |
96 name of the embedding to plot. | |
114 | 97 |
115 UMAP (Uniform Manifold Approximation and Projection) is a manifold learning | 98 UMAP (Uniform Manifold Approximation and Projection) is a manifold learning |
116 technique suitable for visualizing high-dimensional data. Besides tending to | 99 technique suitable for visualizing high-dimensional data. Besides tending to |
117 be faster than tSNE, it optimizes the embedding such that it best reflects | 100 be faster than tSNE, it optimizes the embedding such that it best reflects |
118 the topology of the data, which we represent throughout Scanpy using a | 101 the topology of the data, which we represent throughout Scanpy using a |