Create a single-cell Haircut experiment

create_sce_haircut(path, norm_method = "clr_normalize", adducts = NULL)

Arguments

path

path to output matrices, or R matrix object.

norm_method

Normalization method for counts. Normalized data is stored in logcounts. Set to NULL to skip normalization.

adducts

data_frame with positions of hairpin adducts. Expects two columns named adduct and pos.

Value

SingleCellExperiment containing a sparseMatrix of counts

Examples

create_sce_haircut(scrunchy_data("haircut/"))
#> Loading haircut matrix files: /home/travis/R/Library/scrunchy/extdata/haircut/
#> class: SingleCellExperiment #> dim: 426 250 #> metadata(0): #> assays(2): counts logcounts #> rownames(426): Abasic_1 Abasic_10 ... riboG_8 riboG_9 #> rowData names(2): hairpin position #> colnames(250): TGCGGGTGTAGAGTGC TGGTTCCCATCTATGG ... CTCGAAAAGTTCGATC #> TGACAACGTCGCATAT #> colData names(1): cell_id #> reducedDimNames(0): #> spikeNames(0): #> altExpNames(0):
# using pre-loaded matrix mat <- SingleCellExperiment::counts(fsce_small[["haircut"]]) create_sce_haircut(mat)
#> class: SingleCellExperiment #> dim: 426 250 #> metadata(0): #> assays(2): counts logcounts #> rownames(426): Abasic_1 Abasic_10 ... riboG_8 riboG_9 #> rowData names(2): hairpin position #> colnames(250): TGCGGGTGTAGAGTGC TGGTTCCCATCTATGG ... CTCGAAAAGTTCGATC #> TGACAACGTCGCATAT #> colData names(1): cell_id #> reducedDimNames(0): #> spikeNames(0): #> altExpNames(0):