mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-10-01 09:48:11 +08:00
Add layout and diffexp calculations to cli options
This commit is contained in:
+1
-1
@@ -53,7 +53,7 @@ def run_scanpy(args):
|
|||||||
)
|
)
|
||||||
|
|
||||||
from .scanpy_engine.scanpy_engine import ScanpyEngine
|
from .scanpy_engine.scanpy_engine import ScanpyEngine
|
||||||
app.data = ScanpyEngine(args.data_directory, schema="data_schema.json")
|
data = ScanpyEngine(args.data_directory, schema="data_schema.json", graph_method=args.layout, diffexp_method=args.diffexp)
|
||||||
app.run(host="127.0.0.1", debug=True, port=args.port)
|
app.run(host="127.0.0.1", debug=True, port=args.port)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,11 @@ class ScanpyEngine(CXGDriver):
|
|||||||
@classmethod
|
@classmethod
|
||||||
def add_to_parser(cls, subparsers, invocation_function):
|
def add_to_parser(cls, subparsers, invocation_function):
|
||||||
scanpy_group = subparsers.add_parser("scanpy", help="run cellxgene using the scanpy engine")
|
scanpy_group = subparsers.add_parser("scanpy", help="run cellxgene using the scanpy engine")
|
||||||
|
# TODO these choices should be generated from the actual available methods
|
||||||
|
scanpy_group.add_argument("-l", "--layout", choices=["umap", "tsne"], default="umap",
|
||||||
|
help="Algorithm to use for graph layout")
|
||||||
|
scanpy_group.add_argument("-d", "--diffexp", choices=["ttest"], default="ttest",
|
||||||
|
help="Algorithm to use to calculate differential expression")
|
||||||
scanpy_group.add_argument("data_directory", metavar="dir", help="Directory containing data and schema file")
|
scanpy_group.add_argument("data_directory", metavar="dir", help="Directory containing data and schema file")
|
||||||
scanpy_group.set_defaults(func=invocation_function)
|
scanpy_group.set_defaults(func=invocation_function)
|
||||||
return scanpy_group
|
return scanpy_group
|
||||||
|
|||||||
Reference in New Issue
Block a user