slingClusterLabels {slingshot} | R Documentation

## Extract cluster labels used by Slingshot

### Description

Extract the cluster labels used by `slingshot`.

### Usage

    slingClusterLabels(x)

    ## S4 method for signature 'SlingshotDataSet'
    slingClusterLabels(x)

    ## S4 method for signature 'SingleCellExperiment'
    slingClusterLabels(x)

### Arguments

`x` | an object containing `slingshot` output.

### Value

a vector of cluster labels or a matrix of cluster assignment weights.

### Methods (by class)

- `SlingshotDataSet`: returns the cluster labels stored in a `SlingshotDataSet` object.

- `SingleCellExperiment`: returns the cluster labels used by `slingshot` in a `SingleCellExperiment` object.

### Examples

    data("slingshotExample")
    sds <- getLineages(rd, cl)
    slingClusterLabels(sds)

[Package slingshot version 1.4.0 Index]