histFeatureCategory: Histogram of features per sample type

View source: R/tab_measuredvalues_missingvalues.R

histFeatureCategoryR Documentation

Histogram of features per sample type

Description

The function histFeatureCategory creates histogram plots for each sample type in se.

Usage

histFeatureCategory(se, measured = TRUE, category = "type", ...)

Arguments

se

SummarizedExperiment, the assay slot contains the intensity values per sample. Missing values are encoded as NA.

measured

logical, should the measured values (measured = TRUE) or missing values (measured = FALSE) be taken

category

character, corresponding to a column in colData(se)

...

additional parameters passed to geom_histogram, e.g. binwidth.

Value

plotly object from ggplotly

Examples

## create se
a <- matrix(seq_len(100), nrow = 10, ncol = 10, 
            dimnames = list(seq_len(10), paste("sample", seq_len(10))))
a[c(1, 5, 8), seq_len(5)] <- NA
set.seed(1)
a <- a + rnorm(100)
cD <- data.frame(name = colnames(a), type = c(rep("1", 5), rep("2", 5)))
rD <- data.frame(spectra = rownames(a))
se <- SummarizedExperiment::SummarizedExperiment(assay = a, 
    rowData = rD, colData = cD)

histFeatureCategory(se, measured = TRUE, category = "type")


tnaake/MatrixQCvis documentation built on June 20, 2024, 7:22 a.m.