Open sadhnarao opened 3 hours ago
Hi,
Not member of dev team but hopefully can be helpful. So I think what might be happening from looking at the plots is that due to the number of cells in the first split panel it is being rasterized and the second plot is not. If you set raster = FALSE
that should solve the issue.
If I use pbmc dataset you can see that modifying those parameters modifies both of the plots in the split, but this can get messy with rasterization depending on cell number. Reproducible example below showing both plots are modified by changing parameters when rasterization isn't an issue. This issue with rasterization is also resolved in custom version of FeaturePlot from my package scCustomize (among other changes to the default vignette here)
Best, Sam
suppressMessages(library(Seurat))
pbmc <- pbmc3k.SeuratData::pbmc3k.final
pbmc <- suppressMessages(UpdateSeuratObject(pbmc))
#> Warning: Assay RNA changing from Assay to Assay
#> Warning: Graph RNA_nn changing from Graph to Graph
#> Warning: Graph RNA_snn changing from Graph to Graph
#> Warning: DimReduc pca changing from DimReduc to DimReduc
#> Warning: DimReduc umap changing from DimReduc to DimReduc
#> Warning: Adding a command log without an assay associated with it
#> Adding a command log without an assay associated with it
pbmc$sample_id <- sample(c("sample1", "sample2"), size = ncol(pbmc),
replace = TRUE)
FeaturePlot(pbmc, features = "ACTB", split.by = "sample_id", order = T, pt.size = 2)
FeaturePlot(pbmc, features = "ACTB", split.by = "sample_id", order = F, pt.size = 2)
Created on 2024-10-24 with reprex v2.1.1
I would like to plot gene expression in UMAPs, split by disease state. But when I use split.by the arguments 'pt.size' and 'order' only apply to the last plot
I reviewed prior questions and solutions for this (#235) but the comment thread closes by stating that the latest version of Seurat has addressed this with the order = TRUE argument.
Does anyone have a solution for this that will allow 'order' and 'pt.size' arguments to apply to all graphs?