This function identifies clusters that are nearly exclusively expressed in one donor. Currently it is hard-coded to define clusters with >90 or >50 function iterations will include these options as parameters.
check_donor(
anno,
cluster,
norm.dat,
select.cells = names(cluster),
keep.cl = NULL,
meta1_area = "roi",
meta2_donor = "external_donor_name",
plot = TRUE,
plot.path = "output/"
)anno dataframe which must include column names listed in `neun.colname` `meta1_area` and `meta2_donor` below. "cluster" is added from `cluster` parameter below.
clusters labels for all cells along with sample_id as their names
expression dataframe with columns as cells and rows as gene names and cpm normalized
column nmaes of norm.dat
clusters to definitely keep in analysis (e.g., to exclude from consideration as a donor cluster) default is NULL
The metadata column that contains information about the area (e.g. cortical region and layer). default is "roi"
The metadata column that contains information about the donor. default is "external_donor_name"
default is TRUE
path of plot, default is "./output/"
Gives cluster ids vs donor expression/region heatmap