Skip to main content
Glama

neighbors

Compute nearest neighbors distance matrices and construct neighborhood graphs for single-cell RNA sequencing data analysis. Supports customizable parameters for manifold approximation, distance metrics, and kNN search methods.

Instructions

Compute nearest neighbors distance matrix and neighborhood graph

Input Schema

NameRequiredDescriptionDefault
key_addedNoKey prefix for storing neighbor results.
knnNoWhether to use hard threshold for neighbor restriction.
methodNoMethod for computing connectivities ('umap' or 'gauss').umap
metricNoDistance metric to use.euclidean
metric_kwdsNoOptions for the distance metric.
n_neighborsNoSize of local neighborhood used for manifold approximation.
n_pcsNoNumber of PCs to use. If None, automatically determined.
random_stateNoRandom seed for reproducibility.
transformerNoApproximate kNN search implementation ('pynndescent' or 'rapids').
use_repNoKey for .obsm to use as representation.

Input Schema (JSON Schema)

{ "description": "Input schema for the neighbors graph construction tool.", "properties": { "key_added": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Key prefix for storing neighbor results.", "title": "Key Added" }, "knn": { "default": true, "description": "Whether to use hard threshold for neighbor restriction.", "title": "Knn", "type": "boolean" }, "method": { "default": "umap", "description": "Method for computing connectivities ('umap' or 'gauss').", "enum": [ "umap", "gauss" ], "title": "Method", "type": "string" }, "metric": { "default": "euclidean", "description": "Distance metric to use.", "title": "Metric", "type": "string" }, "metric_kwds": { "additionalProperties": true, "description": "Options for the distance metric.", "title": "Metric Kwds", "type": "object" }, "n_neighbors": { "default": 15, "description": "Size of local neighborhood used for manifold approximation.", "exclusiveMinimum": 1, "maximum": 100, "title": "N Neighbors", "type": "integer" }, "n_pcs": { "anyOf": [ { "minimum": 0, "type": "integer" }, { "type": "null" } ], "default": null, "description": "Number of PCs to use. If None, automatically determined.", "title": "N Pcs" }, "random_state": { "default": 0, "description": "Random seed for reproducibility.", "title": "Random State", "type": "integer" }, "transformer": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Approximate kNN search implementation ('pynndescent' or 'rapids').", "title": "Transformer" }, "use_rep": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Key for .obsm to use as representation.", "title": "Use Rep" } }, "title": "NeighborsModel", "type": "object" }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/huang-sh/scmcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server