Key Takeaways

  • Trajectory and pseudotime analysis order single cells along a biological process, such as differentiation, using gene expression similarity rather than measured time.
  • The start of pseudotime is chosen by the analyst, so the direction of a trajectory is an assumption that needs independent support.
  • In two public scRNA-seq datasets reanalyzed in iSCanGuide™, StaVia recovered the published lineage structure: a basal-rooted hierarchy with two luminal branches in human breast epithelium, and three fates (amnion, mesoderm, and primordial germ cell-like cells) in human embryoids.
  • Analysis choices changed the results. Integration strength, clustering resolution, and the grouping of transitional cells all affected which branches connected.
  • Checking the root, the cells that connect lineages, batch effects, and cluster identities before interpreting a trajectory prevents over-reading it.

Introduction

Trajectory and pseudotime analysis reconstruct how cells move between states, for example from stem cell to differentiated cell, using a single snapshot of single-cell RNA sequencing (scRNA-seq) data. Instead of following the same cells over time, the analysis orders thousands of cells along a continuous path based on gene expression similarity.

This article is for biologists and bioinformaticians who want to apply trajectory analysis to developmental or disease-progression data. It explains the core concepts, compares common methods, and walks through two reanalyses of published datasets in iSCanGuide™, Advaita Bioinformatics’ single-cell analysis platform: human breast epithelium from Nguyen et al.1 and human embryoids from Zheng et al.2 For each, we show what the reanalysis reproduced, what it did not, and which analysis choices made the difference.

What Is Single-Cell Trajectory Analysis?

Single-cell trajectory analysis, also called trajectory inference, reconstructs the paths cells take through a continuous biological process such as differentiation, activation, or disease progression. It connects cells into a graph by gene expression similarity, then orders them from a starting state to one or more end states and identifies where lineages branch.

The output usually has three parts: a graph or tree of cell states, branch points where lineages split, and a pseudotime value for every cell. Trajectory analysis complements clustering. Clustering asks which groups of cells exist; trajectory analysis asks how those groups connect.

What Is Pseudotime, and How Is It Different From Real Time?

Pseudotime is a computational ordering of cells along a biological process, based on gene expression similarity. A cell’s pseudotime reflects how far it has progressed from an analyst-chosen start point, usually scaled from 0 to 1. Pseudotime is a relative measure, not hours or days, and on its own it does not prove that one cell type gives rise to another.

Cells with similar pseudotime values are at similar transcriptional stages, even when they come from different samples. When a dataset includes real collection times, those times provide an independent check on pseudotime, as the embryoid case study below shows. Pseudotime values are also not directly comparable between branches, because each branch is measured by its distance from the same root.

How Does Trajectory Inference Work?

Most trajectory workflows follow the same seven steps, whatever algorithm computes the final trajectory:

  1. Quality control and normalization. Remove low-quality cells and normalize expression so cells are comparable.
  2. Feature selection and dimensionality reduction. Select variable genes and reduce the data, typically with principal component analysis (PCA).
  3. Batch correction. Integrate samples, for example with Harmony3, so that cells group by biology rather than by sample.
  4. Clustering. Group cells into states, for example with the Leiden algorithm.
  5. Annotation. Assign identities to clusters using known markers or published gene sets.
  6. Root selection. Choose the starting state from prior biological knowledge.
  7. Ordering and branch detection. Assign pseudotime to every cell and identify end states and branch points.

Both case studies below followed these steps in iSCanGuide™. Steps 3 to 5 had the largest effect on the final trajectories.

Which Trajectory Inference Method Should I Use?

No single trajectory method is best for every dataset. A benchmark in Nature Biotechnology compared 45 trajectory inference methods and found that performance depended strongly on the shape of the underlying trajectory, such as linear, branching or cyclic.4 Table 1 summarizes methods commonly used for branching differentiation data.

Method Approach Branching Root Reference
Monocle 2 Reverse graph embedding to learn a tree Yes User-set state Qiu et al., Nat Methods, 20175
Slingshot Principal curves through a cluster-level tree Yes User-set or inferred cluster Street et al., BMC Genomics, 20186
PAGA Graph of cluster connectivity; supports disconnected parts Yes User-set for diffusion pseudotime Wolf et al., Genome Biol, 20197
Diffusion pseudotime Distances on a diffusion map from a root cell With branch-detection tools User-set cell or cluster Angerer et al., Bioinformatics, 20168
VIA / StaVia Random walks on a cluster graph; predicts end states automatically Yes, including cyclic or disconnected User-set cluster or cell Stassen et al., Nat Commun, 20219; Genome Biol, 202410

