Normalises marker intensities and stores the result in the data slot.
Raw counts remain unchanged.
Usage
NormaliseData(
object,
method = c("zscore", "minmax", "quantile"),
markers = NULL
)Arguments
- object
An
SpatialCellData-classobject.- method
Character.
"zscore"(default),"minmax", or"quantile".- markers
Character vector or
NULL. Markers to normalise. IfNULL, all markers are normalised.
Value
An SpatialCellData-class with updated data slot.
Examples
counts <- matrix(rnorm(40, 500, 100), nrow = 20,
dimnames = list(NULL, c("CD3", "CD8")))
coords <- data.frame(x = runif(20), y = runif(20))
obj <- CreateSpatialObject(counts, coords)
obj <- NormaliseData(obj, method = "zscore")