Skip to content

Add more marker genes to cellmatch for annotation

Shao, Xin edited this page Jan 8, 2023 · 1 revision

[1] Create a custom_marker data.frame

e.g., add markers for mouse liver periportal and pericentral hepatocytes

custom_marker <- data.frame(species = c("Mouse", "Mouse", "Mouse", "Mouse"),
                            tissue = c("Liver", "Liver", "Liver", "Liver"),
                            cancer= c("Normal", "Normal", "Normal", "Normal"),
                            condition = c("Normal cell", "Normal cell", "Normal cell", "Normal cell"),
                            subtype1 = c("NA", "NA", "NA", "NA"),
                            subtype2 = c("NA", "NA", "NA", "NA"),
                            subtype3 = c("Periportal", "Periportal", "Pericentral", "Pericentral"),
                            celltype = c("Hepatocyte", "Hepatocyte", "Hepatocyte", "Hepatocyte"),
                            gene = c("Cyp2f2", "Alb", "Glul", "Cyp2e1"),
                            resource = c("Experiment", "Experiment", "Experiment", "Experiment"),
                            pmid = c("28166538", "28166538", "28166538", "28166538"), stringsAsFactors = FALSE)

[2] Add to cellmatch and use it in findmarkergene

cellmatch <- rbind(cellmatch, custom_marker)

obj <- findmarkergene(object = obj,
                      species = "Mouse",
                      marker = cellmatch,
                      tissue = "Liver")