Table 1. A comparison of methods commonly used for branching differentiation data.

The two published studies used Monocle 21 and diffusion pseudotime2. Both reanalyses here used StaVia, which predicts end states without being told where they are. Agreement between different algorithms is a useful test of whether a trajectory reflects the data rather than one method’s assumptions.

Case Study 1: Can a Published Breast Epithelium Trajectory Be Reproduced?

Yes, the central result can be reproduced. Reanalyzing the Nguyen et al. breast epithelium data in iSCanGuide™, StaVia recovered a trajectory rooted in basal cells that branches into the two luminal lineages, L1 and L2, matching the published model. Finer claims about individual cell states were not reproduced without further subclustering.

What Did the Original Study Find?

Nguyen et al. profiled human breast epithelial cells from reduction mammoplasties with droplet-based scRNA-seq, sequencing 24,646 cells from four donors.1 They defined one basal and two luminal cell types (L1, secretory; L2, hormone-responsive) and five cell states: basal (B), myoepithelial (Myo), L1.1, L1.2 and L2. Monocle 2 on 4,000 cells, with the root set in basal cells, produced three branches (Myo, L1 and L2), with the L1.2 state at the L1/L2 branch point.

What Did the iSCanGuide™ Reanalysis Show?

We used the deposited data (GEO GSE113197; 24,626 cells), integrated the four donors with Harmony, clustered with Leiden at resolution 0.4, and annotated clusters by scoring them against the paper’s published marker gene sets. Clustering gave one basal cluster (7,315 cells), one L1 cluster (6,603 cells), two L2-like clusters (3,767 and 3,198 cells) and one unresolved cluster (3,683 cells). StaVia, rooted in the basal cluster, found two luminal end states, L1 and L2 (Figure 1).

StaVia pseudotime trajectory of human breast epithelial cells in iSCanGuide, rooted in the basal cluster and branching into L1 and L2 luminal end states

Figure 1. StaVia pseudotime analysis of 24,626 human breast epithelial cells (GSE113197) in iSCanGuide™, rooted in the basal cluster (Start · 1). Pseudotime runs from 0 (purple) to 1 (yellow) and ends in two luminal end states: L1 (End · 2) and L2 (End · 4).

Three published details were not reproduced at this resolution. Basal and myoepithelial cells stayed in one cluster, so no separate Myo branch appeared. L1.1 and L1.2 were not separated, so the branch point could not be assigned to L1.2. The link between the basal and luminal compartments also passed through a small number of cells across a gap in the embedding, which could include doublets or rare intermediate cells. One practical lesson: gene-set scores computed from expression without batch correction carried donor-specific baselines, so cluster identities had to be compared within each donor.

Case Study 2: Can a Time-Course Trajectory Recover Known Lineages?

Yes. Reanalyzing the Zheng et al. human embryoid data in iSCanGuide™, StaVia found the same three end states (amnion, mesoderm, and primordial germ cell-like cells) without being told where they were, using either the authors’ cell labels or our own clusters. This matches the three lineages in the paper’s whole-dataset diffusion map.

What Did the Original Study Find?

Zheng et al. grew microfluidic post-implantation amniotic sac embryoids (μPASEs) from H9 human pluripotent stem cells stimulated with BMP4, and sequenced them at 24, 36 and 48 hours (18,335 cells in total).2 They identified eight cell types: epiblast-like cells (EpiLC), primitive streak-like cells (PSLC), two mesoderm-like states (MeLC1 and MeLC2), nascent and mature amniotic ectoderm-like cells (NasAMLC, AMLC1 and AMLC2) and primordial germ cell-like cells (PGCLC). Using diffusion maps and diffusion pseudotime rooted in EpiLC8, they traced the amnion and mesoderm lineages and found that PGCLCs are most closely related to NasAMLCs.

How Well Did Clustering Recover the Published Cell Types?

After integrating the three timepoints with Harmony, Leiden clustering at resolution 0.65 gave nine clusters. We annotated them using only marker genes named in the paper, then compared them with the authors’ labels. Seven of nine clusters matched a single author cell type, and the overall agreement (adjusted Rand index) was 0.53 (Table 2).

Author cell type Matching cluster purity Share of author cell type captured
EpiLC 74% 83%
PSLC 72% 65%
NasAMLC 62% 45%
AMLC1 + AMLC2 (one combined cluster) AMLC1 54%, AMLC2 30% 74% and 96%
MeLC1 80% 50%
MeLC2 97% 67%
PGCLC 93% 96%

Table 2. Cluster comparison results.

