toMatrix {oncomix}R Documentation

Convert SummarizedExperiment or Dataframe to Matrix

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

toMatrix(m)

Arguments

m

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

Value

A matrix of expression values

Examples

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

[Package oncomix version 1.14.0 Index]