View source: R/PomaCreateObject.R
PomaCreateObject | R Documentation |
SummarizedExperiment
ObjectPomaCreateObject
creates a SummarizedExperiment
object from data frames.
PomaCreateObject(metadata = NULL, features = NULL, factor_levels = 10)
metadata |
Data frame. Metadata variables structured in columns. Sample ID must be the first column. |
features |
Matrix of features. Each feature is a column. |
factor_levels |
Numeric. Integer variables with less levels than indicated by this parameter will be treated as factors. |
A SummarizedExperiment
object.
Pol Castellano-Escuder
Morgan M, Obenchain V, Hester J, Pagès H (2021). SummarizedExperiment: SummarizedExperiment container. R package version 1.24.0, https://bioconductor.org/packages/SummarizedExperiment.
data(iris)
# Create metadata: Data frame with sample names and a group factor
metadata <- data.frame(sample_id = paste0("sample_", 1:150), group = iris$Species)
# Create features: `p` column data frame with features
features <- iris[, 1:4]
# Create a `SummarizedExperiment` object with `POMA`
object <- PomaCreateObject(metadata = metadata,
features = features)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.