generate_pseudobulk: Generate "pseudobulk" data from a 'ContigCellDB'

Description Usage Arguments Details Value Examples

View source: R/pseudo-bulk.R

Description

Tabulate contigs with a unique combination of class_keys per total_keys. For instance, total_keys might be a sample identifier, and class_keys might be the V- and J- gene identities. The idea is that this might mimic the data generated in a bulk experiment.

Usage

1
generate_pseudobulk(ccdb, class_keys, total_keys, type = c("cell", "umi"))

Arguments

ccdb

ContigCellDB()

class_keys

character naming fields in contig_tbl that define unique classes of the repertoire

total_keys

character naming fields to be conditioned upon when calculating the total.

type

one of "cell" or "umi"

Details

This function is currently rather 10x-specific, in that it is assumed that columns barcode and umis exist.

Value

tibble

Examples

1
2
3
data(ccdb_ex)
ccdb_ex = cluster_germline(ccdb_ex)
pseudo = generate_pseudobulk(ccdb_ex, c('v_gene', 'j_gene', 'chain'), c('pop', 'sample'))

CellaRepertorium documentation built on Nov. 8, 2020, 7:48 p.m.