Open MoussaKassim opened 3 weeks ago
I have the same question. PRECAST uses as input a Seurat object but I cannot create a spatial object with three-dimension (e.g., xyz) with Seurat. Can PRECAST use three-dimensional spatial information? If yes, can you provide an example?
Yes, PRECAST is indeed capable of utilizing three-dimensional spatial information. Within PRECAST, this spatial information is employed to construct an adjacency matrix, which quantifies the similarities among various spots.
In our recently developed R package, ProFAST, we offer a function named 'AddAdj' that seamlessly integrates support for three-dimensional coordinates. Below, we present an illustrative example of how to incorporate this function into PRECAST, drawing upon the tutorial found at https://feiyoung.github.io/PRECAST/articles/PRECAST.BreastCancer.html. This example demonstrates the practical application of 'AddAdj' within the PRECAST framework.
Here are the codes: install.packages(''ProFAST") library(ProFAST)
set.seed(2022) PRECASTObj <- CreatePRECASTObject(bc2, project = "BC2", gene.number = 2000, selectGenesMethod = "SPARK-X", premin.spots = 20, premin.features = 20, postmin.spots = 1, postmin.features = 10)
posList <- lapply(PRECASTObj@seulist, function(x) as.matrix(@meta.data[,c('x', 'y', 'z')]))
PRECASTObj@AdjList <- pbapply::pblapply(posList, AddAdj, neighbors=6)
PRECASTObj <- AddParSetting(PRECASTObj, Sigma_equal = FALSE, verbose = TRUE, maxIter = 30)
PRECASTObj <- PRECAST(PRECASTObj, K = 14)
Thank you very much
Hello,
I am reaching out to inquire whether Precast supports 3D functionality. This feature would be highly beneficial for our current project.
Could you please confirm if Precast can be used with 3D data? If so, any additional information or documentation on how to implement this would be greatly appreciated.
Thank you in advance for your assistance.
Best regards,