View source: R/calcNhoodExpression.R
calcNhoodExpression | R Documentation |
This function calculates the mean expression of each feature in the
Milo object stored in the assays slot. Neighbourhood expression data are
stored in a new slot nhoodExpression
.
calcNhoodExpression(x, assay = "logcounts", subset.row = NULL, exprs = NULL)
x |
A |
assay |
A character scalar that describes the assay slot to use for calculating neighbourhood expression. |
subset.row |
A logical, integer or character vector indicating the rows
of |
exprs |
If |
This function computes the mean expression of each gene, subset by subset.rows
where present, across the cells contained within each neighbourhood.
A Milo
object with the nhoodExpression
slot populated.
Mike Morgan
require(SingleCellExperiment) m <- matrix(rnorm(100000), ncol=100) milo <- Milo(SingleCellExperiment(assays=list(logcounts=m))) milo <- buildGraph(m, k=20, d=30) milo <- makeNhoods(milo) milo <- calcNhoodExpression(milo) dim(nhoodExpression(milo))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.