The two remaining clusters held cells in transition between the primitive streak and mesoderm: a nascent MeLC2 cluster and a mixed transitional cluster. AMLC1 and AMLC2 formed one combined amnion cluster (Figure 2).

Human embryoid cell clusters in iSCanGuide annotated from paper marker genes, next to the authors’ cell types on the same embedding

Figure 2. Embryoid cells on the Harmony-integrated embedding in iSCanGuide™. Left: our Leiden clusters, annotated using marker genes named in Zheng et al. (2022). Right: the authors’ cell types. Matching labels share colors, and related cell types share a color family.

What Did the Trajectory Show?

StaVia rooted in EpiLC found three end states with both labelings: AMLC2, MeLC2, and PGCLC with the authors’ labels, and the matching amnion, MeLC2, and PGCLC clusters with ours (Figure 3). MeLC1 did not form a separate end state in either StaVia run. The paper also separated MeLC1 from MeLC2 only when analyzing mesoderm cells on their own.2

Slingshot on the authors’ labels, with all four end states specified, separated MeLC1 and MeLC2 into two branches from PSLC, as in the paper (Figure 3, left). Because its end states were set rather than found, this run tests the paths between cell types, not the fates themselves. In it, the amnion path ran EpiLC → PSLC → NasAMLC → AMLC1 → AMLC2, passing through PSLC instead of leading directly from EpiLC to NasAMLC as in the paper.

The PGCLC result depended on the labeling. With the authors’ labels, the PGCLC branch connected to the NasAMLC node in both StaVia and Slingshot, matching the paper’s finding. With our clusters, StaVia connected it to a central node near the primitive streak and transitional mesoderm clusters, likely because a mixed transitional cluster offered a shorter path. In all three runs, the PGCLC connection crossed a gap in the embedding.

Slingshot and StaVia trajectories of human embryoid cells in iSCanGuide, using author cell labels and Leiden clusters, rooted in epiblast-like cells

Figure 3. Trajectories on the Harmony-integrated embryoid embedding in iSCanGuide™, all rooted in EpiLC. Left: Slingshot on the authors’ cell types, with end states set to MeLC1, MeLC2, AMLC2 and PGCLC. Middle: StaVia on the authors’ cell types, with end states found automatically. Right: StaVia on our Leiden clusters (start cluster 7 = EpiLC; automatically found end clusters 2 = amnion, 3 = MeLC2, 4 = PGCLC).

How Do the Two Reanalyses Compare with the Published Trajectories?

Both reanalyses (Table 4) reproduced the published lineage structure with a different algorithm from the original study, but neither reproduced every finer cell-state claim. The embryoid dataset gave stronger evidence, because its collection timepoints provide a check on trajectory direction that the breast dataset lacks.

Feature Breast epithelium (Nguyen et al., 2018) Embryoids (Zheng et al., 2022)
Published method Monocle 2 Diffusion pseudotime
Reanalysis method StaVia StaVia
Cells 24,626 from four donors 18,335 from three timepoints
Batch variable Donor Timepoint
Root Basal, set manually EpiLC, set manually
Main lineages reproduced Yes: L1 and L2 Yes: amnion, mesoderm, and PGCLC
Finer states Myo branch and L1.2 branch point not resolved MeLC1/MeLC2 split not resolved in whole-dataset run
Independent check on direction None Collection times (24 to 48 hours)

Table 3. Methods and parameters used for reanalyses of each dataset.

What Should You Check Before Trusting a Trajectory?

A trajectory method always produces an answer, so the analyst must test whether that answer reflects biology. These six checks came directly from the two reanalyses:

  1. Treat the root as an assumption. Pseudotime direction comes from the start point you choose. Justify the root with prior knowledge, and with real collection times when the design includes them.
  2. Inspect the cells that connect lineages. In both datasets, a key connection (basal to luminal; PGCLC to the rest) crossed a gap in the embedding. Check gene counts, doublet scores and co-expression of markers from both lineages in those cells.
  3. Match integration strength to the batch variable. Donors in the breast data differed for technical reasons, so strong correction was appropriate. Embryoid timepoints differ for biological reasons as well, so we increased correction only until the 24-hour batch cluster disappeared, then checked that early and late cell types still separated by time.
  4. Annotate clusters with independent evidence. Score clusters against published marker sets, and compare scores within each batch, because expression without batch correction carries sample-level baselines.
  5. Expect transitional cells to change connections. In the embryoid data, how cells between the primitive streak and mesoderm were clustered changed where the PGCLC branch attached.
  6. Match clustering resolution to the question. Cell types separated at low resolution, while finer states (myoepithelial cells, L1.2, AMLC1 versus AMLC2) would need subclustering of each compartment.

