assignCellsToClusters: Assigns cells to previously defined clones.

View source: R/assignCellsToClusters.R

assignCellsToClustersR Documentation

Assigns cells to previously defined clones.

Description

Cells that have not been used to define clones (such as cycling or apoptotic cells) can retrospectively be assigned a clone membership.

Usage

assignCellsToClusters(outc, xps, similarity=T)

Arguments

outc

List containing segment-by-cell matrix and clone membership of each cell. See clusterCells).

xps

Segment-by-cell matrix of expression- or copy number states. Columns represent new cells to be assigned to existing clones.

similarity

Whether to use similarity (similarity=T) or distance (similarity=F), when comparing cells to existing clones. Default similarity metric is "correlation. Default distance metric is "Euclidean".

Details

Let S := { S_1, S_2, ... S_n } be the set of n genomic segments obtained from bulk DNA-sequencing. Further, let S_I \in S be the subset of segments for which cells within a clone have a well defined copy number state. Pearson Correlation Coefficients are calculated as similarity metric between each new cell and the consensus profile of each clone, based on segments s \in S_I. Each cell is assigned to the clone to which it is most similar.
Alternatively, if similarity is set to false, the Euclidean distance metric is used instead of the Pearson Correlation.

Value

List with same components as input:

cnps

Segment-by-cell matrix of copy number states, with new cells added as columns.

sps

The clone membership of each cell (that is columns in cnps).

Author(s)

Noemi Andor

Examples

  data(cnps)
  data(eps)
  set.seed(3)
  rcells1 = sample(colnames(cnps), 120)
  rcells2 = setdiff(colnames(eps), rcells1)
  outc = clusterCells(cnps[apply(cnps, 1, var)>0, rcells1])
  outc = assignCellsToClusters(outc, eps[,rcells2])

liayson documentation built on Sept. 30, 2022, 1:07 a.m.