Add a command to a Seurat object @commands
slot
AddSeuratCommand.Rd
Add a command to a Seurat object @commands
slot
Examples
object <- SeuratObject::pbmc_small
names(object@commands)
#> [1] "NormalizeData.RNA" "ScaleData.RNA"
#> [3] "RunPCA.RNA" "BuildSNN.RNA.pca"
#> [5] "FindClusters" "RunTSNE.pca"
#> [7] "JackStraw.RNA.pca" "ScoreJackStraw.pca"
#> [9] "ProjectDim.RNA.pca" "FindVariableFeatures.RNA"
object <- AddSeuratCommand(
object, "RunSeuratDEAnalysis",
"RunSeuratDEAnalysis(object, group_by = 'groups', ident_1 = 'g1', ident_2 = 'g2')",
list(group_by = "groups", ident_1 = "g1", ident_2 = "g2")
)
object@commands$RunSeuratDEAnalysis
#> Command: RunSeuratDEAnalysis(object, group_by = 'groups', ident_1 = 'g1', ident_2 = 'g2')
#> Time: 2025-08-12 23:10:29.519376
#> group_by : groups
#> ident_1 : g1
#> ident_2 : g2