farrellja / URD

URD - Reconstruction of Branching Developmental Trajectories
GNU General Public License v3.0
115 stars 41 forks source link

Pseudotime discontinuous at zero #64

Open corwms opened 3 years ago

corwms commented 3 years ago

Hello,

Upon running URD on our data, we notice a jump between our root cells at zero and the next lowest pseudotime value. This seems to be typical (Siebert et al., fig 3D). Attached an image of our data.

X_Oct4_Nd150_Di

I'm wondering if there are parameters I can tweak to reduce this effect or if you have recommendations on presentation.

Thank you!

farrellja commented 3 years ago

Hi @corwms,

A discontinuity in pseudotime will definitely occur in our algorithm between cells defined as root and those not defined as root — as you noticed, there’s some of this in some of our published papers. The cells you choose as the root will always have pseudotime 0 by definition, whereas the most connected cells that are not part of the root will have a higher pseudotime based on averaging when they are visited in many simulations. The good news: your expression curve suggests that the simulations found a reasonable path through the data that is pulling out a good signal. The really large gap suggests that your root cells might be connected to a lot of the data so the path taken in each simulation exhibits more variability than I’m used to. Some things you could try:

  1. Choose a smaller set of root cells. You might be able to figure out the best candidates by looking at the current set of root cells in some various dimensions of your diffusion map potentially.
  2. You could try smoothing the pseudotime — calculate it twice from opposite directions (one starting at the root cells, one starting from the tip cells), normalize them both to 0-1 range, then average root pseudotime, (1-tip pseudotime). We did something similar to this in the hydra spatial trajectories, where we started from both the head and the foot: https://github.com/cejuliano/hydra_single_cell/blob/master/SA12_URD_GranularZymogen.Rmd (see the “Calculate pseudotime” section)