selectTrajectory {CellTrails} | R Documentation

## Select component from trajectory graph

### Description

Retains a single component of a trajectory graph.

### Usage

    selectTrajectory(sce, component)

### Arguments

`sce` | A `SingleCellExperiment` object
`component` | Number of component to be selected

### Details

The construction of a trajectory graph may result in a forest having multiple tree components, which may represent individual trajectories or isolated nodes. This method should be used to extract a single component from the graph. A component is identified by its (integer) number.
Diagnostic messages
An error is thrown if the states have not been connected yet; function `connectStates` needs to be called first. An error is thrown if an unknown component (number) is selected.

### Value

An updated `SingleCellExperiment` object

### Author(s)

Daniel C. Ellwanger

### See Also

`connectStates`

`findStates` `states`

### Examples

    # Example data
    data(exSCE)

    # Select trajectory
    exSCE <- selectTrajectory(exSCE, component=1)

[Package CellTrails version 1.0.1 Index]