translate_marker_names: Translate marker names to format use by COMPASS

View source: R/utils.R

translate_marker_namesR Documentation

Translate marker names to format use by COMPASS

Description

Translate boolean population names from format exported by common software tools to a format used by COMPASS.

Usage

translate_marker_names(cellpops)

Arguments

cellpops

character vector of cell population names.

Value

character vector of cell population names used by COMPASS

See Also

select_compass_pops

Examples

#Generate marker names
markers = LETTERS[1:4]
pos = c("+","-")
popnames = apply(expand.grid(pos,pos,pos,pos),1,
              function(x) paste(paste(paste(markers,x,sep=""),
              collapse=""),",Count",sep=""))
popnames = sample(c(popnames,
           paste(paste(markers,sample(c("+","-"),
           length(markers),replace=TRUE),sep=""),
           ",Count",sep="")))
popnames = popnames[select_compass_pops(popnames,LETTERS[1:4])]
#Translate
translate_marker_names(popnames)

RGLab/COMPASS documentation built on Feb. 11, 2025, 4:40 p.m.