brainCells {BRETIGEA} | R Documentation |
Estimate brain cell type proportions in bulk expression data with marker genes.
Description
This function uses marker genes estimated in a meta-analysis of brain cell type-associated RNA expression data sets, and uses them as input for the findCells cell type proportion estimation procedure pipeline.
Usage
brainCells(
inputMat,
nMarker = 50,
species = "combined",
data_set = "mckenzie",
celltypes = c("ast", "end", "mic", "neu", "oli", "opc"),
method = "SVD",
scale = TRUE
)
Arguments
inputMat |
Gene expression data frame or matrix, with rownames corresponding to gene names, some of which are marker genes, and columns corresponding to samples. |
nMarker |
The number of marker genes (that are present in your expression data set) to use in estimating the surrogate cell type proportion variable for each cell type. |
species |
By default, this function uses markers from combined human and mouse measurements, which are the most robust and reliable, as the gene expression patterns are very conserved between these two species. Other options are "human" and "mouse" for data specific to those species. Note that OPCs only have 500 gene symbols in this case, and are taken from only the Darmanis et al or Tasic et al data sets, respectively. |
data_set |
Which data set the data should be derived from. Options are "mckenzie" (default), "kelley". Note that the "kelley" data set will ignore the "species" argument. |
celltypes |
Character vector of which cell types to estimate. |
method |
To estimate the cell type proportions, can either use "PCA" or "SVD". |
scale |
Whether or not to scale the gene expression data from each marker gene prior to using it as an input for dimension reduction. |
Value
A sample-by-cell type matrix of estimate cell type proportion variables.
Examples
ct_res = brainCells(aba_marker_expression, nMarker = 50, species = "combined")
cor.test(ct_res[, "mic"], as.numeric(aba_pheno_data$ihc_iba1_ffpe), method = "spearman")