Mercurial > repos > goeckslab > squidpy
annotate squidpy_spatial.py @ 3:d30ef0613122 draft
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit 3c79b731a6c4379bfb0491ceebf767789c8b79c4
author | goeckslab |
---|---|
date | Tue, 14 May 2024 21:54:05 +0000 |
parents | be0e7952e229 |
children |
rev | line source |
---|---|
0
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
1 import argparse |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
2 import ast |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
3 import json |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
4 import warnings |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
5 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
6 import pandas as pd |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
7 import squidpy as sq |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
8 from anndata import read_h5ad |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
9 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
10 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
11 def main(inputs, anndata, output, output_plot): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
12 """ |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
13 Parameter |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
14 --------- |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
15 inputs : str |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
16 File path to galaxy tool parameter. |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
17 anndata : str |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
18 File path to anndata containing phenotyping info. |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
19 output : str |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
20 File path to output. |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
21 output_plot: str or None |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
22 File path to save the plotting image. |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
23 """ |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
24 warnings.simplefilter('ignore') |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
25 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
26 with open(inputs, 'r') as param_handler: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
27 params = json.load(param_handler) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
28 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
29 adata = read_h5ad(anndata) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
30 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
31 if 'spatial' not in adata.obsm: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
32 try: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
33 adata.obsm['spatial'] = adata.obs[['X_centroid', 'Y_centroid']].values |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
34 except Exception as e: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
35 print(e) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
36 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
37 tool = params['analyses']['selected_tool'] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
38 tool_func = getattr(sq.gr, tool) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
39 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
40 options = params['analyses']['options'] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
41 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
42 for k, v in options.items(): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
43 if not isinstance(v, str): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
44 continue |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
45 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
46 if v in ('', 'none'): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
47 options[k] = None |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
48 continue |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
49 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
50 if k == 'genes': # for spatial_autocorr and sepal |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
51 options[k] = [e.strip() for e in v.split(',')] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
52 elif k == 'radius': # for spatial_neighbors |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
53 options[k] = ast.literal_eval(v) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
54 elif k == 'interactions': # for ligrec |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
55 options[k] = pd.read_csv(v, sep="\t") |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
56 elif k == 'max_neighs': |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
57 options[k] = int(v) # for sepal |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
58 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
59 cluster_key = params['analyses'].get('cluster_key') |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
60 if cluster_key: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
61 tool_func(adata, cluster_key, **options) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
62 else: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
63 tool_func(adata, **options) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
64 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
65 if output_plot: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
66 plotting_options = params['analyses']['plotting_options'] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
67 for k, v in plotting_options.items(): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
68 if not isinstance(v, str): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
69 continue |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
70 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
71 if v in ('', 'none'): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
72 plotting_options[k] = None |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
73 continue |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
74 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
75 if k == 'figsize': |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
76 options[k] = ast.literal_eval(v) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
77 elif k in ('palette', 'score', 'source_groups', 'target_groups'): |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
78 options[k] = [e.strip() for e in v.split(',')] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
79 elif k == 'means_range': # ligrec |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
80 v = v.strip() |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
81 if v[0] == '(': |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
82 v = v[1:] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
83 if v[-1] == ')': |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
84 v = v[:-1] |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
85 options[k] = tuple([float(e.strip()) for e in v.split(',', 1)]) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
86 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
87 plotting_func = getattr(sq.pl, tool) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
88 if cluster_key: |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
89 plotting_func(adata, cluster_key, save=output_plot, **plotting_options) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
90 else: # TODO Remove this, since all plottings need cluster key |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
91 plotting_func(adata, save=output_plot, **plotting_options) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
92 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
93 adata.write(output) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
94 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
95 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
96 if __name__ == '__main__': |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
97 aparser = argparse.ArgumentParser() |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
98 aparser.add_argument("-i", "--inputs", dest="inputs", required=True) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
99 aparser.add_argument("-e", "--output", dest="output", required=True) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
100 aparser.add_argument("-a", "--anndata", dest="anndata", required=True) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
101 aparser.add_argument("-p", "--output_plot", dest="output_plot", required=False) |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
102 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
103 args = aparser.parse_args() |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
104 |
be0e7952e229
planemo upload for repository https://github.com/goeckslab/tools-mti/tree/main/tools/squidpy commit ee16860018eba110ff845d62b18396db22abd91e
goeckslab
parents:
diff
changeset
|
105 main(args.inputs, args.anndata, args.output, args.output_plot) |