How Does iSCanGuide™ Support Trajectory Analysis?

iSCanGuide™ runs the trajectory workflow in one environment, from data upload and quality control through integration, clustering, annotation, and pseudotime. Every step in both case studies, including Harmony integration, Leiden clustering, gene-set enrichment, and StaVia trajectories, was run in iSCanGuide™.

The platform’s analysis modules include Embedding, Clustering, Differential Expression, Genes Collection, Enrichment, Cell Annotation, Cell-Cell Communication, and Trajectory. Custom gene sets, such as marker lists taken from a publication, can be loaded to score and annotate clusters. Author metadata can be imported alongside counts to compare clusters with published labels and to subset cells by cell type.

Next Step

Try trajectory and pseudotime analysis on your own single-cell data. Request an iSCanGuide™ demo to see the full workflow, from integration and annotation to lineage reconstruction. See how iSCanGuide™ handles real datasets on our use cases page, or learn more about single-cell analysis in our Learning Center.

Frequently Asked Questions

What is the difference between trajectory analysis and RNA velocity?

Trajectory analysis orders cells by expression similarity and needs a user-chosen root to set direction. RNA velocity estimates direction from the ratio of unspliced to spliced transcripts in each cell.11 The two can be combined, with velocity used to support the choice of root; Zheng et al. used both.2

Can pseudotime show that one cell type becomes another?

No. Pseudotime shows that cell states are transcriptionally connected in a plausible order. Lineage tracing, transplantation, or time-course experiments are needed to confirm that one state gives rise to another.

How do I choose the root for pseudotime?

Use prior biological knowledge, such as known stem or progenitor markers, or the earliest timepoint in a time-course design. In our examples, the root was set in basal cells for breast epithelium and in epiblast-like cells for the embryoids, as in the original studies.1,2

Should I integrate samples from different timepoints before trajectory analysis?

Only as far as needed to remove technical differences. Strong integration can erase real developmental differences between timepoints. Compare embeddings with and without integration, and check that early and late cell types still separate by time after correction.

Why do different trajectory methods give different results?

Methods assume different trajectory shapes, such as trees, cycles or disconnected lineages. A benchmark of 45 methods found that no single method performed best across all trajectory types,4 so running a second method is a practical check.

References

  1. Nguyen QH, Pervolarakis N, et al. Profiling human breast epithelial cells using single cell RNA sequencing identifies cell diversity. Nature Communications. 2018;9:2028. doi:10.1038/s41467-018-04334-1
  2. Zheng Y, Yan RZ, et al. Single-cell analysis of embryoids reveals lineage diversification roadmaps of early human development. Cell Stem Cell. 2022;29(9):1402–1419. doi:10.1016/j.stem.2022.08.009
  3. Korsunsky I, et al. Fast, sensitive and accurate integration of single-cell data with Harmony. Nature Methods. 2019;16:1289–1296. doi:10.1038/s41592-019-0619-0
  4. Saelens W, et al. A comparison of single-cell trajectory inference methods. Nature Biotechnology. 2019;37:547–554. doi:10.1038/s41587-019-0071-9
  5. Qiu X, et al. Reversed graph embedding resolves complex single-cell trajectories. Nature Methods. 2017;14:979–982. doi:10.1038/nmeth.4402
  6. Street K, et al. Slingshot: cell lineage and pseudotime inference for single-cell transcriptomics. BMC Genomics. 2018;19:477. doi:10.1186/s12864-018-4772-0
  7. Wolf FA, et al. PAGA: graph abstraction reconciles clustering with trajectory inference through a topology preserving map of single cells. Genome Biology. 2019;20:59. doi:10.1186/s13059-019-1663-x
  8. Angerer P, et al. destiny: diffusion maps for large-scale single-cell data in R. Bioinformatics. 2016;32(8):1241–1243. doi:10.1093/bioinformatics/btv715
  9. Stassen SV, et al. Generalized and scalable trajectory inference in single-cell omics data with VIA. Nature Communications. 2021;12:5528. doi:10.1038/s41467-021-25773-3
  10. Stassen SV, et al. StaVia: spatially and temporally aware cartography with higher-order random walks for cell atlases. Genome Biology. 2024;25. doi:10.1186/s13059-024-03347-y
  11. La Manno G, et al. RNA velocity of single cells. Nature. 2018;560:494–498. doi:10.1038/s41586-018-0414-6

Reviewed by Beverly V. Robinson, PhD (Genetics & Molecular Biology, Emory University), Bioinformatics Scientist at Advaita

Let’s Get Started