ContigCellDB-fun: Construct a ContigCellDB

Description Usage Arguments Value Functions Accessors/mutators See Also Examples

Description

Construct a ContigCellDB

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
ContigCellDB(
  contig_tbl,
  contig_pk,
  cell_tbl,
  cell_pk,
  cluster_tbl,
  cluster_pk = character(),
  equalize = TRUE
)

ContigCellDB_10XVDJ(
  contig_tbl,
  contig_pk = c("barcode", "contig_id"),
  cell_pk = "barcode",
  ...
)

Arguments

contig_tbl

a data frame of contigs, and additional fields describing their properties

contig_pk

character vector naming fields in contig_tbl that uniquely identify a row/contig

cell_tbl

a data frame of cell barcodes, and (optional) additional fields describing their properties

cell_pk

character vector naming fields in cell_tbl that uniquely identify a cell barcode

cluster_tbl

A data frame that provide cluster assignments for each contig

cluster_pk

If cluster_tbl was provided, a character vector naming fields in cluster_tbl that uniquely identify a cluster

equalize

logical. Should the contig, cells and clusters be equalized by taking the intersection of their common keys?

...

passed to ContigCellDB()

Value

ContigCellDB

Functions

Accessors/mutators

See $,ContigCellDB-method for more on how to access and mutate slots. See mutate_cdb() and filter_cdb() for endomorphic filtering/mutation methods See split_cdb() to split into a list, and rbind.ContigCellDB() for the inverse operation.

See Also

$,ContigCellDB-method

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
data(contigs_qc)
contigs_qc

cdb = ContigCellDB(contigs_qc, contig_pk = c('barcode', 'pop', 'sample', 'contig_id'),
 cell_pk = c('barcode', 'pop', 'sample'))
 cdb

 # everything that was in contigs_qc
 cdb$contig_tbl

 # Only the cell_pk are included by default (until clustering/canonicalization)
 cdb$cell_tbl

 # Empty, since no cluster_pk was specified
 cdb$cluster_tbl

 # Keys
 cdb$contig_pk
 cdb$cell_pk
 cdb$cluster_pk

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