Comments (4)
Hi @connerlambden ,
I think this is the best strategy (running Slingshot in PC space and only using UMAP for visualization), but unfortunately since UMAP is non-linear, it doesn't always produce congruent results.
One thing you could try is to re-run UMAP with slightly different parameters (or even just a different random seed) and see if it improves. Otherwise, I would just color the points on the UMAP plot by pseudotime and either forgo the lines or draw them by hand/in PowerPoint (I've seen a lot of published papers do something like this). This isn't the most satisfying solution, but it is only for visualization, and the actual pseudotime values will be derived from the PCs, anyway.
Best,
Kelly
from slingshot.
Thanks for the help. I'm trying the following:
umap_curve_embedding <- embedCurves(sce, newDimRed=reducedDims(sce)$UMAP) lines(SlingshotDataSet(umap_curve_embedding)@curves[[1]]$s, lwd = 2, col = 'red')
Results look super weird. Any ideas? Also, how do I do this on a per-lineage basis?
from slingshot.
Haha, I often get this type of plot myself. The issue is that the s
matrix is not re-ordered, so the cells in that matrix match up with the cells in your original data. If you want to put them in order of pseudotime, there is a corresponding index you can use (SlingshotDataSet(umap_curve_embedding)@curves[[1]]$ord
), but we wrote a lines
function for SlingshotDataSet
objects that should know how to handle this properly. If lines(SlingshotDataSet(umap_curve_embedding), lwd = 2, col = 'red')
doesn't work, let me know! And you can give a vector of different colors if you don't want all lineages to be the same color.
from slingshot.
Thanks that worked!
from slingshot.
Related Issues (20)
- how to calclate the POS to compare other algorithm? HOT 2
- Pulling and plotting Differential pseudotime data across different conditions/metadata slots HOT 1
- `embedCurves` should also map MST into new space HOT 1
- Slingshot followed by CellRank HOT 1
- is slingshot using only the variable genes? HOT 2
- Pick one lineage from many for conditiontest HOT 3
- How do I extract feature_info in my rds file? HOT 4
- What does a curve represent biologically? HOT 7
- Overlapping curve issue - change to code needed? HOT 3
- Removing a lineage from a `PseudotimeOrdering` object? HOT 3
- Error in graph.adjacency.dense: Adjacency matrix should be symmetric to produce an undirected graph. Invalid value HOT 5
- pseudotime in two lineage? HOT 2
- Slingshot error HOT 1
- Error while plotting the Minimum Distances Between Cell-Type Centroids using Slingshot in r HOT 6
- Error: (converted from warning) useNames = NA is deprecated. Instead, specify either useNames = TRUE or useNames = FALSE. HOT 1
- Slingshot package ------ Error in crossprod(out) : "crossprod" is not BUILTIN function HOT 1
- confusion about the end of a lineage HOT 1
- [Question] Is there any way to force a single trajectory/disable splitting? HOT 3
- Can I use more than two dimensions as the input for Slingshot? HOT 2
- how to use slingshot_conditions on PCA and visualization on UMAP HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from slingshot.