DefaultAssay for FindClusters after RPCA integration in seurat v5 vs seurat v4 #9114
-
Hello, rpca <- FindNeighbors(rpca, reduction = "integrated.rpca", dims = 1:30,verbose=T) Error in FindClusters.Seurat(rpca, resolution = seq(from = 0.1, to = 0.7, : Provided graph.name not present in Seurat object The code works fine if I don't change the default assay (as done in the vignette at https://satijalab.org/seurat/articles/seurat5_integration) however the columns with the cluster results in the metadata have "RNA" in their name suggesting the clustering was done on the RNA assay (even if I computed the SNN on integrated.rpca ). Is it correct not to set DefaultAssay as "integrated" in seurat v5 workflow after getting the integration results? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
The integration results are not stored in an assay anymore but are stored as a reduction (here integrated.rpca), precisely as PCA corrected coordinates, from which UMAP coordinates and clusters will be calculated. This is why in Seurat v5, You can always revert back to a Seurat v4 integration (by using More info here But basically, everything is good here, your clusters have been calculated on your integrated data when you specify 'integrated.rpca', which should be the name set in the |
Beta Was this translation helpful? Give feedback.
-
Thank you Alexis! Very clear! |
Beta Was this translation helpful? Give feedback.
The integration results are not stored in an assay anymore but are stored as a reduction (here integrated.rpca), precisely as PCA corrected coordinates, from which UMAP coordinates and clusters will be calculated. This is why in Seurat v5,
RunPCA
must be run before integration, while in Seurat v4, it was run after integration, you need the PCA coordinates to calculate the integration corrected coordinates in v5.You can always revert back to a Seurat v4 integration (by using
options(Seurat.object.assay.version = "v3")
) or on your object :pbmc3k[["RNA3"]] <- as(object = pbmc3k[["RNA"]], Class = "Assay")
Before running a Seurat v4 integration pipeline (using
FindIntegationAnchors
andInteg…