sample_genes {CellBench} | R Documentation

## Sample genes from a SingleCellExperiment

### Description

Sample n genes from a SingleCellExperiment object with no replacement

### Usage

    sample_genes(x, n)

### Arguments

`x` | the SingleCellExperiment object
`n` | the number of genes to sample

### Value

SingleCellExperiment object

### Examples

    sample_sce_data <- readRDS(cellbench_file("10x_sce_sample.rds"))
    dim(sample_sce_data)
    x <- sample_genes(sample_sce_data, 50)
    dim(x)

[Package CellBench version 1.6.0 Index]