toMatrix: Convert SummarizedExperiment or Dataframe to Matrix

Description Usage Arguments Value Examples

View source: R/oncoMix_two_component_mixture_models.R

Description

This internal function converts SummarizedExperiment objects and dataframes (both S3 and S4) to matrices of expression values. Used within oncomix functions to convert all matrix-like objects to the matrix class.

Usage

1

Arguments

m

Can be a matrix, a data.frame, a DataFrame, or SummarizedExperiment object.

Value

A matrix of expression values

Examples

1
2
3
m <- as.data.frame(matrix(data=rgamma(n=150, shape=2, rate=2),
nrow=10, ncol=15))
m <- toMatrix(m)

Example output



oncomix documentation built on Nov. 8, 2020, 5:39 p.m.