omicverse-single-cell-trajectory-inference

Infer trajectories and summarize lineages on cluster-ready AnnData objects.

13|2|Updated Apr 5, 2026
One-click install
npx skills add https://github.com/Starlitnightly/omicverse-skills --skill omicverse-single-cell-trajectory-inference
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: omicverse-single-cell-trajectory-inference
Source: https://github.com/Starlitnightly/omicverse-skills/tree/main/src/omicverse_skills/skills/single-cell-trajectory-inference
Command: npx skills add https://github.com/Starlitnightly/omicverse-skills --skill omicverse-single-cell-trajectory-inference

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires anndata, numpy, pandas, scanpy, omicverse, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

Provide reproducible trajectory inference and coarse lineage summarization for cluster-ready single-cell AnnData objects so users can compute pseudotime, fate probabilities, and cluster-level topology without redoing preprocessing.

Core Features & Use Cases

  • Multi-branch inference: Run diffusion_map, slingshot, or palantir branches through a shared TrajInfer wrapper to obtain dpt_pseudotime, slingshot_pseudotime, or palantir_pseudotime and associated outputs.
  • Palantir follow-ups: Compute fate probabilities, branch masks, and optional lineage gene trends when dependencies are present.
  • PAGA topology: Produce cluster-level PAGA summaries and visualizations after pseudotime computation to aid interpretation.
  • Use Case: Convert an OmicVerse trajectory notebook into a reusable workflow to compare DPT, Slingshot, and Palantir analyses on the same preprocessed dataset.

Quick Start

Run diffusion_map on my cluster-ready AnnData to compute pseudotime and then calculate and plot a PAGA topology summary.

Frequently Asked Questions about omicverse-single-cell-trajectory-inference

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I compute pseudotime for a single-cell AnnData object?

To compute pseudotime for single-cell AnnData, you can use diffusion_map, slingshot, or palantir algorithms via a shared wrapper, producing dpt_pseudotime, slingshot_pseudotime, or palantir_pseudotime alongside fate probabilities and PAGA summaries.

What preprocessing is required before running trajectory inference on AnnData?

Trajectory inference on AnnData requires completed QC, normalization, PCA or embedding generation, neighbor graph construction, and clustering. You must have existing cluster labels in anndata.obs, an obsm representation, and a plotting basis to generate pseudotime and lineage summaries.

Can I compare DPT, Slingshot, and Palantir trajectory analyses on the same dataset?

Yes, you can compare DPT, Slingshot, and Palantir trajectory analyses on the same preprocessed single-cell dataset by running each method through a shared TrajInfer wrapper to obtain corresponding pseudotime values and associated outputs for direct comparison.

Do I need external dependencies to run Palantir trajectory inference?

Running Palantir trajectory inference requires optional external dependencies including pcurvepy2 for slingshot and mellon for computing Palantir gene trends. Fate probabilities and branch masks are computed when these dependencies are present.

How does PAGA topology summarize single-cell cluster relationships?

PAGA topology summarizes single-cell cluster relationships by producing cluster-level connectivity summaries and visualizations after pseudotime computation. It interprets lineage structure by mapping transitions between annotated clusters in the AnnData object.

What is the difference between diffusion map and slingshot pseudotime methods?

Diffusion map computes dpt_pseudotime using diffusion processes on the neighbor graph, while slingshot generates slingshot_pseudotime through fitting minimum spanning trees to clusters. Both are accessed via a shared wrapper to produce lineage summaries on AnnData objects.