Learn R Programming

cellGeometry (version 0.5.7)

collapse_group: Collapse groups in cellMarkers object

Description

Experimental function for collapsing groups in a cellMarkers objects.

Usage

collapse_group(mk, groups, weights = NULL)

Value

An updated cellMarkers class object.

Arguments

mk

A 'cellMarkers' class object.

groups

Character vector of groups to be collapsed. The collapsed group retains the name of the 1st element.

weights

Optional vector of weights for calculating the mean gene expression across groups. If left as NULL weights are determined by the total cell count in each group.