Closed TuoCai2000 closed 7 months ago
Did you make sure your input object for the RaceID analysis had unique row names (genes) and column names (cells)? If this is the case, I'd need sample code reproducing the error.
Hi! Thank you so much! I have sent my code and data to the email: StemID@noreply.github.com,I will appreciate a lot if you help me !
Not sure that works. Please send to me directly and I can see what I can do: dominic.gruen@uni-wuerzburg.de Ideally, send small sample data.
I ran your code.
Please install the RaceID package from CRAN, instead of sourcing the R file from this repo.
Also, there is no need to convert ndata to a data.frame: ndata <-hspc@assays$RNA@counts)
I also recommend computing the distance matrix in PCA space instead of in UMAP space. UMAP distances can be meaningless or at least very distorted.
require(RaceID) library(Seurat) hspc=readRDS("hspc.rds") ndata <-hspc@assays$RNA@counts sc <- SCseq(ndata) sc <- filterdata( object = sc, mintotal = 500 ) part <- as.numeric(hspc@meta.data$RNA_snn_res.0.255) d <- as.matrix(dist(hspc@reductions$umap@cell.embeddings)) umap <- as.data.frame(hspc@reductions$umap@cell.embeddings) names(part) <- colnames(d) n <- colnames(sc@ndata) part <- part[n] sc@cpart <- sc@cluster$kpart <- part sc@distances <- d[n,n] sc@tsne <- umap[n,] sc@medoids <- compmedoids(sc, sc@cpart) ltr <- Ltree(sc) ltr <- compentropy(ltr) ltr <- projcells( object = ltr, cthr=5, # use clusters with at least this many cells nmode=TRUE # use knn )
Hi, thank you for developing StemID! I tried to run StemID on my seurat object following the closed issues. However, it errors when I run the code:
I will appreciate a lot if you help me! Thank you very much!