Mercurial > repos > ebi-gxa > seurat_find_clusters
comparison seurat_macros.xml @ 6:d541e9e62beb draft default tip
planemo upload commit 0264c359f1d638bbbbab515a3502231f679cdcf6
author | ebi-gxa |
---|---|
date | Sat, 02 Mar 2024 10:42:24 +0000 |
parents | eefaffdcd441 |
children |
comparison
equal
deleted
inserted
replaced
5:eefaffdcd441 | 6:d541e9e62beb |
---|---|
1 <?xml version="1.0"?> | 1 <?xml version="1.0"?> |
2 <macros> | 2 <macros> |
3 <token name="@VERSION@">0.3.0</token> | 3 <token name="@VERSION@">4.0.0</token> |
4 <token name="@SEURAT_VERSION@">3.2.3</token> | 4 <token name="@SEURAT_VERSION@">4.0.4</token> |
5 <xml name="requirements"> | 5 <xml name="requirements"> |
6 <requirements> | 6 <requirements> |
7 <requirement type="package" version="@VERSION@">seurat-scripts</requirement> | 7 <requirement type="package" version="@VERSION@">seurat-scripts</requirement> |
8 </requirements> | 8 </requirements> |
9 </xml> | 9 </xml> |
11 <version_command><![CDATA[ | 11 <version_command><![CDATA[ |
12 echo $(R --version | grep version | grep -v GNU)", seurat version" $(R --vanilla --slave -e "library(seurat); cat(sessionInfo()\$otherPkgs\$seurat\$Version)" 2> /dev/null | grep -v -i "WARNING: ") | 12 echo $(R --version | grep version | grep -v GNU)", seurat version" $(R --vanilla --slave -e "library(seurat); cat(sessionInfo()\$otherPkgs\$seurat\$Version)" 2> /dev/null | grep -v -i "WARNING: ") |
13 ]]></version_command> | 13 ]]></version_command> |
14 </xml> | 14 </xml> |
15 | 15 |
16 <xml name="input_object_params"> | 16 <xml name="input_object_params" token_multiple="False" token_varname="input" token_optional="False"> |
17 <conditional name="input" label="Input format"> | 17 <conditional name="@VARNAME@" label="Input format"> |
18 <param type="select" name="format" label="Choose the format of the input" help="RData, Loom or AnnData"> | 18 <param type="select" name="format" label="Choose the format of the @VARNAME@" help="Seurat RDS, Seurat H5, Single Cell Experiment RDS, Loom or AnnData"> |
19 <option value="rds_seurat" selected="true">RDS with a Seurat object</option> | 19 <option value="rds_seurat" selected="true">RDS with a Seurat object</option> |
20 <option value="loom">Loom</option> | 20 <option value="loom">Loom</option> |
21 <option value="h5seurat">Seurat HDF5</option> | |
21 <option value="anndata">AnnData</option> | 22 <option value="anndata">AnnData</option> |
22 <option value="rds_sce">RDS with a Single Cell Experiment object</option> | 23 <option value="rds_sce">RDS with a Single Cell Experiment object</option> |
23 </param> | 24 </param> |
24 <when value="anndata"> | 25 <when value="anndata"> |
25 <param type="data" name="anndata_file" label="AnnData file" help="The AnnData format provided by Scanpy" format="h5,h5ad"/> | 26 <param type="data" name="anndata_file" multiple="@MULTIPLE@" optional="@OPTIONAL@" label="AnnData file" help="Select AnnData files for @VARNAME@" format="h5,h5ad"/> |
26 </when> | 27 </when> |
27 <when value="loom"> | 28 <when value="loom"> |
28 <param type="data" name="loom_file" label="Loom file" help="Input as Loom v? file" format="h5,h5loom"/> | 29 <param type="data" name="loom_file" multiple="@MULTIPLE@" optional="@OPTIONAL@" label="Loom file" help="Select Loom file(s) for @VARNAME@" format="h5,h5loom"/> |
29 </when> | 30 </when> |
30 <when value="rds_seurat"> | 31 <when value="rds_seurat"> |
31 <param type="data" name="rds_seurat_file" label="RDS file" help="Input as RDS file with Seurat 3 object" format="rdata"/> | 32 <param type="data" name="rds_seurat_file" multiple="@MULTIPLE@" optional="@OPTIONAL@" label="RDS file" help="Select RDS file(s) with Seurat object for @VARNAME@" format="rdata"/> |
32 </when> | 33 </when> |
33 <when value="rds_sce"> | 34 <when value="rds_sce"> |
34 <param type="data" name="rds_sce_file" label="RDS file" help="Input as RDS file with Single Cell Experiment object" format="rdata"/> | 35 <param type="data" name="rds_sce_file" multiple="@MULTIPLE@" optional="@OPTIONAL@" label="RDS file" help="Select RDS file(s) with Single Cell Experiment object for @VARNAME@" format="rdata"/> |
36 </when> | |
37 <when value="h5seurat"> | |
38 <param type="data" name="h5seurat_file" multiple="@MULTIPLE@" optional="@OPTIONAL@" label="Seurat HDF5" help="Select Seurat HDF5 file(s) for @VARNAME" format="h5"/> | |
35 </when> | 39 </when> |
36 </conditional> | 40 </conditional> |
37 </xml> | 41 </xml> |
38 | 42 |
43 <token name="@INPUT_OBJ_PREAMBLE@"> | |
44 #if $input.format == 'loom' | |
45 ln -s '$input.loom_file' input.loom; | |
46 #else if $input.format == 'h5seurat' | |
47 ln -s '$input.h5seurat_file' input.h5seurat; | |
48 #else if $input.format == 'anndata' | |
49 ## it complains when using links for AnnData... | |
50 cp '$input.anndata_file' input.h5ad; | |
51 #end if | |
52 </token> | |
53 | |
39 <token name="@INPUT_OBJECT@"> | 54 <token name="@INPUT_OBJECT@"> |
40 #if $input.format == "anndata" | 55 #if $input.format == "anndata" |
41 --input-object-file '$input.anndata_file' --input-format anndata | 56 --input-object-file input.h5ad --input-format anndata |
42 #else if $input.format == "loom" | 57 #else if $input.format == "loom" |
43 --input-object-file '$input.loom_file' --input-format loom | 58 --input-object-file input.loom --input-format loom |
44 #else if $input.format == "rds_seurat" | 59 #else if $input.format == "rds_seurat" |
45 --input-object-file '$input.rds_seurat_file' --input-format seurat | 60 --input-object-file '$input.rds_seurat_file' --input-format seurat |
46 #else if $input.format == "rds_sce" | 61 #else if $input.format == "rds_sce" |
47 --input-object-file '$input.rds_sce_file' --input-format singlecellexperiment | 62 --input-object-file '$input.rds_sce_file' --input-format singlecellexperiment |
63 #else if $input.format == "h5seurat" | |
64 --input-object-file input.h5seurat --input-format h5seurat | |
65 #end if | |
66 </token> | |
67 | |
68 <token name="@QUERY_OBJ_PREAMBLE@"> | |
69 #if $query.format == 'loom' | |
70 ln -s '$query.loom_file' query.loom; | |
71 #else if $query.format == 'h5seurat' | |
72 ln -s '$query.h5seurat_file' query.h5seurat; | |
73 #else if $query.format == 'anndata' | |
74 ## it complains when using links for AnnData... | |
75 cp '$query.anndata_file' query.h5ad; | |
76 #end if | |
77 </token> | |
78 | |
79 <token name="@QUERY_OBJECT@"> | |
80 #if $query.format == "anndata" | |
81 --query-object-file query.h5ad --query-format anndata | |
82 #else if $query.format == "loom" | |
83 --query-object-file query.loom --query-format loom | |
84 #else if $query.format == "rds_seurat" | |
85 --query-object-file '$query.rds_seurat_file' --query-format seurat | |
86 #else if $query.format == "rds_sce" | |
87 --query-object-file '$query.rds_sce_file' --query-format singlecellexperiment | |
88 #else if $query.format == "h5seurat" | |
89 --query-object-file query.h5seurat --query-format h5seurat | |
90 #end if | |
91 </token> | |
92 | |
93 <token name="@ANCHORS_OBJ_PREAMBLE@"> | |
94 #if $anchors.format == 'loom' | |
95 ln -s '$anchors.loom_file' anchors.loom; | |
96 #else if $anchors.format == 'h5seurat' | |
97 ln -s '$anchors.h5seurat_file' anchors.h5seurat; | |
98 #else if $anchors.format == 'anndata' | |
99 ## it complains when using links for AnnData... | |
100 cp '$anchors.anndata_file' anchors.h5ad; | |
101 #end if | |
102 </token> | |
103 | |
104 <token name="@ANCHORS_OBJECT@"> | |
105 #if $anchors.format == "anndata" | |
106 --anchors-object-file anchors.h5ad --anchors-format anndata | |
107 #else if $anchors.format == "loom" | |
108 --anchors-object-file anchors.loom --anchors-format loom | |
109 #else if $anchors.format == "rds_seurat" | |
110 --anchors-object-file '$anchors.rds_seurat_file' --anchors-format seurat | |
111 #else if $anchors.format == "rds_sce" | |
112 --anchors-object-file '$anchors.rds_sce_file' --anchors-format singlecellexperiment | |
113 #else if $anchors.format == "h5seurat" | |
114 --anchors-object-file anchors.h5seurat --anchors-format h5seurat | |
115 #end if | |
116 </token> | |
117 | |
118 <token name="@REFERENCE_OBJ_PREAMBLE@"> | |
119 #if $reference.format == 'loom' | |
120 ln -s '$reference.loom_file' reference.loom; | |
121 #else if $reference.format == 'h5seurat' | |
122 ln -s '$reference.h5seurat_file' reference.h5seurat; | |
123 #else if $reference.format == 'anndata' | |
124 ## it complains when using links for AnnData... | |
125 cp '$reference.anndata_file' reference.h5ad; | |
126 #end if | |
127 </token> | |
128 | |
129 <token name="@REFERENCE_OBJECT@"> | |
130 #if $reference.format == "anndata" | |
131 --reference-object-file reference.h5ad --reference-format anndata | |
132 #else if $reference.format == "loom" | |
133 --reference-object-file reference.loom --reference-format loom | |
134 #else if $reference.format == "rds_seurat" | |
135 --reference-object-file '$reference.rds_seurat_file' --reference-format seurat | |
136 #else if $reference.format == "rds_sce" | |
137 --reference-object-file '$reference.rds_sce_file' --reference-format singlecellexperiment | |
138 #else if $reference.format == "h5seurat" | |
139 --reference-object-file reference.h5seurat --reference-format h5seurat | |
140 #end if | |
141 </token> | |
142 | |
143 <token name="@INPUT_OBJS_PREAMBLE@"> | |
144 #if $input.format == 'loom' | |
145 #for $i, $fh in enumerate($input.loom_file): | |
146 ln -s '$fh' input.${i}.loom; | |
147 #end for | |
148 #else if $input.format == 'h5seurat' | |
149 #for $i, $fh in enumerate($input.h5seurat_file): | |
150 ln -s '$fh' input.${i}.h5seurat; | |
151 #end for | |
152 #else if $input.format == 'anndata' | |
153 ## it complains when using links for AnnData... | |
154 #for $i, $fh in enumerate($input.anndata_file): | |
155 cp '$fh' input.${i}.h5ad; | |
156 #end for | |
157 #end if | |
158 </token> | |
159 | |
160 <token name="@INPUT_OBJECTS@"> | |
161 #if $input.format == "anndata" | |
162 --input-object-files | |
163 #set file_array = [ "input."+str($i)+".h5ad" for $i, $fh in enumerate($input.anndata_file)] | |
164 #set files = ",".join($file_array) | |
165 ${files} | |
166 --input-format anndata | |
167 #else if $input.format == "loom" | |
168 --input-object-files | |
169 #set file_array = [ "input."+str($i)+".loom" for $i, $fh in enumerate($input.loom_file)] | |
170 #set files = ",".join($file_array) | |
171 ${files} | |
172 --input-format loom | |
173 #else if $input.format == "rds_seurat" | |
174 --input-object-files | |
175 #set file_array = $input.rds_seurat_file | |
176 #set files = ",".join([ str($fh) for $fh in $file_array ]) | |
177 ${files} | |
178 --input-format seurat | |
179 #else if $input.format == "rds_sce" | |
180 --input-object-files | |
181 #set file_array = $input.rds_sce_file | |
182 #set files = ",".join([ str($fh) for $fh in $file_array ]) | |
183 ${files} | |
184 --input-format singlecellexperiment | |
185 #else if $input.format == "h5seurat" | |
186 --input-object-files | |
187 #set file_array = [ "input."+str($i)+".h5seurat" for $i, $fh in enumerate($input.h5seurat)] | |
188 #set files = ",".join($file_array) | |
189 ${files} | |
190 --input-format h5seurat | |
191 #end if | |
192 </token> | |
193 | |
194 <token name="@REFERENCE_OBJS_PREAMBLE@"> | |
195 #if $reference.format == 'loom' | |
196 #for $i, $fh in enumerate($reference.loom_file): | |
197 ln -s '$fh' reference.${i}.loom; | |
198 #end for | |
199 #else if $reference.format == 'h5seurat' | |
200 #for $i, $fh in enumerate($reference.h5seurat_file): | |
201 ln -s '$fh' reference.${i}.h5seurat; | |
202 #end for | |
203 #else if $reference.format == 'anndata' | |
204 ## it complains when using links for AnnData... | |
205 #for $i, $fh in enumerate($reference.anndata_file): | |
206 cp '$fh' reference.${i}.h5ad; | |
207 #end for | |
208 #end if | |
209 </token> | |
210 | |
211 <token name="@REFERENCE_OBJECTS@"> | |
212 #if $reference.format == "anndata" and $reference.anndata_file: | |
213 --reference-object-files | |
214 #set file_array = [ "reference."+str($i)+".h5ad" for $i, $fh in enumerate($reference.anndata_file)] | |
215 #set files = ",".join($file_array) | |
216 ${files} | |
217 --reference-format anndata | |
218 #else if $reference.format == "loom" and $reference.loom_file: | |
219 --reference-object-files | |
220 #set file_array = [ "reference."+str($i)+".loom" for $i, $fh in enumerate($reference.loom_file)] | |
221 #set files = ",".join($file_array) | |
222 ${files} | |
223 --reference-format loom | |
224 #else if $reference.format == "rds_seurat" and $reference.rds_seurat_file: | |
225 --reference-object-files | |
226 #set files = ",".join([ str($fh) for $fh in $reference.rds_seurat_file ]) | |
227 ${files} | |
228 --reference-format seurat | |
229 #else if $reference.format == "rds_sce" and $reference.rds_sce_file: | |
230 --reference-object-files | |
231 #set files = ",".join([ str($fh) for $fh in $reference.rds_sce_file ]) | |
232 ${files} | |
233 --reference-format singlecellexperiment | |
234 #else if $reference.format == "h5seurat" and $reference.h5seurat: | |
235 --reference-object-files | |
236 #set file_array = [ "reference."+str($i)+".h5seurat" for $i, $fh in enumerate($reference.h5seurat)] | |
237 #set files = ",".join($file_array) | |
238 ${files} | |
239 --reference-format h5seurat | |
48 #end if | 240 #end if |
49 </token> | 241 </token> |
50 | 242 |
51 <xml name="output_object_params"> | 243 <xml name="output_object_params"> |
52 <param type="select" name="format" label="Choose the format of the output" help="Seurat, Single Cell Experiment or Loom"> | 244 <param type="select" name="format" label="Choose the format of the output" help="Seurat, Single Cell Experiment, AnnData or Loom"> |
53 <option value="rds_seurat" selected="true">RDS with a Seurat object</option> | 245 <option value="rds_seurat" selected="true">RDS with a Seurat object</option> |
246 <option value="anndata">AnnData written by Seurat</option> | |
54 <option value="loom">Loom</option> | 247 <option value="loom">Loom</option> |
55 <option value="rds_sce">RDS with a Single Cell Experiment object</option> | 248 <option value="rds_sce">RDS with a Single Cell Experiment object</option> |
56 </param> | 249 </param> |
57 </xml> | 250 </xml> |
58 | 251 |
60 <data name="loom_file" from_work_dir="seurat_obj.loom" format="h5" label="${tool.name} on ${on_string}: Seurat Loom"> | 253 <data name="loom_file" from_work_dir="seurat_obj.loom" format="h5" label="${tool.name} on ${on_string}: Seurat Loom"> |
61 <filter>format == 'loom'</filter> | 254 <filter>format == 'loom'</filter> |
62 </data> | 255 </data> |
63 <data name="rds_seurat_file" format="rdata" label="${tool.name} on ${on_string}: Seurat RDS"> | 256 <data name="rds_seurat_file" format="rdata" label="${tool.name} on ${on_string}: Seurat RDS"> |
64 <filter>format == 'rds_seurat'</filter> | 257 <filter>format == 'rds_seurat'</filter> |
258 </data> | |
259 <data name="anndata_file" format="h5ad" label="${tool.name} on ${on_string}: AnnData from Seurat"> | |
260 <filter>format == 'anndata'</filter> | |
65 </data> | 261 </data> |
66 <data name="rds_sce_file" format="rdata" label="${tool.name} on ${on_string}: Seurat Single Cell Experiment RDS"> | 262 <data name="rds_sce_file" format="rdata" label="${tool.name} on ${on_string}: Seurat Single Cell Experiment RDS"> |
67 <filter>format == 'rds_sce'</filter> | 263 <filter>format == 'rds_sce'</filter> |
68 </data> | 264 </data> |
69 </xml> | 265 </xml> |
78 #else if $format == "rds_sce" | 274 #else if $format == "rds_sce" |
79 --output-object-file '$rds_sce_file' --output-format singlecellexperiment | 275 --output-object-file '$rds_sce_file' --output-format singlecellexperiment |
80 #end if | 276 #end if |
81 </token> | 277 </token> |
82 | 278 |
279 <xml name="plot_output_files_format" token_format="png"> | |
280 <data label="Seurat ${plot_type.plot_type_selector} on ${on_string}: @FORMAT@ plot" name="plot_out_@FORMAT@" format='@FORMAT@' > | |
281 <filter>plot_format == '@FORMAT@'</filter> | |
282 </data> | |
283 </xml> | |
284 | |
285 <token name="@OUTPUT_PLOT@"> | |
286 #if $plot_format == "png" | |
287 --plot-out '$plot_out_png' | |
288 #else if $plot_format == "pdf" | |
289 --plot-out '$plot_out_pdf' | |
290 #else if $plot_format == "eps" | |
291 --plot-out '$plot_out_eps' | |
292 #else if $plot_format == "ps" | |
293 --plot-out '$plot_out_ps' | |
294 #else if $plot_format == "jpg" | |
295 --plot-out '$plot_out_jpg' | |
296 #else if $plot_format == "tiff" | |
297 --plot-out '$plot_out_tiff' | |
298 #else if $plot_format == "svg" | |
299 --plot-out '$plot_out_svg' | |
300 #end if | |
301 </token> | |
302 | |
83 <xml name="genes-use-input"> | 303 <xml name="genes-use-input"> |
84 <param name="genes_use" argument="--genes-use" optional="true" type="data" format="tsv,txt,tabular" label="Genes to use" help="A file with gene names to use in construction of SNN graph if building directly based on expression data rather than a dimensionally reduced representation (i.e. PCs)."/> | 304 <param name="genes_use" argument="--genes-use" optional="true" type="data" format="tsv,txt,tabular" label="Genes to use" help="A file with gene names to use in construction of SNN graph if building directly based on expression data rather than a dimensionally reduced representation (i.e. PCs)."/> |
85 </xml> | 305 </xml> |
86 <xml name="dims-use-input"> | 306 <xml name="dims-use-input"> |
87 <param name="dims_use" argument="--dims-use" min="1" optional="true" type="integer" label="PCA Dimensions to use" help="Number of PCs (dimensions) to use in construction of the SNN graph."/> | 307 <param name="dims_use" argument="--dims-use" min="1" optional="true" type="integer" label="PCA Dimensions to use" help="Number of PCs (dimensions) to use in construction of the SNN graph."/> |
94 types of single cell data. | 314 types of single cell data. |
95 ]]></token> | 315 ]]></token> |
96 | 316 |
97 <token name="@VERSION_HISTORY@"><![CDATA[ | 317 <token name="@VERSION_HISTORY@"><![CDATA[ |
98 **Version history** | 318 **Version history** |
319 4.0.0: Moves to Seurat 4.0.0, introducing a number of methods for merging datasets, plus the whole suite of Seurat plots. Pablo Moreno with funding from AstraZeneca. | |
99 | 320 |
100 3.2.3+galaxy0: Moves to Seurat 3.2.3 and introduce convert method, improving format interconversion support. | 321 3.2.3+galaxy0: Moves to Seurat 3.2.3 and introduce convert method, improving format interconversion support. |
101 | 322 |
102 3.1.2_0.0.8: Update metadata parsing | 323 3.1.2_0.0.8: Update metadata parsing |
103 | 324 |
106 3.1.1_0.0.6+galaxy0: Moved to Seurat 3. | 327 3.1.1_0.0.6+galaxy0: Moved to Seurat 3. |
107 | 328 |
108 Find clusters: removed dims-use, k-param, prune-snn. | 329 Find clusters: removed dims-use, k-param, prune-snn. |
109 | 330 |
110 2.3.1+galaxy0: Improved documentation and further exposition of all script's options. Pablo Moreno, Jonathan Manning and Ni Huang, Expression Atlas team https://www.ebi.ac.uk/gxa/home at | 331 2.3.1+galaxy0: Improved documentation and further exposition of all script's options. Pablo Moreno, Jonathan Manning and Ni Huang, Expression Atlas team https://www.ebi.ac.uk/gxa/home at |
111 EMBL-EBI https://www.ebi.ac.uk/. Parts obtained from wrappers from Christophe Antoniewski(github.com/drosofff) and Lea Bellenger(github.com/bellenger-l). | 332 EMBL-EBI https://www.ebi.ac.uk/. Parts obtained from wrappers from Christophe Antoniewski (GitHub drosofff) and Lea Bellenger (GitHub bellenger-l). |
112 | 333 |
113 0.0.1: Initial contribution. Maria Doyle (github.com/mblue9). | 334 0.0.1: Initial contribution. Maria Doyle (GitHub mblue9). |
114 ]]></token> | 335 ]]></token> |
115 | 336 |
116 | 337 |
117 <xml name="citations"> | 338 <xml name="citations"> |
118 <citations> | 339 <citations> |
340 <citation type="doi">10.1038/s41592-021-01102-w</citation> | |
119 <citation type="doi">10.1038/nbt.4096</citation> | 341 <citation type="doi">10.1038/nbt.4096</citation> |
120 <citation type="bibtex"> | 342 <citation type="bibtex"> |
121 @misc{r-seurat-scripts.git, | 343 @misc{r-seurat-scripts.git, |
122 author = {Jonathan Manning, Pablo Moreno, EBI Gene Expression Team}, | 344 author = {Jonathan Manning, Pablo Moreno, EBI Gene Expression Team}, |
123 year = {2018}, | 345 year = {2018}, |
125 publisher = {GitHub}, | 347 publisher = {GitHub}, |
126 journal = {GitHub repository}, | 348 journal = {GitHub repository}, |
127 url = {https://github.com/ebi-gene-expression-group/r-seurat-scripts.git}, | 349 url = {https://github.com/ebi-gene-expression-group/r-seurat-scripts.git}, |
128 } | 350 } |
129 </citation> | 351 </citation> |
130 <citation type="doi">10.1038/s41592-021-01102-w</citation> | |
131 </citations> | 352 </citations> |
132 </xml> | 353 </xml> |
133 </macros> | 354 </macros> |